HTTP Request Smuggling
Two HTTP components on the same connection disagree about where one request ends and the next begins, so an attacker’s bytes are reinterpreted as the prefix of another user’s request.
What it is
Smuggling (a.k.a. HTTP desync) is a parser differential on message framing. A request chain — browser → CDN/WAF → reverse proxy / API gateway → origin — reuses a small pool of upstream connections to carry many users’ requests. HTTP/1.1 delimits a body two ways: Content-Length (CL, a byte count) and Transfer-Encoding: chunked (TE, a 0\r\n\r\n terminator). When the front-end and back-end derive the boundary differently, the back-end’s view of the stream shifts: leftover bytes from the attacker’s request are prepended to the victim’s. The trust boundary that breaks is request isolation — HTTP/1.1 never isolated concurrent requests on a keep-alive socket; it assumed every hop agrees on byte framing (HTTP Terminator, HTTP Request Smuggling in API Gateways). CWE-444 (Inconsistent Interpretation of HTTP Requests).
Why it matters
Impact is near-worst-case and usually cross-user, unauthenticated, and automatable:
- Response Queue Poisoning (RQP) — the front-end loses track of which response belongs to which request, streaming other users’ responses (session cookies, API keys, PII) to the attacker while DoSing everyone else (CRLF-Powered Desync).
- Prefix injection — redirect victims’ JS includes to an attacker origin → stored XSS / mass account takeover with no interaction (Netflix, HTTP/2: The Sequel).
- Control bypass — smuggled requests skip gateway auth, rate limits, and path ACLs in a single step (API Gateway Security, Header-Based Access Control Bypass).
- Capturing other users’ requests, cache poisoning that persists the malicious response for everyone, and
Set-Cookieinjection to session-fixate the victim.
Max bounties are routine: $20k (Netflix), $15k×triple (Atlassian Jira), $6.5k first-timer on Slack (Two Rulers, One Wire).
How it works
Every variant is one question: which component wins the framing disagreement, and in which direction?
- CL.TE and TE.CL Desync — classic HTTP/1.1. One hop honors
Content-Length, the otherTransfer-Encoding. Includes TE.TE (obfuscated TE that one parser rejects), CL.0 (back-end ignores the body entirely), and the early-response gadget that breaks the 0.CL deadlock. - HTTP/2 Downgrade Smuggling — a front-end speaks HTTP/2 (frame-length framing, unambiguous) but rewrites to HTTP/1.1 upstream. H2.CL / H2.TE arise when the downgrade trusts an attacker-supplied CL/TE; HTTP/2’s binary headers also permit CRLF, colons, and spaces in places HTTP/1 forbids, enabling header/request-line injection.
- Client-Side and Connection-Locked Desync — CRLF-powered desync from header-injection primitives (request splitting), plus connection-locked / IP-locked / browser-powered desyncs that shift execution into the victim’s browser when cross-connection poisoning is blocked, and the connection-reuse bugs behind them.
- AI-Discovered Desync — the HTTP Terminator’s autonomous cascade: dual-matching CL,
multipart/byterangesCL.0, the dangling-byte RQP technique, Response Forking, and Shared-Parser Confusion (a server reuses one parser for requests and responses).
Request tunnelling is the sibling primitive: when the front-end never reuses back-end connections, you can’t hit other users, but you can still smuggle a request fully unprocessed by the front-end (bypassing path rules, leaking/forging internal headers). Confirm it with the HEAD technique, not the “send a flurry” test, which always false-negatives (HTTP/2: The Sequel).
Where to find it
- Architecture smell: any CDN / WAF / reverse proxy / API gateway in front of an origin, especially one that downgrades HTTP/2→HTTP/1.1 upstream or multiplexes many clients over shared back-end connections.
- Servers/proxies with a history: AWS ALB & API Gateway, Imperva Cloud WAF, Netlify, F5 BIG-IP, PulseSecure vTM, Netty/Zuul, HAProxy, Varnish, Apache Traffic Server, nginx (CRLF via
$uriinproxy_pass), Hiawatha, Jetty, Envoy, Go net/http, Caddy, nghttpx, Citrix NetScaler. - Primitives that upgrade: any reported “HTTP request header injection” / CRLF — it is badly underestimated and often a critical desync (Making header injection critical with one prompt).
How to test
- Baseline. Pick a request with a stable response. Establish connection-reuse behavior (does your prefix reach your own later requests only, all users, or nobody?).
- Trigger detection by timeout. Send a request whose framing makes the back-end wait for bytes that never arrive; a hang confirms a parsing disagreement. This is how HTTP Request Smuggler and Burp Scanner detect CL.TE/TE.CL/H2.x.
- Differential probing. For HTTP/2, see HTTP/1 headers inside the H/2 response body = desync. For tunnelling, use HEAD and look for a leaked
Content-Lengthof the smuggled response. - Confirm safely with a self-targeting prefix before any cross-user payload — smuggling exactly two complete requests gives triagers undeniable evidence without harming users.
- Scope the direction (CL.TE vs TE.CL vs CL.0 vs H2.x) and the isolation model before weaponizing.
Checklist:
- Map the proxy chain and whether HTTP/2 is downgraded upstream.
- Timeout-test CL.TE, TE.CL, TE.TE, CL.0, H2.CL, H2.TE.
- Test obfuscated TE (
xchunked, tab/space, line-folding, duplicate headers). - Probe header smuggling via mutated header names (space-suffix, underscores, invalid bytes).
- Determine connection reuse (cross-user vs connection-locked vs IP-locked vs tunnelling-only).
- If header injection / CRLF is reported, escalate to request splitting → RQP.
- Test method/path handling: methods allowed a body,
GET /adminrequest-line injection.
Exploitation and escalation
- RQP → harvest other users’ responses (cookies, tokens). See CL.TE and TE.CL Desync, Client-Side and Connection-Locked Desync.
- Prefix / resource redirect → malicious JS → ATO, often via the HEAD gadget to force a cached XSS. Links Account Takeover, DOM-Based XSS.
- Capture victim requests into a stored/reflected gadget (profile field) to steal credentials in bulk.
- Cache poisoning → persist the malicious response to every visitor (Web Cache Poisoning).
- Bypass front-end authz and reach internal endpoints / IDOR (HTTP Smuggling + IDOR, BOLA in APIs, Header-Based Access Control Bypass).
- Internal header forging via tunnelling — smuggle
X-Forwarded-For, auth/identity headers past the front-end’s rewrite; discover their names with Param Miner.
Bypassing defenses
- TE obfuscation (
Transfer-Encoding: xchunked, trailing tab/space, line-folding, header duplication) defeats front-ends that pattern-match TE instead of parsing it. \n-only vs\r\n— blocking\r\nbut not a bare\nis a classic failed hotfix;\nalone usually suffices.- HTTP/2 charset smuggling — inject CRLF, colons-in-names, or spaces-in-method through binary H/2 that re-imposed HTTP/1 limits fail to reject.
- Header-name mutation slips
Content-Length/X-Forwarded-Forpast one parser in the chain (Practical HTTP Header Smuggling). - WAF
%0d%0afilters are beaten with Unicode normalization / encoding tricks on the injection point (CRLF-Powered Desync).
Real-world cases
- Netflix / Netty (CVE-2021-21295) — H2.CL, JS hijack, $20k (HTTP/2: The Sequel).
- AWS ALB / Verizon / AOL — H2.TE, OAuth code & bearer-token theft; Atlassian Jira (PulseSecure vTM) — RQP leaking sessions, global session expiry, $15k×3; Netlify CDN / F5 BIG-IP / Imperva affected (same source).
- Slack
slackb.com— CL.TE, session-cookie theft, Evan Custodio, $6.5k (Two Rulers, One Wire). - Hiawatha ≤12.1 (CVE, CWE-444) — prioritizes CL over TE and forwards both; fixed in 12.2 (HTTP Request Smuggling in Hiawatha).
- Varnish (CVE-2021-36740) — H2 request smuggling via H/2→H/1 rewrite (Varnish H2 smuggling).
- HAProxy — CVE-2023-40225 (empty CL) and CVE-2024-53008 (CL/TE ACL bypass); Apache mod_proxy request-line injection (CVE-2021-33193) (API Gateways, HTTP/2: The Sequel).
- Apache Traffic Server (CVE-2026-63078) and dual-CL bugs on Meta/bank/SSO/Citrix NetScaler infra, found autonomously (HTTP Terminator).
- IDOR chain — CL.TE smuggles
GET /admin…to the back-end as the next user’s request (HTTP Smuggling + IDOR); first-bug CL.TE writeup (Finding My First Bug). - PHP-FPM request smuggling CVE-2026-129289 (present since PHP 5.6.0), fixed in the 2026-11-19 PHP release alongside phpAfterShell; keep FPM listeners off untrusted networks and disable FastCGI connection reuse. (source)
Prevention
- Use HTTP/2 (or higher) end-to-end. Never downgrade to upstream HTTP/1.1 — this is the root-cause fix (HTTP/2: The Sequel, HTTP Terminator).
- Reject ambiguous framing: any request with both CL and TE, duplicate/empty CL, obfuscated TE, or (downgrading) CRLF/colon-in-name/space-in-method. Normalize before forwarding.
- Allow-list request methods on both front-end and back-end, and separately allow-list which methods may carry a body (effectively POST/PUT/PATCH only) — the two extra Terminator recommendations.
- nginx: avoid
$uri/$document_uriinproxy_pass/returnto kill CRLF injection into the upstream request. - Disable back-end connection reuse where HTTP/1.1 upstream is unavoidable; it blocks cross-user contamination at a performance cost.
- Patch proxies/servers to current versions; verify header-normalization rules survive every config and library change.
Tools
- HTTP Request Smuggler (Burp) — detection + exploit for CL.TE/TE.CL/TE.TE/H2.x/CL.0, HEAD tunnelling, request-contamination checks. Burp Suite Extensions.
- Turbo Intruder — the
BURP/HTTP2engines for desync, RQP and single-packet timing; now with an MCP interface (Turbo Intruder). - Param Miner — guesses internal/secret header names, protocol-ruler analysis.
- Burp Scanner / Burp AT — automated desync + CRLF-desync skills (Burp AI and MCP).
- HTTP Terminator — PortSwigger’s open-source autonomous desync research factory.
- Hackvertor — encoding for CRLF injection points. Burp Collaborator for blind OAST (Burp Collaborator).
Sub-pages
- CL.TE and TE.CL Desync — classic HTTP/1.1 framing disagreements, TE.TE, CL.0 and the early-response gadget.
- HTTP/2 Downgrade Smuggling — H2.CL / H2.TE from HTTP/2→HTTP/1.1 downgrade and binary-header injection.
- Client-Side and Connection-Locked Desync — CRLF-powered / request-splitting desync, browser-powered, connection-locked, IP-locked, and connection-reuse bugs.
- AI-Discovered Desync — the HTTP Terminator cascade: dual-CL, multipart/byteranges, dangling-byte RQP, Response Forking, Shared-Parser Confusion.
Related
- API Gateway Security · Header-Based Access Control Bypass · Web Cache Poisoning · Web Exploitation Talks · Vulnerability Chaining · Account Takeover · Session Management · BOLA in APIs · DOM-Based XSS
Sources
- Can AI do novel security research? Meet the HTTP Terminator · original
- CRLF-Powered Desync Attacks: Beheading HTTP Streams · original
- HTTP/2: The Sequel is Always Worse · original
- HTTP Request Smuggling in API Gateways · original
- Advanced request smuggling · original
- Smuggling Shouldn't Exist Anymore, Right? (connection reuse) · original
- Practical HTTP Header Smuggling · original
- HTTP Request Smuggling in Hiawatha · original
- HTTP Request Smuggling IDOR · original
- Finding My First Bug: HTTP Request Smuggling · original
- Two Rulers, One Wire: HTTP Desync on Slack · original
- Varnish HTTP/2 request smuggling · original
- Making HTTP header injection critical with one prompt · original
- The Most Overlooked Vulnerability — HTTP Request Smuggling · original
- Exploiting HTTP Parsers Inconsistencies · original
- HTTP Terminator: an AI system proposed a new desync attack class · original
- James Kettle's Autonomous Research Cascade · original
- How Cloudflare WAF helps protect against phpAfterShell and other critical PHP flaws · original