In-depth lesson · Cache bugs
Tips for beginners
Every point the Cache bugs reports back under this heading, best-backed first, each with the reports it is seen in.
-
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]
Seen in 4 reports
-
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]
Seen in 4 reports
-
Consider less common headers and request smuggling techniques. Headers like Transfer-Encoding, trailers, or method override headers can sometimes be used to poison caches. Also test for HTTP/3 alternative service manipulation. [#15501, #18715, #18714, #867]
Seen in 4 reports
-
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]
Seen in 3 reports
-
Show real impact. A cache poisoning finding is only valuable if you can demonstrate that it affects other users, for example by stealing session tokens, CSRF tokens or personal data, or by serving malicious content. A reflected header without a cached effect is not enough. [#15263, #20042, #33372]
Seen in 3 reports
-
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]
Seen in 2 reports
-
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]
-
Document your steps clearly. Include the request and response showing the poisoned cache entry and how it is served to a different user. This helps triagers understand the impact quickly. [#17082, #18559]
-
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]
Seen in 1 report
-
Be careful about scope. Only test domains and endpoints that are explicitly in scope for the bug bounty program. Reporting an out-of-scope issue wastes time and may violate program rules. Also ensure your test does not cause denial of service or data loss. [#18014]
Seen in 1 report
-
If you find a cache key that ignores query strings or paths, try to poison a response with an unkeyed header that is reflected. This can lead to stored XSS or redirects. [#29460]