{
  "hunt": {
    "meta": {
      "tlp": "clear",
      "hunt": {
        "handoff": "promote-to-detection",
        "trigger": "intel-report",
        "methodology": "model-assisted",
        "applicability": "campaign-specific",
        "justification": "CVE-2026-111497 is a critical, KEV-listed vulnerability that allows remote code execution via a ubiquitous compression format. Confirming the absence of exploitation in a large estate is a high-value defensive objective."
      },
      "name": "Brotli Decoder Exposure and Exploitation Assessment",
      "type": "investigation",
      "labels": [
        "hunt",
        "attack.t1190",
        "attack.t1518",
        "discovery",
        "execution",
        "initial access"
      ],
      "targets": {
        "hunter": {
          "name": "Hunt agent",
          "agent": true
        },
        "analyst": {
          "name": "Tier-2 analyst",
          "role": "analyst"
        },
        "endpoint": {
          "name": "Endpoint telemetry (hb_ surfaces)",
          "category": "endpoint",
          "telemetry": [
            "endpoint"
          ]
        }
      },
      "analysis": "This hunt pivots from inventory (the 'what') to prevalence (the 'rare') and finally to behavior (the 'how') across three different surfaces, providing context that a simple version-match rule would lack.",
      "coverage": [
        {
          "stage": "exploit-delivery-malformed-brotli",
          "reason": "The listed surfaces cannot inspect the internal content of a Brotli-compressed stream to identify the malformed block switch; this requires NDR or TLS-decrypted traffic capture.",
          "status": "not_visible"
        },
        {
          "stage": "exploit-execution-and-crash",
          "steps": [
            "suspicious-behavior-triage"
          ],
          "status": "covered"
        },
        {
          "stage": "discovery-of-vulnerable-decoder",
          "steps": [
            "vulnerable-inventory-scope",
            "rare-version-prevalence"
          ],
          "status": "covered"
        }
      ],
      "scenario": {
        "stages": [
          {
            "name": "Exploit delivery via malformed Brotli stream",
            "slug": "exploit-delivery-malformed-brotli",
            "tactic": "initial-access",
            "techniques": [
              "T1190"
            ],
            "observables": [
              "HTTP requests with Brotli compression headers",
              "Crafted Brotli-compressed stream payloads",
              "Attacker-controlled data passed to node:zlib"
            ]
          },
          {
            "name": "Exploit execution and process crash",
            "slug": "exploit-execution-and-crash",
            "tactic": "execution",
            "techniques": [
              "T1190"
            ],
            "observables": [
              "Node.js process crash",
              "Exception code c0000005 (Access Violation)",
              "node.exe or node process spawning shells (sh, bash, cmd.exe)",
              "Memory disclosure of sensitive process memory",
              "Abnormal process terminations in web-facing applications"
            ]
          },
          {
            "name": "Discovery of vulnerable Brotli components",
            "slug": "discovery-of-vulnerable-decoder",
            "tactic": "discovery",
            "techniques": [
              "T1518"
            ],
            "observables": [
              "Node.js versions < 22.23.4",
              "Node.js versions < 24.22.1",
              "Node.js versions < 26.12.1",
              "Google Brotli versions 1.0.3 to 1.0.9, 1.1.0, 1.2.0",
              "Python packages Brotli and brotlicffi",
              "Vulnerable Bun, .NET, or Envoy deployments"
            ]
          }
        ],
        "summary": "An attacker exploits a critical buffer overflow in the Google Brotli decoder (CVE-2026-111497) by sending malformed compressed data to vulnerable applications such as Node.js or Python. Successful exploitation leads to memory corruption, resulting in either a denial-of-service crash or remote code execution."
      },
      "severity": "high",
      "rationale": "Start with internet-facing API gateways and web servers running Node.js or proxy software like Envoy, as these are the most exposed to malformed Brotli streams.",
      "guardrails": {
        "claims": "no_unsupported",
        "evidence": "citation_required",
        "telemetry": "untrusted",
        "missing_data": "not_benign"
      },
      "hypothesis": "An attacker is exploiting a vulnerable Brotli decoder (CVE-2026-111497) in an internet-facing Node.js or proxy instance to gain remote code execution or cause memory-corrupting crashes.",
      "parameters": {
        "scope_hosts": {
          "from": {
            "ref": "analyst-input",
            "kind": "manual",
            "observed": "2026-10-26"
          },
          "type": "list[host]",
          "default": [],
          "description": "Optional list of hostnames to focus the hunt on."
        },
        "lookback_days": {
          "from": {
            "ref": "hunt-standard",
            "kind": "manual",
            "observed": "2026-10-26"
          },
          "type": "number",
          "default": "14",
          "description": "Days of history to examine."
        },
        "suspicious_shells": {
          "from": {
            "ref": "hunt-standard",
            "kind": "manual",
            "observed": "2026-10-26"
          },
          "type": "list[string]",
          "default": [
            "sh",
            "bash",
            "cmd.exe",
            "powershell.exe",
            "zsh"
          ],
          "description": "Shells that should not be spawned by a web server."
        },
        "affected_package_names": {
          "from": {
            "ref": "Rapid7",
            "kind": "article",
            "observed": "2026-10-26"
          },
          "type": "list[string]",
          "default": [
            "node",
            "nodejs",
            "bun",
            "brotli",
            "brotlicffi",
            "envoy"
          ],
          "description": "Package names associated with the vulnerable decoder."
        }
      },
      "provenance": {
        "authors": [
          {
            "org": "huntbase.io",
            "name": "Huntbase hunt generation"
          }
        ],
        "generated": {
          "by": "huntbase-hunt-generation",
          "from": "https://www.rapid7.com/blog/post/etr-cve-2026-111497-critical-out-of-bounds-write-in-the-node-js-brotli-decoder",
          "gates": [
            "dry-run",
            "lint"
          ],
          "model": "hb_google/gemini-3-flash-preview"
        }
      },
      "references": [
        {
          "url": "https://www.rapid7.com/blog/post/etr-cve-2026-111497-critical-out-of-bounds-write-in-the-node-js-brotli-decoder",
          "name": "Rapid7 \u2014 CVE-2026-111497: Critical out-of-bounds write in the Node.js Brotli decoder"
        }
      ],
      "blind_spots": [
        {
          "id": "inventory-coverage-gap",
          "risk": "A host without the monitoring agent will not appear in the software inventory, leaving a blind spot in the exposure assessment.",
          "stage": "discovery-of-vulnerable-decoder",
          "question": "whether unmanaged cloud instances or shadow IT hosts are running vulnerable decoders",
          "requires": "complete endpoint agent enrollment"
        },
        {
          "id": "linux-crash-visibility",
          "risk": "Standard syslog might not capture every segmentation fault; a lack of crash data does not prove an absence of exploitation attempts.",
          "stage": "exploit-execution-and-crash",
          "question": "whether Node.js crashed on Linux with high fidelity",
          "requires": "hb_linux_audit with segfault reporting"
        }
      ]
    },
    "name": "Brotli Decoder Exposure and Exploitation Assessment",
    "description": "This hunt identifies the organizational exposure to CVE-2026-111497, a critical out-of-bounds write vulnerability in the Brotli decoder. It begins by scoping the estate to hosts running vulnerable versions of Node.js, Bun, and Brotli libraries. It then identifies rare versions of these applications across the fleet to highlight unpatched systems. Finally, it searches for post-exploitation behaviors, specifically shell processes spawned by web-facing applications and memory violation crashes (0xc0000005). An agent weighs the inventory exposure against behavioral signals to prioritize remediation."
  },
  "nodes": [
    {
      "id": "hypothesis",
      "type": "hypothesis",
      "label": "Hypothesis",
      "config": {
        "tags": [],
        "coverage": [
          {
            "stage": "exploit-delivery-malformed-brotli",
            "reason": "The listed surfaces cannot inspect the internal content of a Brotli-compressed stream to identify the malformed block switch; this requires NDR or TLS-decrypted traffic capture.",
            "status": "not_visible"
          },
          {
            "stage": "exploit-execution-and-crash",
            "steps": [
              "suspicious-behavior-triage"
            ],
            "status": "covered"
          },
          {
            "stage": "discovery-of-vulnerable-decoder",
            "steps": [
              "vulnerable-inventory-scope",
              "rare-version-prevalence"
            ],
            "status": "covered"
          }
        ],
        "rationale": "An attacker is exploiting a vulnerable Brotli decoder (CVE-2026-111497) in an internet-facing Node.js or proxy instance to gain remote code execution or cause memory-corrupting crashes.",
        "blind_spots": [
          {
            "id": "inventory-coverage-gap",
            "risk": "A host without the monitoring agent will not appear in the software inventory, leaving a blind spot in the exposure assessment.",
            "stage": "discovery-of-vulnerable-decoder",
            "question": "whether unmanaged cloud instances or shadow IT hosts are running vulnerable decoders",
            "requires": "complete endpoint agent enrollment"
          },
          {
            "id": "linux-crash-visibility",
            "risk": "Standard syslog might not capture every segmentation fault; a lack of crash data does not prove an absence of exploitation attempts.",
            "stage": "exploit-execution-and-crash",
            "question": "whether Node.js crashed on Linux with high fidelity",
            "requires": "hb_linux_audit with segfault reporting"
          }
        ],
        "scoping_notes": "Start with internet-facing API gateways and web servers running Node.js or proxy software like Envoy, as these are the most exposed to malformed Brotli streams.",
        "beyond_detection": "This hunt pivots from inventory (the 'what') to prevalence (the 'rare') and finally to behavior (the 'how') across three different surfaces, providing context that a simple version-match rule would lack."
      }
    },
    {
      "id": "vulnerable-inventory-scope",
      "type": "query",
      "label": "Identify potentially vulnerable software",
      "config": {
        "dsl": "sqlite",
        "role": "scoping",
        "source": "endpoint",
        "content": "SELECT device_hostname, package_name, package_version, install_path FROM hb_software_inventory WHERE (instr(',' || '{{affected_package_names}}' || ',', ',' || LOWER(package_name) || ',') > 0 OR LOWER(package_name) LIKE '%node%') AND (package_version LIKE '22.%' OR package_version LIKE '24.%' OR package_version LIKE '26.%' OR package_version LIKE '1.0.%' OR package_version LIKE '1.1.%' OR package_version LIKE '1.2.%')",
        "surface": "hb_software_inventory",
        "description": "Scope the hunt to hosts running packages mentioned in the advisory (Node.js, Bun, Brotli) to determine the baseline exposure.",
        "expected_signal": "A list of hosts and versions. Silence means no vulnerable major versions were found in the current inventory."
      },
      "parents": [
        {
          "id": "hypothesis"
        }
      ],
      "primitive_config": {
        "dsl": "sqlite",
        "role": "scoping",
        "label": "Identify potentially vulnerable software",
        "reads": [
          "device_hostname",
          "package_name",
          "package_version",
          "install_path"
        ],
        "source": "hb_software_inventory",
        "target": "endpoint",
        "content": "SELECT device_hostname, package_name, package_version, install_path FROM hb_software_inventory WHERE (instr(',' || '{{affected_package_names}}' || ',', ',' || LOWER(package_name) || ',') > 0 OR LOWER(package_name) LIKE '%node%') AND (package_version LIKE '22.%' OR package_version LIKE '24.%' OR package_version LIKE '26.%' OR package_version LIKE '1.0.%' OR package_version LIKE '1.1.%' OR package_version LIKE '1.2.%')",
        "silence": "not_evidence_of_absence",
        "expected": "A list of hosts and versions. Silence means no vulnerable major versions were found in the current inventory.",
        "verified": "dry-run",
        "verified_at": "2026-11-18"
      }
    },
    {
      "id": "rare-version-prevalence",
      "type": "query",
      "label": "Fleet prevalence of Node and proxy versions",
      "config": {
        "dsl": "sqlite",
        "role": "baseline",
        "source": "endpoint",
        "content": "SELECT process_name, process_file_version, COUNT(DISTINCT device_hostname) AS host_count, MIN(time) AS first_observed FROM hb_process_activity WHERE (LOWER(process_name) LIKE '%node%' OR LOWER(process_name) LIKE '%bun%' OR LOWER(process_name) LIKE '%envoy%') AND ('{{scope_hosts}}' = '' OR instr(',' || '{{scope_hosts}}' || ',', ',' || device_hostname || ',') > 0) AND time >= datetime('now', '-{{lookback_days}} days') GROUP BY 1, 2 ORDER BY host_count ASC",
        "surface": "hb_process_activity",
        "description": "Stack-count running versions across the fleet. Rare versions (tail-end) often indicate unpatched or shadow-IT instances that missed the standard update cycle.",
        "expected_signal": "Rarely seen versions on a small number of hosts. These are the primary targets for remediation review."
      },
      "parents": [
        {
          "id": "vulnerable-inventory-scope"
        }
      ],
      "primitive_config": {
        "dsl": "sqlite",
        "role": "baseline",
        "label": "Fleet prevalence of Node and proxy versions",
        "reads": [
          "process_name",
          "process_file_version",
          "device_hostname",
          "time"
        ],
        "source": "hb_process_activity",
        "target": "endpoint",
        "content": "SELECT process_name, process_file_version, COUNT(DISTINCT device_hostname) AS host_count, MIN(time) AS first_observed FROM hb_process_activity WHERE (LOWER(process_name) LIKE '%node%' OR LOWER(process_name) LIKE '%bun%' OR LOWER(process_name) LIKE '%envoy%') AND ('{{scope_hosts}}' = '' OR instr(',' || '{{scope_hosts}}' || ',', ',' || device_hostname || ',') > 0) AND time >= datetime('now', '-{{lookback_days}} days') GROUP BY 1, 2 ORDER BY host_count ASC",
        "silence": "not_evidence_of_absence",
        "baseline": {
          "window": "{{lookback_days}}d",
          "compare": "first_seen"
        },
        "expected": "Rarely seen versions on a small number of hosts. These are the primary targets for remediation review.",
        "verified": "dry-run",
        "prevalence": {
          "by": "device_hostname",
          "key": [
            "process_name",
            "process_file_version"
          ],
          "rare_below": 5
        },
        "verified_at": "2026-11-18"
      }
    },
    {
      "id": "suspicious-behavior-triage",
      "type": "query",
      "label": "Detect post-exploit behavior and crashes",
      "config": {
        "dsl": "sqlite",
        "role": "detection-candidate",
        "source": "endpoint",
        "content": "SELECT device_hostname, process_name, process_cmd_line, parent_process_name, time FROM hb_process_activity WHERE (LOWER(parent_process_name) LIKE '%node%' OR LOWER(parent_process_name) LIKE '%bun%' OR LOWER(parent_process_name) LIKE '%envoy%') AND instr(',' || '{{suspicious_shells}}' || ',', ',' || LOWER(process_name) || ',') > 0 AND ('{{scope_hosts}}' = '' OR instr(',' || '{{scope_hosts}}' || ',', ',' || device_hostname || ',') > 0) AND time >= datetime('now', '-{{lookback_days}} days')",
        "surface": "hb_process_activity",
        "description": "Identify active exploitation by looking for shell processes spawned directly from the affected applications or memory corruption crashes.",
        "expected_signal": "Any shell spawned from Node.js is an immediate high-fidelity indicator of RCE. Silence is evidence of absence for this specific technique."
      },
      "parents": [
        {
          "id": "rare-version-prevalence"
        }
      ],
      "primitive_config": {
        "dsl": "sqlite",
        "role": "detection-candidate",
        "label": "Detect post-exploit behavior and crashes",
        "reads": [
          "device_hostname",
          "process_name",
          "process_cmd_line",
          "parent_process_name",
          "time"
        ],
        "source": "hb_process_activity",
        "target": "endpoint",
        "content": "SELECT device_hostname, process_name, process_cmd_line, parent_process_name, time FROM hb_process_activity WHERE (LOWER(parent_process_name) LIKE '%node%' OR LOWER(parent_process_name) LIKE '%bun%' OR LOWER(parent_process_name) LIKE '%envoy%') AND instr(',' || '{{suspicious_shells}}' || ',', ',' || LOWER(process_name) || ',') > 0 AND ('{{scope_hosts}}' = '' OR instr(',' || '{{scope_hosts}}' || ',', ',' || device_hostname || ',') > 0) AND time >= datetime('now', '-{{lookback_days}} days')",
        "silence": "evidence_of_absence",
        "expected": "Any shell spawned from Node.js is an immediate high-fidelity indicator of RCE. Silence is evidence of absence for this specific technique.",
        "verified": "dry-run",
        "verified_at": "2026-11-18"
      }
    },
    {
      "id": "agent-triage",
      "type": "analytic",
      "label": "Evaluate exposure and behavior",
      "config": {
        "cite": "required",
        "tools": [
          "endpoint"
        ],
        "context": [
          "vulnerable-inventory-scope",
          "rare-version-prevalence",
          "suspicious-behavior-triage"
        ],
        "objective": "Identify which hosts are both exposed (running vulnerable versions) and showing suspicious activity (rare versions, shell spawning).",
        "description": "Correlate the presence of vulnerable versions with the prevalence outliers and any suspicious behavioral signals.",
        "max_iterations": 3,
        "success_criteria": "A risk-ranked list of hosts with confirmed exposure and any indicators of exploitation."
      },
      "parents": [
        {
          "id": "suspicious-behavior-triage"
        }
      ]
    },
    {
      "id": "risk-decision",
      "type": "checkpoint",
      "label": "Route by risk level",
      "config": {
        "fuzzy": true,
        "judge": "hunter",
        "question": "the agent finds hosts with vulnerable versions that also show suspicious shell activity or represent rare, unpatched version outliers in the fleet",
        "condition": "the agent finds hosts with vulnerable versions that also show suspicious shell activity or represent rare, unpatched version outliers in the fleet",
        "blind_spot": "inventory-coverage-gap",
        "confidence": "high",
        "description": "Determine whether the evidence warrants an immediate remediation task or a standard close-out.",
        "checkpoint_type": "mandatory"
      },
      "parents": [
        {
          "id": "agent-triage"
        }
      ]
    },
    {
      "id": "remediation-review",
      "type": "task",
      "label": "Prioritize patching and investigation",
      "config": {
        "assignee": "analyst",
        "description": "Address the high-risk exposure identified by the hunt.",
        "instructions": "Upgrade affected Node.js instances to fixed releases (22.23.4, 24.22.1, or 26.12.1). For any host showing shell spawning from a Node.js parent, immediately initiate an incident response investigation to determine the extent of the compromise."
      },
      "parents": [
        {
          "id": "risk-decision",
          "branch": "on_supports"
        },
        {
          "id": "risk-decision",
          "branch": "default"
        },
        {
          "id": "risk-decision",
          "branch": "on_unavailable"
        }
      ]
    },
    {
      "id": "close-out",
      "type": "task",
      "label": "Finalize hunt report",
      "config": {
        "assignee": "analyst",
        "description": "Document findings and identify remaining blind spots.",
        "instructions": "Record the number of vulnerable vs. patched hosts. Summarize any suspicious activity found. Provide the list of unpatched systems to the patching team."
      },
      "parents": [
        {
          "id": "risk-decision",
          "branch": "on_refutes"
        },
        {
          "id": "remediation-review"
        }
      ]
    }
  ]
}