Aller au contenu
Skillpedia
Sécurité5.4k · #14937

hunt-subdomain

Ce qu’il fait

Cette compétence recherche les risques de prise de contrôle de sous-domaine, où un enregistrement DNS pointe vers un service qui n'est plus utilisé. Elle s'adresse aux tests autorisés des noms de domaine et de l'hébergement d'une entreprise.

Quand l’utiliser

  • ✓Quand un sous-domaine pointe vers un service tiers qui a peut-être été supprimé.
  • ✓Quand une entreprise possède d'anciens sous-domaines de prévisualisation ou de préproduction qui ne sont plus utilisés.
  • ✓Quand une adresse OAuth ou de connexion utilise un sous-domaine doté d'un enregistrement orphelin.

Lien du skill

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

Copiez-le et collez-le dans votre IA (Claude, ChatGPT ou Cursor) en lui demandant de suivre les instructions.

Comment l’utiliser

Le plus simple : copiez le message et collez-le dans votre IA. Elle lit le skill et suit les instructions.

Message prêt à coller

Utilise ce skill pour m’aider : https://github.com/elementalsouls/Claude-BugHunter/blob/main/skills/hunt-subdomain/SKILL.md Lis le fichier SKILL.md de ce lien et suis ses instructions pour ma tâche.
Envie que votre IA trouve seule des skills comme celui-ci ?Installez le MCP gratuit de Skillpedia : une ligne, et elle cherche parmi 15 000+ skills avant chaque tâche.Installer en 1 minute →

Exemple de demande à votre IA

“Peux-tu vérifier nos sous-domaines à la recherche d'enregistrements DNS orphelins qui pourraient être revendiqués, dans le cadre de notre test autorisé ?”

5 nouveaux skills par semaine. 1 minute de lecture.

Comment ça marche

L'agent liste les sous-domaines, lit leurs enregistrements DNS et vérifie si le service visé existe encore. Il ne signale que les sous-domaines revendicables confirmés, ainsi que leur impact.

Contenu technique (SKILL.md original)

Texte original de l’auteur, en anglais, directement depuis GitHub.

Crown Jewel Targets

Subdomain takeover is high-value because it allows an attacker to serve content from a trusted, company-owned domain — bypassing browser same-origin trust, phishing filters, and user skepticism simultaneously.

Highest payout contexts:

  • Subdomains of major SaaS brands (Shopify, Snapchat, Mozilla, Yelp) where the trusted domain has user session context
  • CDN-backed subdomains (Fastly, CloudFront) where CNAME points to unclaimed origins
  • Third-party service integrations: UserVoice, WordPress.com, GitHub Pages, GitLab Pages, Heroku, Zendesk
  • Preview/staging/dev subdomains (new., preview., course., delivery., addons-preview.) — abandoned after feature launches
  • Subdomains used for OAuth redirect URIs or SSO endpoints — these pay highest

Asset types that matter most:

  • CNAME records pointing to deprovisioned third-party services
  • NS delegations to abandoned zones
  • A records pointing to unallocated cloud IPs (less common)
  • GitLab/GitHub Pages with unclaimed project namespaces

Attack Surface Signals

DNS signals:

  • CNAME pointing to *.github.io, *.gitlab.io, *.fastly.net, *.herokudns.com, *.wordpress.com, *.uservoice.com, *.zendesk.com, *.s3.amazonaws.com, *.azurewebsites.net, *.netlify.app
  • NXDOMAIN or SERVFAIL on the CNAME target while the parent record still exists
  • NS records delegating to registrars where the zone is no longer registered

HTTP response signals:

  • "There isn't a GitHub Pages site here"
  • "NoSuchBucket" (S3)
  • "The specified bucket does not exist"
  • "No such app" (Heroku)
  • "Sorry, this shop is currently unavailable" (Shopify)
  • "This UserVoice subdomain is available"
  • "Do you want to register" (any domain parking page)
  • HTTP 404 with provider-specific error templates
  • Fastly: "Fastly error: unknown domain"
  • "404 Web Site not found" (Azure App Service)

