Skip to content
Cache bugs Write-up Intermediate

Responsible denial of service with web cache poisoning

Web cache poisoning could be used to make a single request that stores an error or redirect response in the cache, so every later visitor to that URL received the broken response. This let an attacker persistently deny access to parts of sites such as Tesla, HackerOne, Bitbucket, PayPal and Twitter.

James Kettle Follow

Published on portswigger.net

Bounty$22,300total stated by author View original

In this post, I'll tell the story of how I came to love denial of service attacks, and show you how to use web cache poisoning to take down websites with a single request while earning bug bounties along the way.

James Kettle (@albinowax), 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 cache key ignored certain request headers, so responses generated from those headers (such as WAF blocks, redirects or errors) were stored and served to all users.

Impact

Attackers could persistently deny access to pages or core JavaScript files for all visitors with a single request, though some programs declined to patch or pay for the issue.

What the attacker needed

A cache-buster parameter; a header the cache ignores

The fix

Caches should include all headers that affect the response in the cache key, or avoid caching error and redirect responses.

How it was found

  1. Send a request to a target URL with a cache-buster parameter so the poisoned entry is not seen by real users.
  2. Add a header that the cache does not include in its key but the backend reacts to, such as a forwarded-port or transfer-encoding header.
  3. Observe the error, redirect or block response being stored in the cache for that URL.
  4. Request the same URL without the cache-buster to confirm other visitors receive the poisoned response.

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 website cache is a shared store that keeps a copy of a page so it can be served quickly to everyone. If an attacker can make the cache save a broken or blocked response for a normal URL, then every visitor gets that broken copy until it expires. This is called web cache poisoning, and here it was used to make pages unavailable rather than to steal data.

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 James Kettle

View all

10 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.