[engineeringblog.yelp.com] CRLF Injection
A CRLF injection in the request URI allowed an attacker to inject a Set-Cookie header into the HTTP response. This could set a cookie for the entire yelp.com domain.
- Disclosed after 2.4 years
CRLF Injection via Request-URI
PoC:
https://engineeringblog.yelp.com/xxcrlftest%0d%0aSet-Cookie:%20test=test;domain=.yelp.com
HTTP Response:
HTTP/1.1 301 Moved Permanently
...
Location: http://engineeringblog.yelp.com/xxcrlftest
Set-Cookie: test=test;domain=.yelp.com
Result: Creating a cookie-param "test=test" on *.yelp.com
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 failed to sanitise CRLF characters in the request URI before using it in the Location header.
What the attacker needed
Attacker sends a crafted request
How it was found
- Send a request to the engineering blog with a crafted path containing encoded CRLF and a Set-Cookie header.
- Observe the 301 response containing the injected Set-Cookie header.
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 builds a redirect response, it copies part of the requested URL into a header. If the URL contains special newline characters, an attacker can sneak in extra headers. Here, that let the attacker set a cookie that would be sent to every yelp.com subdomain.
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.