Skip to content
Cache bugs Write-up Advanced

Gotta cache 'em all: bending the rules of web cache exploitation

The paper describes how discrepancies in URL parsing between web caches and origin servers can be exploited to achieve arbitrary web cache deception and poisoning. An attacker could hijack sensitive information or store malicious payloads by crafting URLs that are interpreted differently by the cache and the origin.

Martin Doyhenard Follow

Published on portswigger.net

Through the years, we have seen many attacks exploiting web caches to hijack sensitive information or store malicious payloads. However, as CDNs became more popular, new discrepancies between proprietary URL parsers prove that we have only seen the tip of the iceberg.

Martin Doyhenard (@tincho_508), on portswigger.net

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 root cause is that different HTTP servers and caches parse URLs inconsistently, especially regarding delimiters and normalization, leading to path confusion.

Impact

An attacker could hijack sensitive information or store malicious payloads, depending on cache rules and configurations.

What the attacker needed

Cache and origin parser discrepancy

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.

Web caches store copies of web pages to make websites faster. If a cache and the website's server disagree about what a URL means, an attacker can trick the cache into storing private data or malicious content. This can let them steal information or attack other users.

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.

More by Martin Doyhenard

View all

2 more disclosed reports, best first.

Similar reports

View all

Same bug class and techniques, clearest first.

Web cache poisoning and deception

The lesson behind this report.

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.