Skillpedia
الأمان5.4k · #14898

hunt-cache-poison

ما الذي تفعله

تختبر هذه المهارة طبقات التخزين المؤقت وشبكات توصيل المحتوى بحثًا عن تسميم الذاكرة وخداع التخزين المؤقت. وهي للاختبار الأمني المصرّح به للمواقع التي تستخدم ذاكرة تخزين مؤقت أو شبكات توصيل محتوى.

متى تستخدمها

  • ✓عندما يقع الموقع خلف شبكة توصيل محتوى وتريد فحص طريقة تخزينه للاستجابات.
  • ✓عندما قد يُبنى رابط إعادة تعيين كلمة المرور من مضيف غير موثوق في ترويسة Host.
  • ✓عندما قد تُخزَّن صفحة خاصة في ذاكرة عامة عن طريق الخطأ.

رابط المهارة

https://github.com/elementalsouls/Claude-BugHunter/blob/main/skills/hunt-cache-poison/SKILL.md

انسخه والصقه في الذكاء الاصطناعي الذي تستخدمه (Claude أو ChatGPT أو Cursor) واطلب منه اتباع التعليمات.

طريقة الاستخدام

أسهل طريقة: انسخ الرسالة والصقها في الذكاء الاصطناعي الذي تستخدمه. سيقرأ المهارة وينفّذ تعليماتها.

رسالة جاهزة للصق

استخدم هذه المهارة لمساعدتي: https://github.com/elementalsouls/Claude-BugHunter/blob/main/skills/hunt-cache-poison/SKILL.md اقرأ ملف SKILL.md في هذا الرابط ونفّذ تعليماته لمهمتي.
تريد أن يجد الذكاء الاصطناعي مهارات مثل هذه بنفسه؟ثبّت خادم Skillpedia MCP المجاني: سطر واحد، ويبحث في 15,000+ مهارة قبل كل مهمة.ثبّته في دقيقة واحدة →

مثال على ما تطلبه من الذكاء الاصطناعي

“هل يمكنك فحص ما إذا كانت شبكة توصيل المحتوى لدينا قد تخزّن صفحة حساب خاصة، أو تقبل ترويسات مسمومة، في اختبارنا المصرّح به؟”

5 مهارات جديدة كل أسبوع. قراءة في دقيقة واحدة.

كيف تعمل

يرسل الوكيل طلبات بترويسات ومسارات غير معتادة، ثم يتحقق مما إذا كانت الاستجابة المسمومة أو الخاصة تُخزَّن وتُقدَّم لطلبات أخرى. ويؤكد النتيجة باختبار واضح.

المحتوى التقني (ملف SKILL.md الأصلي)

النص الأصلي من المؤلف، مباشرة من GitHub.

Crown Jewel Targets

Cache poisoning is high-value because a single poisoned cache entry can affect thousands or millions of victims simultaneously — one request, mass exploitation. Payout scales with blast radius.

Highest-value targets:

  • CDN-served assets (cdn.shopify.com, cloudfront distributions, Fastly/Akamai edges) — poisoning these affects every visitor globally
  • E-commerce platforms with affiliate/referral flows (Shopify, WooCommerce storefronts) — session hijack or affiliate fraud potential
  • Gaming platforms with update servers (rockstargames updates.* domains) — DoS on update delivery = widespread client breakage
  • Authentication endpoints served through caches — leads to account takeover (the highest severity variant)
  • Asset CDNs (JS/CSS delivery) — XSS payload delivery at scale
  • SaaS multi-tenant platforms — one poisoned response bleeds into all tenants sharing a cache key

Asset types that pay most: CDN hostnames, subdomain-per-tenant patterns, update/download servers, login/account pages cached incorrectly, affiliate link shorteners.


Autonomous Testing Priority

Two distinct attacks live under this skill — target the simpler one first.

Attack 1 — Password Reset Poisoning (Host header injection):

The app uses the Host header to construct the password reset link in the email. Inject an attacker-controlled hostname; the victim's reset email contains a link to your server.

POST /forgot-password
Host: attacker.com
X-Forwarded-Host: attacker.com
X-Host: attacker.com

email=victim@target.com
Content-Type: application/x-www-form-urlencoded

Use a distinctive hostname you control or can identify in the response. Proof: the injected hostname appears in the response body (some apps reflect the generated reset link), or the action succeeds (2xx with a "reset email sent" message) after injection — confirming the poisoned link would be sent to the victim.

