Bug class · Advanced
Web cache poisoning and deception
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.
- median public bounty
- $1,060
How it works
Full lessonThe pattern behind every report in this class.
Web cache poisoning and deception are attacks that abuse the shared caches sitting between users and a web application. In poisoning, an attacker manipulates a request so that the cache stores a harmful response, which is then served to other visitors. In deception, the attacker tricks the cache into storing a victim's private data, which they can later retrieve. These issues matter to bug bounty programs because a single poisoned cache entry can affect many users at once, turning a minor input handling flaw into a widespread compromise. Reports in this dataset cover both variants across blogs, help sites, download subdomains, APIs, sign-in pages, e-commerce and profile pages, often behind Cloudflare and other CDNs. [#17082, #16054, #18559, #20042, #9496, #33372]
Programs care because cache poisoning can lead to stored cross-site scripting, credential theft, session hijacking and malware distribution, while cache deception can expose personal data, CSRF tokens and authentication tokens. The impact is amplified by the cache's reach: one poisoned response can be served to every user who requests the same resource. Common root causes include unkeyed headers being reflected into responses, cache keys that ignore parts of the request, and caches that store error pages or sensitive content based on file extensions. These mistakes appear in features like generated JavaScript files, preview endpoints, raw snippet views, API responses and authenticated pages. [#14266, #14560, #14785, #15263, #16384, #18559, #20042, #28483]
The attack starts with the cache key, the set of request components the cache uses to decide whether two requests are the same. If a header, query parameter or other input influences the response but is not part of the cache key, an attacker can vary that input to poison the stored response. For example, the X-Forwarded-Host header was used to build absolute links but was not included in the cache key, so an attacker could make the cached page point to their domain. Similarly, the Origin header was omitted from the cache key, allowing a response tailored to one origin to be served to others. [#16384, #17082, #15263]
Another common enabler is insufficient validation or normalisation of inputs that end up in cached responses. Array parameters copied into generated JavaScript without validation, or parameter values reflected verbatim into a cached file, let an attacker corrupt the cached content. Length checks that count decoded characters rather than encoded bytes can be bypassed with multi-byte characters, allowing a longer payload to be reflected. Path traversal sequences that are not normalised can cause a sensitive response to be cached under a shareable path. [#14266, #14560, #14561, #21591, #28483]
Things to try
All 44Each line worked in a disclosed report. Test only what a program's scope allows.
Host and forwarded headers 10
- Send repeated requests with an X-Forwarded-Host header set to a domain you control, then request the same URL without the header to see whether the malicious hostname appears in the cached response.
- Send repeated requests to a blog page with a spoofed X-Forwarded-Host header and check whether links in the cached page point at your domain.
- Send X-Forwarded-Port and X-Forwarded-Host headers to a cacheable URL and check whether redirects pointing at an invalid port or host get cached.
- Send an invalid app-instance routing header with a cache-busting query string and check whether the resulting 404 is cached and served to cookieless visitors.
Path and extension tricks 7
- Request a dynamic cart or checkout page with an extra character such as a plus, minus or dot before the path, and check whether the no-cache headers disappear and cart cookies are set.
- Craft a product URL containing a path traversal sequence after another product ID and check whether the cached entry replaces the legitimate product with the attacker's.
- Append an image extension to a search URL that reflects a session token, then request the same URL from another browser and check whether the cached token can be reused.
- Craft a URL with an encoded path traversal under a cached share path that resolves to a sensitive API endpoint, get a victim to visit it, then retrieve their auth token from the cache.
Authenticated page caching 6
- Request a public board page without cookies after a signed-in visitor has loaded it and check whether their user id, CSRF token, CSP nonce and timezone are returned from the edge cache.
- Visit a URL ending in a non-existent CSS file while logged in, then open it in a private window and check whether the cached page shows the user as logged in and leaks their details.
- Append a non-existent file extension to an authenticated page URL, get a victim to open it, then visit the same URL and check whether their email, name and CSRF token are in the cached response.
- Trick a user into opening a link on a subdomain and then request the same URL to see whether user-specific content was cached.
Error and redirect caching 5
- Send a crafted URL that makes the server redirect to itself with an added trailing slash and check whether the redirect loop is cached for all visitors.
- Send a crafted Authorization header to a file download URL and check whether the resulting 403 is cached and served to users without the header.
- Send a request with an oversized custom header to a test path and check whether the resulting 400 response is cached and returned for later normal requests.
- Send an unkeyed trailer header to a file download URL and check whether a malformed 400 response is cached for the legitimate file.
Header and version negotiation 4
- Send a request to a framework page with an internal prefetch header and check whether an empty JSON object or error page with a 200 status is cached.
- Send requests to a JSON API endpoint with different Origin headers and a unique query string, then check whether a response tailored to one origin is served to requests from other origins.
- Send an Accept-Version header to a route that is not versioned behind a CDN and check whether the resulting 404 is cached for the normal URL.
- Advertise an HTTP/3 alternative, then send Alt-Svc: clear and check whether a client keeps sending later requests to the separate backend.
Bypasses and variations
- Bypass a decoded-character length limit by using multi-byte UTF-8 characters that expand to many URL-encoded bytes, then check whether the reflected value still poisons the cached file.
- Append an .avif extension to a crafted URL and check whether the edge cache stores normally non-cacheable sensitive content.
- Send more than 94 arbitrary headers and then append a header normally part of the cache key to see whether cache key evaluation and WAF rules are skipped.
Typical fixes
- Restrict caching to specific addresses so dynamic pages are not stored
Tips for beginners
All 11- Start by identifying which parts of a request are reflected in the response but are not part of the cache key. Common candidates are headers like X-Forwarded-Host, X-Forwarded-Port, Origin and other custom headers. Send requests with these headers set to a domain you control and then request the same URL without them to see if the cached response contains your domain. [#16054, #17082, #16384, #14785]
- Look for endpoints that generate JavaScript or other static files from parameters. If a parameter value is copied into the file without validation, you may be able to poison the cached file. Test with array parameters or special characters and check whether the corrupted output is served to normal requests. [#14266, #14560]
- Test whether error responses are cached. Send requests that trigger 400 or 404 errors with a cache-busting parameter and then request the same URL normally to see if the error is served. This can be done with malformed headers, invalid routing headers or oversized headers. [#18213, #20180, #17446]
- For cache deception, try appending a static file extension such as .css or .avif to an authenticated page URL. Visit the URL while logged in, then open it in a private window or another browser to see if your personal data or CSRF tokens are returned from the cache. Also try path traversal sequences to make sensitive API responses appear under a cached path. [#18559, #20042, #19213, #28483]
- Check whether the cache respects cache-control headers. For example, preview endpoints that should not be cached may still be stored. Vary a parameter on a preview endpoint and see if cached results for users who later made content private are still served. [#13712]
- When testing for poisoning, always use a cache-busting parameter to avoid affecting other users. Once you have a potential finding, demonstrate impact by showing that the poisoned response is served to a separate client without the malicious input. Avoid testing on production pages that many users visit. [#21966, #29460]
Start here: a reading path
Open the pathClear reports in order, easiest first.
-
1
Caching Trouble: The Public Cache That Leaked Private User DataBeginner
The endpoint returned personalised data with a Cache-Control header of public, max-age=86400 and lacked a Vary header, so shared caches stored and served the response to other users.
-
2
PURGE is not authenticatedBeginner
Likely the caching layer (Varnish) was configured to accept PURGE requests from any client without authentication or IP restriction.
-
3
Web Cache Deception : Comment j’ai volé la clé API d’un utilisateur avec Burp SuiteBeginner
Likely the cache keyed on the full URL including the static-looking extension, while the origin server ignored the extra path segment and returned the private page, so the private response was cached publicly.
-
4
$7,000 for Poisoning a Cache: Turning One Request Into Stored XSSIntermediate
The origin server trusted the client-supplied X-Forwarded-Host header when generating HTML without sufficient output encoding, and the CDN cache key excluded that header, so a single poisoned response was cached and served to all visitors.
-
5
Practical Web Cache PoisoningIntermediate
Likely the cache key does not include all request inputs that affect the response, so an attacker-controlled header can alter the cached response served to other users.
-
6
How I Took a Website Completely Offline with a Funky Cache PoisonIntermediate
Likely the CDN cached responses based on a small set of predictable cookie values, and the server returned an empty response when a specific header was present, allowing an attacker to poison all cache variants.
-
7
Shopify.com Web Cache Deception vulnerability leads to personal information and CSRF tokens leakageIntermediate
The cache server classified responses as cacheable based solely on the URL extension (.css) without checking the actual content type, so it cached dynamic pages containing private data.
-
8
Bypass of Cloudflare's Cache Keys and WAF via header overflowIntermediate
Likely the HTTP header parser in Cloudflare's Front Line truncated requests at around 100 headers (including internal ones), so rulesets and cache-key evaluation never saw headers beyond that limit.
Guides and techniques
View allThe best explainers, cheat sheets and technique posts on Cache bugs, from around the web.
-
Cache key injection: Smuggling poison through the doorShows how cache key injection lets attackers smuggle poisoned responses past cache defences, with practical exploitation notes.
Technique YesWeHack
-
Web Cache DeceptionPortSwigger explains web cache deception, how cached responses leak private data and how to test for it.
Explainer portswigger.net
-
The Cache Poisoning Bible: Part 3 — Advanced Weaponization & Critical Impact ChainsThird part of a cache poisoning series covering advanced weaponisation and chaining to achieve critical impact.
Technique medium.com
-
HTTP header hacks: basic and advanced exploit techniques exploredExplores HTTP header exploitation including cache-poisoned denial of service, Vary abuse and reverse proxy misconfigurations with real examples.
Technique yeswehack.com
-
How to find SSTI, cache poisoning, business logic vulnerabilities: methodology tips from top Bug Bounty huntersTop hunters share recon and exploitation methodology for server-side template injection, cache poisoning and business logic flaws.
Methodology yeswehack.com
Highest paid
View allThe biggest public bounties for Cache bugs.
-
Stored XSS on https://paypal.com/signin via cache poisoningHigh PayPal HackerOne
$18,900 -
DoS on PayPal via web cache poisoningMedium PayPal HackerOne
$9,700 -
ChatGPT Account Takeover - Wildcard Web Cache DeceptionOpenAI (ChatGPT) Write-up
$6,500 -
Next.js and cache poisoning: a quest for the black holeVercel (NextJS) Write-up
$5,000 -
DoS Vulnerability via Cache Poisoning on cdn.shopify.com and shopify-assets.shopifycdn.comMedium Shopify HackerOne
$3,800 -
https://themes.shopify.com::: Host header web cache poisoning lead to DoSMedium Shopify HackerOne
$2,900 -
Denial of service via cache poisoningMedium HackerOne
$2,500 -
$2,250
Newest reports
All 262Most recently disclosed.
-
-
-
-
-
-
curl 8.23.0 keeps sending requests to an HTTP/3 backend after Alt-Svc: clearHigh curl HackerOne
-
`Vary` cache-key conflation of absent and empty request fieldsLow Django HackerOne
-
-
-
Microsoft Exchange Server Elevation of Privilege Vulnerability (CVE-2026-77910)High Microsoft Advisory
New Cache bugs reports by email
Follow Cache bugs and get each week's new disclosures in one short email.