Web Cache Deception Attacks
What you'll learn: How attackers trick web caches into storing private user data as public content, exposing sensitive information to unauthorized users.
The Core Vulnerability
Web Cache Deception exploits the gap between how a web cache and an origin server interpret URLs. A cache might treat /account/profile.css as a static, cacheable file because it ends in .css, while the application server ignores the extension and serves the actual /account/profile page—with your private data.
The trick: The attacker sends you a malicious link to your account page with a fake static extension appended. When you visit it, the cache stores your authenticated content as if it were a public CSS file. The attacker then requests the same URL and retrieves your cached private data.
How the Attack Works
- Attacker crafts a URL:
https://bank.com/account/statements/style.css - Victim clicks the link while authenticated
- Application ignores the extension, serves the actual
/account/statementspage with sensitive data - Cache sees
.cssextension, stores the response as public static content - Attacker requests the same URL, receives the victim's cached private information
The Analogy
Imagine a library filing system where documents are sorted by their file extension. Someone tricks you into photocopying your confidential medical records under the filename "menu.pdf" because the cafeteria menu uses that name. The librarian files it publicly in the "Menu" section. Now anyone asking for "menu.pdf" gets your medical records instead.
Why It's Dangerous
Unlike cache poisoning (where you manipulate what gets cached), cache deception manipulates whose data gets cached as public content. The victim's authenticated session makes the request, but the cache serves it to everyone.
Key Takeaway: Web Cache Deception occurs when path confusion between caching layers and application logic causes private authenticated content to be cached and served publicly based on URL manipulation.