Gunicorn HTTP Request/Response Smuggling vulnerability
Gunicorn 21.2.0 fails to properly validate the Transfer-Encoding header, falling back to Content-Length, which enables TE.CL request smuggling. An attacker could exploit this to poison caches, expose data, manipulate sessions, and cause other impacts.
benoitc/gunicorn
Originally disclosed on huntr
Gunicorn version 21.2.0 does not properly validate the value of the 'Transfer-Encoding' header as specified in the RFC standards, which leads to the default fallback method of 'Content-Length,' making it vulnerable to TE.CL request smuggling. This vulnerability can lead to cache poisoning, data exposure, session manipulation, SSRF, XSS, DoS, data integrity compromise, security bypass, information leakage, and business logic abuse.
From the GitHub Advisory Database (GHSA-hc5x-x2vx-497g, CC BY 4.0).
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely the server does not reject or correctly parse non-standard Transfer-Encoding values, defaulting to Content-Length and creating a parsing discrepancy with front-end proxies.
Impact
This could lead to cache poisoning, data exposure, session manipulation, SSRF, XSS, DoS, data integrity compromise, security bypass, information leakage, and business logic abuse.
What the attacker needed
Gunicorn 21.2.0 behind a proxy; Attacker can send crafted HTTP requests
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 report has not been written yet. The Original tab links to the source.
When a web server and a proxy sit in front of an application, they must agree on where one HTTP request ends and the next begins. Gunicorn mishandles a header that tells it the request body length, so an attacker can craft a request that the proxy sees as one request but Gunicorn sees as two. This mismatch lets the attacker sneak in a second request that other users might receive.
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.