mcpField
P
pentest-http-smuggling

pentest-http-smuggling

github.com/jd-opensourceSecurity31547 installsUpdated 28w ago
Repository

About pentest-http-smuggling

A security-testing skill for authorized assessments of HTTP request smuggling and related host-header and cache attacks. It guides testers through proxy fingerprinting, protocol-specific tests, and impact validation.

Key features

  1. 01Proxy and stack fingerprinting
  2. 02CL.TE, TE.CL, and TE.TE testing
  3. 03HTTP/2 downgrade testing
  4. 04Cache poisoning and Host header tests
  5. 05Impact validation with proof of concept

Use cases

  1. 01Assessing proxy and backend parsing discrepancies
  2. 02Testing HTTP/2-to-HTTP/1 translation
  3. 03Validating cache poisoning risks
  4. 04Documenting request hijacking impact

Install

Copy the command and run it in a terminal.

$npx skills add https://github.com/jd-opensource/joysafeter --skill pentest-http-smuggling

After installing, type/pentest-http-smugglingin Claude Code to confirm it loaded.

Bundled filesreferences/tools.mdreferences/workflows.md

Details

From the project README

Pentest HTTP Smuggling

Purpose

Detect and exploit discrepancies between front-end proxies and back-end servers in HTTP request parsing. These attacks bypass security controls, poison caches, and hijack requests — entirely absent from standard taint analysis pipelines.

Prerequisites

Authorization Requirements
  • Written authorization with explicit scope for protocol-level testing
  • Infrastructure awareness — identify all reverse proxies, CDNs, load balancers in path
  • Rollback plan for cache poisoning tests (CDN purge access)
  • Emergency contacts for infrastructure team (smuggling can affect other users)
Environment Setup
  • Python 3.x with raw socket capability for crafted HTTP requests
  • Burp Suite Professional with HTTP Request Smuggler extension
  • curl compiled with HTTP/2 support (--http2-prior-knowledge)
  • Turbo Intruder for timing-sensitive attacks
  • Network capture tool (Wireshark/tcpdump) for response analysis

Core Workflow

  1. Stack Fingerprinting: Identify reverse proxies (nginx, HAProxy, Cloudflare, AWS ALB), CDNs, load balancers. Determine HTTP version support (HTTP/1.1, HTTP/2) and parsing behavior.
  2. CL.TE Smuggling: Craft requests where front-end uses Content-Length and back-end uses Transfer-Encoding. Observe differential parsing and request boundary confusion.
  3. TE.CL Smuggling: Reverse scenario — front-end uses Transfer-Encoding, back-end uses Content-Length. Test with obfuscated TE headers.
  4. TE.TE Smuggling: Both sides use Transfer-Encoding but one can be confused with header obfuscation (capitalization, whitespace, duplicate headers).
  5. HTTP/2 Downgrade: Exploit H2-to-H1 translation at reverse proxies. Header injection via pseudo-headers, CRLF injection in H2 headers, request splitting through H2 CONTINUATION frames.
  6. Cache Poisoning: Poison cached responses with attacker-controlled content. Test cache key vs cache content discrepancies. Verify with different client sessions.
  7. Host Header Attacks: Host header injection, password reset poisoning, routing-based SSRF, web cache poisoning via ambiguous Host headers (WSTG-INPV-17).
  8. Impact Validation: Demonstrate cache poisoning, credential theft, request hijacking, or security control bypass as PoC.

WSTG Coverage

WSTG IDTest NameStatus
WSTG-INPV-15HTTP Request Smuggling✅
WSTG-INPV-17Host Header Injection✅

Tool Categories

CategoryToolsPurpose
Smuggling Detectionsmuggler.py, HTTP Request Smuggler (Burp)Automated CL.TE/TE.CL detection
HTTP/2 Testingh2csmuggler, curl --http2, nghttpH2 downgrade and desync attacks
Timing AttacksTurbo IntruderMicrosecond-precision request timing
Raw RequestsPython sockets, netcatCrafted malformed HTTP requests
Cache Analysiscurl, custom scriptsCache behavior verification
Traffic CaptureWireshark, tcpdumpResponse boundary analysis

References

  • references/tools.md - Tool function signatures and parameters
  • references/workflows.md - Attack pattern definitions and test vectors

Comments

Markdown supported