️♂️ The Dark Web Knew Before the Company Did: Finding a
An authenticated API endpoint was cached publicly by a CDN, and the backend trusted headers like X-Forwarded-Host, allowing cache poisoning. An attacker could poison the cache to serve sensitive internal data to unauthenticated users, potentially leading to account takeover and privilege escalation.
Free Link🎈
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 the CDN cached responses for an authenticated endpoint without considering authorization headers, and the backend trusted user-supplied headers like X-Forwarded-Host, allowing cache poisoning.
Impact
This could lead to full account takeover, sensitive internal API exposure, privilege escalation, and cache poisoning affecting all users.
What the attacker needed
Valid authentication token; CDN caching enabled; backend trusts X-Forwarded-Host
How it was found
- Send a request to the preview endpoint and observe cache headers indicating public caching.
- Send a poisoning request with a valid token and a manipulated X-Forwarded-Host header.
- Send an unauthenticated request to the same endpoint and receive a cached response.
- Replay the cached response across different accounts to access sensitive data.
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.
A CDN (content delivery network) stores copies of web pages to serve them faster. If a page meant only for logged-in users is stored publicly, anyone can see it. Here, the server also trusted a header that could be manipulated to poison the stored copy with sensitive information.
What is Cache bugs?
A cache and the origin disagree about a request, so a poisoned response is served to everyone or a private page is stored as public.