Escalating reflected XSS with HTTP Smuggling
A reflected XSS vulnerability was escalated to a site-wide, no-interaction XSS by exploiting a CL.TE HTTP request smuggling flaw. An attacker could poison responses so that other users receive the malicious script.
As with the majority of HTTP Smuggling, it started with a smuggle probe from Burp’s HTTP Request Smuggler Extension:
The full write-up lives on its author's site
It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely a discrepancy between front-end and back-end servers in how they interpret Content-Length and Transfer-Encoding headers, allowing request smuggling.
Impact
An attacker could poison responses so that nearly every user who visited the site would receive a malicious script, potentially leading to CSRF or CORS attacks.
What the attacker needed
CL.TE request smuggling vulnerability; reflected XSS vulnerability; ability to send crafted requests
How it was found
- Send a request with both Content-Length and Transfer-Encoding: chunked headers to test for CL.TE smuggling.
- Observe that sending the request twice returns a 404 for the second request, confirming the smuggled prefix was processed.
- Craft a Turbo Intruder payload that prepends a smuggled request containing the reflected XSS payload.
- Send the attack request followed by several victim requests to poison the next responses.
- Confirm that one of the subsequent responses contains the injected XSS.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
HTTP request smuggling is a trick where two servers in a chain disagree about where one request ends and the next begins. Here, the front-end server used one length header while the back-end used another, so extra data was treated as the start of the next user's request. That let the attacker inject a script into another user's page, turning a simple reflected cross-site scripting (XSS) bug into one that hits everyone.
What is Smuggling / CRLF?
A front end and a back end split one connection's bytes into requests differently, letting an attacker hide a request inside another user's.