Try multiple host headers — apps vary in which one they trust (X-Forwarded-Host is most common, but Host itself also works when the proxy passes it through).

Attack 2 — Web Cache Poisoning:

Inject the attacker-controlled hostname into X-Forwarded-Host on a GET request for a cacheable page. If the hostname is reflected in the response body AND the response gets cached, subsequent visitors receive the poisoned response.

Check for cache signals in the response: X-Cache: HIT, CF-Cache-Status: HIT, Age: <nonzero>, or Via: cloudfront/varnish/fastly.

Proof for both: injected value reflected in response body, or action completed successfully despite the manipulated header.


Attack Surface Signals

URL patterns to look for:

  • cdn., assets., static., updates., downloads. subdomains
  • URL path structures with extensions that look static: /path/to/page.css, /account.php/nonexistent.jpg
  • Affiliate/link shortener endpoints: /link/, /go/, /ref/, /out/
  • Paths that mix dynamic content with cacheable-looking URLs

Response headers that signal a cache:

X-Cache: HIT / MISS
X-Cache-Status: HIT
CF-Cache-Status: HIT / MISS (Cloudflare)
Age: <nonzero>
Via: 1.1 varnish / cloudfront / fastly
Cache-Control: public, max-age=...
Surrogate-Control: max-age=...
X-Served-By: cache-...

JS/tech stack signals:

  • Fastly, Varnish, Cloudfront, Akamai, Nginx proxy_cache in response headers
  • Shopify/Linkpop stacks with third-party integrations
  • Platforms using path-based routing without normalizing trailing segments
  • Servers that reflect unvalidated headers into responses (Host, X-Forwarded-Host, X-Original-URL)

Dangerous header candidates (unkeyed inputs):

X-Forwarded-Host
X-Host
X-Forwarded-Scheme
X-Original-URL
X-Rewrite-URL
Forwarded
X-HTTP-Method-Override

Step-by-Step Hunting Methodology

  1. Map cache infrastructure. Send a GET to the target and inspect response headers. Identify the caching layer (Cloudflare, Fastly, Varnish, Nginx). Note Age, X-Cache, CF-Cache-Status headers.

  2. Identify cache key components. Send two identical requests — if Age increments, the response is cached. Vary headers one-by-one (e.g., add X-Forwarded-Host) to determine which headers are NOT included in the cache key (unkeyed).

  3. Test unkeyed header reflection. Add X-Forwarded-Host: evil.com and check if the value appears in the response body (redirects, canonical links, CSP headers, JS src attributes, meta tags). Append

الأسئلة الشائعة

لماذا تعد ثغرات التخزين المؤقت خطيرة؟

إدخال مسموم واحد في الذاكرة قد يصل إلى كثير من الزوار في وقت واحد، لذلك قد يكون الأثر كبيرًا.

ما خداع التخزين المؤقت؟

هو أن تُخزَّن صفحة خاصة كأنها ملف ثابت، فيتمكن الآخرون من قراءتها.

هل تتداخل مع اختبارات ترويسة Host؟

نعم. تتضمن المهارة تسميم ترويسة Host وتشير إلى مهارة منفصلة لتفاصيل أكثر.

التفاصيل

الوصف الأصلي من المؤلف

Hunting skill for cache poison vulnerabilities. Built from 10 public bug bounty reports including X-Forwarded-Host poisoning, X-HTTP-Method-Override / GCS cache, reflected→stored XSS via cache, classic Omer-Gil Web Cache Deception, Cloudflare Cache Deception Armor bypass, session-token cache deception, Akamai hop-by-hop smuggling → server-side edge poisoning, and Kettle's 2024 path-normalization WCD against Cloudflare/Fastly/GCP. Host/X-Forwarded-Host injection that reaches app logic (reset-link poisoning, routing SSRF, OAuth issuer) is owned by hunt-host-header; this skill owns the case where

repo: elementalsouls/Claude-BugHunter

الشعبية

نجوم GitHub
5.4k
الترتيب
#14898
الترخيص
MIT
آخر تحديث
2‏/11‏/2026

هل هذه المهارة مفيدة؟

0

سجّل الدخول للتصويت.

التعليقات

  • …

المزيد من المهارات من هذا المستودع

مهارات مشابهة