Tech stack signals:

  • Response headers: X-Served-By: cache-* (Fastly), X-GitHub-Request-Id, Server: Netlify
  • CNAME chain resolving to provider infrastructure but returning provider 404
  • SSL cert issued to provider wildcard (*.fastly.net) rather than company domain

Step-by-Step Hunting Methodology

  1. Enumerate all subdomains for the target using passive + active sources:

    • subfinder -d target.com -all
    • amass enum -passive -d target.com
    • assetfinder --subs-only target.com
    • Certificate transparency: crt.sh/?q=%.target.com
  2. Resolve all subdomains and flag those with:

    • NXDOMAIN responses
    • CNAME pointing to a third-party provider
    cat subdomains.txt | dnsx -a -cname -o resolved.txt
    
  3. Cross-reference CNAMEs against known vulnerable provider fingerprints using nuclei or subjack:

    subjack -w subdomains.txt -t 100 -timeout 30 -ssl -c fingerprints.json
    nuclei -l subdomains.txt -t takeovers/
    
  4. Manual verification for each flagged subdomain:

    • dig CNAME subdomain.target.com — confirm CNAME exists
    • dig A <cname-target> — confirm NXDOMAIN or no resolution
    • curl -sk https://subdomain.target.com — check for provider error string
  5. Confirm claimability — attempt to register the resource:

    • GitHub Pages: check if <username>.github.io/<repo> or org page is unclaimed
    • GitLab Pages: check project namespace
    • S3: attempt aws s3api create-bucket --bucket <bucketname>
    • UserVoice/Zendesk/WordPress: visit registration URL
    • Fastly: check if origin hostname is unregistered
  6. Claim the resource (only enough to prove control — do NOT serve malicious content):

    • Create a minimal index page with your HackerOne username and a timestamp
    • Take screenshot showing your content served on subdomain.target.com
  7. Document the chain: CNAME record → provider target → unclaimed resource → your content

  8. Assess impact escalation:

    • Does the subdomain appear in OAuth redirect allowlists?
    • Does it share cookies with parent domain (domain=.target.com)?
    • Is it referenced in the app's CSP?
    • Can it receive authenticated API calls?
  9. Write report before releasing the claim (some programs want to verify first)


Payload & Detection Patterns

Bulk CNAME extraction and NXDOMAIN detection:

# Extract CNAMEs and check if target resolves
while read sub; do
  cname=$(dig +short CNAME "$sub" | head -1)
  if [ -n "$cname" ]; then
    result=$(dig +short A "$cname"
Questions fréquentes

Pourquoi une prise de contrôle est-elle grave ?

Elle permet de diffuser du contenu depuis une adresse d'entreprise de confiance, ce qui peut servir à l'hameçonnage ou au vol de connexions.

Quels services sont vérifiés ?

La compétence couvre des services comme GitHub Pages, Heroku, Zendesk, Fastly, Azure et Netlify.

Les sous-domaines de connexion sont-ils plus risqués ?

Oui. La compétence indique que les sous-domaines utilisés pour OAuth ou l'authentification unique ont l'impact le plus élevé.

Détails

Description originale de l’auteur

Hunting skill for subdomain takeover vulnerabilities. Includes modern provider fingerprints — Microsoft Azure DevOps `cloudapp.azure.com` regional-pool re-issue (1-click OAuth ATO via wildcard `reply_to`, Binary Security), Zendesk help-desk takeover → email interception → password reset chain (0xprial writeup), Vercel `cname.vercel-dns.com` deleted-project takeover, plus general Fastly CDN service re-attach and S3 dangling-bucket cookie-scope techniques. Use when hunting subdomain takeover — emphasis on ATO-chain primitives (OAuth `redirect_uri`, cookie-domain, email DNS).

repo: elementalsouls/Claude-BugHunter

Popularité

Étoiles GitHub
5.4k
Position au classement
#14937
Licence
MIT
Mis à jour
02/11/2026

Ce skill vous est-il utile ?

0

Connectez-vous pour voter.

Commentaires

  • …

Autres skills de ce dépôt

Skills similaires