Skip to content

Don't confirm Elasticsearch CRITICAL from an HTML mention - #44

Draft
cursor[bot] wants to merge 1 commit into
mainfrom
cursor/critical-bug-management-16f1
Draft

cursor[bot] wants to merge 1 commit into
mainfrom
cursor/critical-bug-management-16f1

Conversation

@cursor

@cursor cursor Bot commented Oct 6, 2026

Copy link
Copy Markdown
Contributor

Bug and impact

check_elasticsearch_noauth confirmed CRITICAL unauthenticated Elasticsearch access on any HTTP 200 whose body contained the substring elasticsearch or cluster_name.

Port 9200 is in the default scan set, so this check always runs when that port is open. Fusion maps service-probe findings to source=probe + reliability=high (cvss 9.5), which the gate pins as un-droppable.

Trigger: Scan with --probe / --full (or the GUI equivalent). A web frontend, status page, or docs site bound to :9200 — including a docker-compose port-map of a search UI onto 9200 — returns HTML/JS that mentions elasticsearch. The report then states the cluster is open with "full data exfiltration and arbitrary document write possible."

Root cause

Confirmation was a case-insensitive substring match. JSON parse was best-effort and not required, unlike Docker/K8s/Vault probes in the same file which demand a distinctive parsed document.

Fix

Require HTTP 200 plus a JSON object with a non-empty string cluster_name (the real Elasticsearch/OpenSearch GET / payload). HTML mentions, JSON arrays, and tagline-only objects no longer confirm. OpenSearch cluster root documents still confirm.

Validation

  • python3 -m pytest test_probers.py::test_elasticsearch_detected_vs_auth test_probers.py::test_elasticsearch_html_mention_is_not_open_cluster test_probers.py::test_opensearch_json_root_still_confirms -v — 3 passed
  • python3 -m pytest test_*.py -q — 1754 passed, 5 skipped
Open in Web View Automation 

GET / on port 9200 treated any 200 whose body contained "elasticsearch"
or "cluster_name" as unauthenticated cluster access. Fusion pins probe
findings, so a docker-mapped frontend or docs page became an un-droppable
CRITICAL. Require a JSON object with a string cluster_name, matching the
real ES/OpenSearch root document.

Co-authored-by: dmitryflynn <dmitryflynn@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant