Skip to content

fix(vuln): reduce SSTI false positives with unique canary + baseline - #186

Open
weibalangzi wants to merge 1 commit into
awarexone:mainfrom
weibalangzi:fix/ssti-unique-canary-baseline
Open

weibalangzi wants to merge 1 commit into
awarexone:mainfrom
weibalangzi:fix/ssti-unique-canary-baseline

Conversation

@weibalangzi

Copy link
Copy Markdown

Summary

  • Phase SSTI probes previously treated reflection of 7*7 → 49 as confirmation via grep -qE '(\\b49\\b|7777777)'.
  • That pattern false-positives on ordinary page content (CSS values, durations, IDs, etc.) and on reflected-but-unevaluated payloads.
  • Switch payloads to a unique math canary (739391*739391 → 546699042881).
  • Fetch an uninjected baseline first; skip URLs whose baseline already contains the canary, and only confirm when the canary appears after injection.

Test plan

  • bash -n bughunter/tools/vuln_scanner.sh
  • On a benign page that contains 49 in HTML/CSS, confirm Check 4 no longer reports [SSTI-CONFIRMED]
  • On a known SSTI lab/endpoint (if available), confirm the unique canary still triggers [SSTI-CONFIRMED]
  • Baseline skip path: if a URL body already contains 546699042881, the URL is skipped without confirmation

Made with Cursor

Matching \b49\b from 7*7 probes false-positives on normal page content.
Use a unique product canary (739391*739391) and require it to be absent
from an uninjected baseline response before confirming SSTI.

Co-authored-by: Cursor <cursoragent@cursor.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