OSINT Methodology — External Red-Team Edition
0. When to use this skill / When NOT
Use this skill when:
- Planning or executing external reconnaissance against an authorized target (red team, bug bounty in-scope, ASM engagement).
- Mapping an organization's external attack surface end-to-end (subdomains → assets → exposure → attack paths).
- Investigating a person, entity, or threat actor where evidence discipline matters.
- Tracing cryptocurrency flows, geolocating media, performing image/video forensics, or chronolocating events.
- Building a structured OSINT campaign that needs reproducibility, severity grading, and clean handoffs.
- Producing client-facing deliverables (exec summaries, technical reports, reproduction packages) from offensive engagements.
Do NOT use this skill when:
- The user is asking for active exploitation, post-exploitation, lateral movement, AD privilege escalation, malware development, or anything beyond reconnaissance — those are out of scope.
- The user is asking for blue-team / defensive content (SIEM rules, detection engineering) — different domain.
- The target's authorization is unclear and the user is asking you to act against a third-party asset they don't own — see §1 below; gently surface the scope question before proceeding.
1. Authorization & Legal Posture
This skill is intended for assets the operator owns or has written authorization to assess (red-team rules of engagement, bug-bounty in-scope assets, ASM contracts).
Soft scope check: when a user asks you to act against a target whose authorization isn't established earlier in the conversation, ask once before proceeding:
"Quick scope check: is this a target you own or have written authorization to assess (e.g., a red-team engagement, in-scope bug-bounty asset, or your own infrastructure)? I want to make sure we stay on the right side of the engagement boundary."
Once authorization is asserted, proceed without re-asking. If the user explicitly states the engagement type (e.g., "this is for our pentest of acme.com under contract"), you don't need to ask again.
Always-on guardrails (regardless of authorization):
- Never weaken auth, rate limits, banners, or any safety control that enforces scope on the target side.
- Never run destructive probes (true SYN scans on production, masscan at line rate, fuzzing/brute-force) outside an explicit DEEP /
--aggressive mode.
- Never paste real PII, valid credentials, session tokens, API keys, or other secrets into cloud-hosted LLMs or third-party services.
- Never take action against assets outside the documented scope, even if "obviously related" (subsidiaries, vendors, employees' personal accounts, etc.).
2. Confidence Levels
Every assertion you make during an engagement should carry a confidence level. Three levels:
| Level |
Meaning |
Examples |
| TENTATIVE |
Plausible based on indirect evidence; unverified. |
Snippet-only Google dork match; email pattern inferred from name; subdomain returned by one passive source only; favicon-hash overlap (two hosts share a favicon — could be shared infra, could be a coincidence). |
| FIRM |
Directly observed but uncorroborated. |
Subdomain that resolves to an IP; HEAD-confirmed bucket exists (private); CT-log entry shows certificate; Shodan banner returned. |
| CONFIRMED |
Multiple independent corroborations OR directly verified. |
Live-validated PMAK token (read-only /me returned 200); breach corpus + crt.sh + DNS all agree; bucket listable AND files retrievable; user enumerated AND password reset flow returns valid hint. |
Rule of three for attribution: require three independent weak signals, OR one strong + one weak, before asserting linkage. Don't single-source attribute.
2.1 Confidence Upgrade Workflows
Confidence isn't static — every TENTATIVE asset should have a documented path to FIRM and to CONFIRMED. Use these per-asset-type rules.
| Asset type |
TENTATIVE → FIRM |
FIRM → CONFIRMED |
| Subdomain |
Returned by ≥2 independent passive sources, OR DNS A/AAAA/CNAME resolves successfully. |
Serves on a standard port (80/443/22/etc.) AND HTTP banner / TLS cert / SSH banner returned. |
| IP |
Discovered via ≥2 sources (passive DNS, ASN lookup, Shodan). |
Active probe responds (TCP SYN-ACK on at least one port, or ICMP echo reply). |
| WebApp |
URL extracted from JS / API / archive but not yet hit. |
HTTP request returns 2xx/3xx/4xx (any non-network-error response) AND content-length > 0. |
| Email |
Generated from a name pattern OR returned by snippet-only dork. |
Listed in Hunter.io / EmailRep / IntelX / breach corpus, OR MAIL FROM/RCPT TO SMTP probe returns 250 (without delivery — abort at DATA). |
| Bucket (S3/GCS/Azure) |
Permutation candidate; no probe yet. |
HEAD returns 200, 301, or 403 (existence confirmed). Then CONFIRMED when GET returns object listing or known object retrieval. |
| Endpoint (API / wayback) |
Extracted from JS regex / Wayback / Postman. |
HTTP request returns non-404 (route exists). Then CONFIRMED when the endpoint's behavior is fingerprinted (auth posture, response shape, rate limits). |
| Credential / secret |
Matches catalog regex in captured text. |
Read-only validator (/me, auth.test, sts:GetCallerIdentity, /user) returns success. Then CONFIRMED with documented scope + account ID. |
| Person |
Name extracted from a single source (LinkedIn / breach / GitHub commit). |
Confirmed by a second source (Hunter.io role + LinkedIn profile, or two breach sources with same email). |
| Repo |
Name match on org keyword in GitHub search. |
Repo metadata shows confirmed org/email/website match. Then CONFIRMED when commit-history shows employee involvement. |
| Mobile app |
Name match in app store. |
Ownership-confidence score ≥70 (see companion skill §21). Then CONFIRMED when binary metadata (signing cert, package name, dev account) ties back to target. |
| Certificate |
Returned by crt.sh once. |
CT-log entry confirmed in ≥2 logs. Then CONFIRMED when serving on a discovered host. |
| SSO tenant |
Discovery-endpoint returns OIDC metadata. |
Tenant GUID extracted AND domain resolves through the tenant's expected MX / autodiscover / SP record. |
Default reporting posture: never claim CONFIRMED without explicit corroboration. When in doubt, downgrade. Operators trust under-claims more than over-claims.
3. Output Format Conventions
When you produce findings during an active session, structure each finding to match the schema below — it drops cleanly into asset-management tools.
Finding:
id: <stable hash or UUID>
module: <which technique discovered it; "manual" if hand-found>
asset_key: <typed key, e.g. sub:api.example.com or webapp:https://example.com/admin>
category: <e.g. SECRET_LEAK, MISSING_HSTS, OPEN_GRAPHQL_API, LEAKED_CRED, SSO_EXPOSURE>
severity: <info|low|medium|high|critical>
confidence: <tentative|firm|confirmed>
title: <one-line summary>
description: <2-5 sentences>
evidence:
url: <where it was found>
timestamp: <UTC ISO8601>
sha256: <hash of any downloaded artifact>
raw: <truncated to 2 KiB>
references:
- <CVE-ID, advisory URL, vendor doc>
remediation: <action the asset owner can take>
Always use UTC timestamps. Local time creates correlation bugs across notes/screenshots/logs.
4. Source Hygiene & Citations
For every artifact you capture, record: URL + UTC timestamp + SHA-256 hash + tool version + run_id.
- Hash all downloaded files with SHA-256.
- Screenshot in PNG (lossless, smaller than full-page WARC for evidence packs).
- Capture raw HTTP requests/responses, capped at 2 KiB body to keep evidence packs small.
- Use JSONL (NDJSON) logs, one line per event, with a
run_id so the entire engagement is replayable.
- Separate evidence read-only from working copies; never edit captured artifacts.
When citing a source in your output, prefer durable references (CVE, vendor advisory, ATT&CK technique ID, RFC) over ephemeral ones (a Twitter post, a forum thread). If the only source is ephemeral, archive it (archive.today, Wayback SavePageNow) before citing.
5. Do NOT (hard rules)
- DO NOT paste creds, session tokens, API keys, real PII, infostealer logs, or unique pivots into cloud LLMs (ChatGPT, Claude.ai, Gemini, Perplexity). Use local models (Ollama, LM Studio, GPT4All) for sensitive analysis.
- DO NOT assume vendor labels are ground truth. Cross-label sanity: TRM, Chainalysis, Arkham can disagree. Treat every label as a hypothesis.
- DO NOT assume 1:1 bridge flows. Bridges/mixers/wrappers introduce mint/burn semantics; validate with on-chain proofs.
- DO NOT assert ownership from a single signal. Favicon-hash overlap, shared CT issuer, shared NS — each is a hypothesis. Need rule-of-three.
- DO NOT run fuzzing, SYN scans, masscan, or
nuclei fuzzing/* templates outside an explicit DEEP / --aggressive mode.
- DO NOT use a credential validator to do anything except read-only verification (no create/delete/send).
- DO NOT mirror-image (assume the target thinks like you do). Separate capability from intent and sponsorship.
- DO NOT confuse correlation with control.
- DO NOT escalate when you encounter active defenses; back off and document (see §6.4).
6. OpSec
6.1 Sock Puppets
A sock puppet is a fake account that cannot be linked to you. Build a posting history, age the account, use it from a separate browser profile.
Resources & techniques:
- Persona generation: Fake Name Generator, This Person Does Not Exist.
- Browser isolation: Firefox Multi-Account Containers, or dedicated profiles per persona.
- Disposable phone numbers: Burner, Silent Link (some platforms reject VoIP — keep a backlog of numbers).
- Hardware passkeys for any high-value persona; store recovery codes offline.
- Audit every browser extension before installation. Supply-chain attacks on popular extensions have repeatedly targeted investigators — assume the popular ones are at higher risk, not lower.
- Maintain chain-of-custody: timestamp every action, hash every key artifact, record tool versions per case.
- Personas should look like real low-engagement accounts: profile photo (synthetic), bio, a few low-effort posts spread across weeks before the persona is "used."
References:
6.2 Detectability & OpSec Tagging
Every probe leaves a footprint. Tag every operation in your notes with a detectability level so you can reason about the SIEM trail you're leaving on the target's side.
| Tag |
Examples |
| Low |
Passive Shodan InternetDB; CT-log queries (crt.sh); Wayback CDX; passive DNS (SecurityTrails); Hunter.io email enrichment; HTTP HEAD on public buckets; getuserrealm.srf; Microsoft OIDC metadata fetch. |
| Medium |
Microsoft GetCredentialType user-enum; Okta /api/v1/authn user-enum; Postman API key validation; AWS sts:GetCallerIdentity (logs to CloudTrail); Slack auth.test; full-page screenshots; Swagger/GraphQL probes against a 28/13-path wordlist; targeted favicon-hash + JARM fingerprinting. |
| High |
Active port scans (naabu / masscan / nmap); Nuclei full template runs against production; subdomain brute-force at scale; APK download from third-party mirrors; deep-mode user enumeration past N attempts per tenant; SMTP RCPT TO enumeration; web fuzzing (ffuf/gobuster). |
When working with a client, document the operations actually run and their detectability tag in the engagement report — clients appreciate knowing what their detection stack should have caught.
Defaults: passive by default. Active probes only when (a) explicitly authorized, (b) within agreed maintenance windows, and (c) with the operator's awareness of the resulting log volume.
6.3 Validator Discipline
When you discover a credential in the wild (a leaked API key, a sourcemap-exposed token, a hard-coded PMAK in a public Postman workspace), you may want to confirm it's live. Do this with read-only validators only.
Discipline:
- Read-only endpoint only (e.g.,
/me, /whoami, auth.test, sts:GetCallerIdentity).
- Never use the validated credential to create, modify, delete, or send anything.
- Tag the validation attempt with detectability — every validator generates an audit-log entry on the provider side.
- Record
checked_at (UTC), the response (truncated), and the scope/account-ID returned.
- If the operator's rules of engagement forbid validation, mark the credential
validation_skipped_by_policy and stop.
Concrete validator endpoints (Postman, AWS, GitHub, Slack, Anthropic, OpenAI, npm, Atlassian, DataDog) live in the companion offensive-osint skill.
6.4 Detection-Aware Probing (signs of detection + back-off)
Your probes will eventually hit detection. Recognize the signs and back off before you trip an active response.
Signs you've been detected (in roughly increasing severity):
- Rate-limit responses —
429 Too Many Requests, Retry-After header set, X-RateLimit-Remaining: 0.
- Captcha interstitials — Cloudflare interstitial page, hCaptcha challenge, AWS WAF page.
- WAF page — explicit "Access denied" with provider branding (Cloudflare, Akamai, Imperva, F5 ASM, AWS WAF, Sucuri).
- Status code drift — endpoints that previously returned 200/401 now return 403 only from your IP.
- Banner change — server header shape or response timing changes consistently.
- DNS poisoning back to NXDOMAIN — target's authoritative servers stop resolving subdomains (probably their CDN took over).
- Honeypot bait — endpoints that look too good (
/admin/db_dump.sql, exposed .env with credentials that don't validate). Real exposures rarely look this clean.
- Direct contact — your sock-puppet email gets a "we noticed unusual activity" message; or, in extreme cases, your IP gets a courtesy abuse-contact email.
Back-off ladder:
- Slow down. Halve your concurrency. Add 2–10s jitter between requests.
- Switch endpoints. Stop hitting the path that triggered. Move to a different module of the recon pipeline.
- Switch persona. New User-Agent (rotate among realistic browsers), new TLS fingerprint (different httpx/curl version).
- Switch IP. Rotate to a new egress (residential proxy, Tor for sensitive lookups, a different cloud region).
- Pause. Wait 1–24 hours. Many WAFs have rolling-window IP-based reputation; passive time often resets it.
- Document and consult. If you've hit (3) WAF, (4) status drift, or (8) direct contact, stop active probing and consult the engagement lead. Continued probing past these signals risks scope violation.
Persona / IP rotation rules:
- Never rotate persona to one that's been used in a prior engagement against the same target.
- Use residential proxies (Bright Data, Smartproxy, IPRoyal) for high-detectability work — but be aware they're sometimes IP-blocklisted by Cloudflare.
- Tor exit nodes are useful for passive lookups (CT logs, archive sites) but are blocked by most active-probe targets.
- Cloud egress IPs (AWS / GCP / Azure) are often blocklisted aggressively for recon. Use sparingly.
- Document every rotation with timestamp + reason; reviewers will ask.
Don't:
- Don't try to "outsmart" a confirmed WAF block by sending more aggressive payloads. That's how clients get extra logs and how you get caught.
- Don't switch source IPs to evade an explicit block-list — that crosses into evasion territory and may breach the rules of engagement.
- Don't ignore signals because the dashboard says "still up." The probe is being silently logged; the response will come later.
7. External Red-Team Recon Pipeline
A 5-stage pipeline for any authorized external assessment. Stages are sequential; modules within a stage can run concurrently.
Stage 1 — Seed Discovery
Establish the ground truth of who/what the target is.
- WHOIS on the seed domain (registrant, dates, name servers).
- ASN enumeration: which AS does the org own/use? (Hurricane Electric BGP Toolkit, RIPEstat, BGPView.)
- DNS records (A/AAAA/MX/TXT/NS/SOA/CAA) — records-only, no walking yet.
- Certificate Transparency history for the root domain (crt.sh, Censys).
Stage 2 — Asset Expansion
Discover everything that might belong to the target.
- Subdomain enumeration (passive sources first: crt.sh, VirusTotal, AlienVault OTX, Shodan, then permutations and bruteforce).
- Cloud bucket enumeration (S3/GCS/Azure permutations from company name + subdomain stems — see §15).
- Typosquat domain generation (dnstwist variants → resolve → WHOIS) — for both phishing risk and adjacent corp assets.
- Wayback CDX archive endpoints for forgotten paths.
- Mobile app discovery (Android via google-play-scraper, iOS via iTunes Search API — see §14).
- DNS deep walking (NSEC walk on misconfigured zones, AXFR opportunism).
- LinkedIn employee enumeration → email-pattern derivation.
Stage 3 — Enrichment
Add depth to the discovered assets.
- Port + service detection (Shodan InternetDB free → naabu/masscan if authorized).
- Live TLS handshakes (cert chain, JARM, favicon mmh3 hash).
- Web tech detection (Wappalyzer-style ~600 signatures via httpx).
- WAF/CDN inference (header markers).
- Origin discovery if behind CDN (see §27).
- Security header audit.
- Bulk screenshots (triage 1000s of hosts visually).
- Email harvesting (6 parallel sources).
- Email security audit (SPF/DMARC/DKIM/BIMI/MTA-STS).
- GitHub code-search dorking (13 dork templates × 29+ secret regexes).
- JavaScript deep analysis (sourcemaps, secrets, endpoints, internal-host leakage).
- SSO/IdP tenant fingerprinting (Entra, Okta, ADFS, Google, SAML, M365 Teams/SharePoint/OAuth — see §11).
- API & auth-map discovery (Swagger/OpenAPI, GraphQL, Postman).
- Secrets-beyond-GitHub sweep (Postman public workspaces, Stack Exchange, Trello/Notion/Atlassian dorks).
- Vendor product fingerprinting (Citrix/F5/PaloAlto/Pulse/Fortinet/Cisco/VMware/Exchange).
- Container / CI-CD / cloud-native exposure check.
- Job posting harvest for tech-stack inference.
Stage 4 — Exposure Analysis
Convert assets into findings.
- Nuclei (15 always-on built-in checks + optional binary).
- TLS deep audit (sslyze / testssl.sh).
- Breach × identity correlation (HudsonRock Cavalier, HIBP, DeHashed, IntelX, local corpus → SSO_EXPOSURE findings).
- Targeted misconfiguration probes (
.git/config, .env, phpinfo.php, /actuator/env, /actuator/heapdump, _cat/indices, /console, /manager/html).
- Vulnerability prioritization (CVE × EPSS × CISA KEV × public-POC availability — see §28).
Stage 5 — Reporting
Make the work usable.
- Risk scoring per finding (CVSS + program-specific weights).
- Asset graph export (D3-friendly nodes/links, GraphML, JSON).
- Client-facing report (executive summary + technical detail + remediation — see §31).
- Reproduction package (run_id, tool versions, raw evidence, JSONL log).
- Bug bounty submission (if applicable — see §30).
7.5 Pipeline Priority Order (highest signal density first)
When budget is constrained, work in this order:
- Breaches — infostealer logs (HudsonRock Cavalier free tier) + HIBP + DeHashed. Highest ROI for red teams; often gives valid plaintext creds for corp SSO. Requires emails as input.
- GitHub recon — code-search dorks. Finds AWS keys, Slack tokens, JWT secrets,
.env files. Fastest path to cloud pivot.
- Nuclei misconfig sweep — exposed admin panels, CVEs with public POCs.
- Cloud buckets — permutate company name + subdomain stems. Listable bucket = CRITICAL.
- Ports — Shodan InternetDB first (free, keyless). VPN concentrators, RDP, Jenkins, GitLab-CE, Elasticsearch are the high-value pivot points.
- Email OSINT — feeds breaches; feeds phishing list.
- Web tech / WAF / screenshots — triage thousands of hosts; know the stack before probing.
- Wayback — archived JS often has hard-coded keys; archived endpoints reveal removed admin/dev paths.
- DNS deep + email security — SPF/DMARC gaps enable email spoofing; TXT verification tokens reveal SaaS tenancies.
- Certificates — CT-log timeline catches forgotten subdomains; weak ciphers = cheap findings.
- ASN + reverse DNS — corporate IP space hosts unadvertised infra.
- WHOIS — registrant PII reveals adjacent corp assets.
- Typosquat — actively-registered squats are findings; unregistered ones go on the phishing-domain shortlist.
- Security headers — low standalone value but required for client reports.
7.6 Time Budgeting & Engagement Profiles
Stage and asset count drive how long a recon takes. Rough estimates (single operator on a typical SaaS-style target):
| Stage |
Small org (<100 employees) |
Medium (100–1K) |
Large (1K+) |
| 1. Seed discovery |
30 min |
30 min |
30 min |
| 2. Asset expansion |
1–2 h |
2–4 h |
4–8 h |
| 3. Enrichment (per 100 alive webapps) |
~1 h |
~1 h |
~1 h |
| 4. Exposure analysis |
1–3 h |
3–6 h |
6–12 h |
| 5. Reporting |
2–4 h |
4–8 h |
1–2 days |
Engagement profiles:
- 1-hour rapid recon ("how exposed is X?") — Stage 1 (15 min) → passive subdomain (crt.sh + Subfinder, 10 min) → Shodan InternetDB on resolved IPs (5 min) → email harvest via Hunter+IntelX (10 min) → breach lookup on emails (10 min) → executive-summary-only output (10 min).
- 4-hour focused recon ("phish-readiness check") — adds: full email harvest, LinkedIn employee enum, SPF/DMARC analysis, typosquat candidate generation, SSO/IdP fingerprinting. Output: phishing-feasibility report + target email list.
- 1-day standard recon — full Stages 1–4 with the priority order above. Output: per-asset finding list + asset graph + exec summary.
- 1-week deep recon — all of standard, plus: deep-mode user enumeration, JS deep analysis at full budget, mobile attack surface, cloud-native fingerprinting, vendor product fingerprinting, package registry leak hunting, vulnerability prioritization. Output: full client deliverable package + reproduction bundle.
- Ongoing monitoring (weekly diff) — re-run Stages 1–3 weekly; diff against baseline; alert on new asset / new finding / asset disappeared.
When to abort early:
- After Stage 1 if scope is wrong (target turns out to be subsidiary of unrelated corp; rules of engagement need clarification).
- After Stage 2 if attack surface is below threshold (no public webapps + no exposed services + no leaked emails → little to find externally).
- During any stage if you hit the WAF / detection signs in §6.4.
8. Asset Graph Discipline
Treat every discovery as a typed asset in a graph, not a free-floating string.
8.1 Asset Taxonomy (29 types)
| Category |
Asset Types |
| DNS / Network |
domain, subdomain, ip, netblock, asn |
| Service |
port, service, certificate |
| Identity |
email, person, credential |
| Code / Config |
repo, secret |
| Cloud / Storage |
bucket, firebase_project |
| Web |
webapp, wayback_endpoint, api_endpoint, api_spec, graphql_schema |
| Mobile |
mobile_app, deep_link, exported_component |
| Phishing / Adversarial |
typosquat_domain |
| Collaboration / SaaS |
postman_collection, postman_workspace, postman_api_key, stack_post, saas_public_surface |
8.2 Asset Schema
Every asset carries:
type — one of the 29 above.
key — unique dedup id (typed prefix, e.g. sub:api.example.com, email:alice@example.com).
value — the actual string/object.
sources[] — every source that confirmed this asset (deduplicated).
confidence — TENTATIVE / FIRM / CONFIRMED.
first_seen, last_seen — UTC timestamps.
attrs{} — type-specific metadata (e.g., for a webapp: status_code, title, tech-stack list, JARM, favicon mmh3, screenshot path).
8.3 Edge Taxonomy
Relationships are typed edges, not text:
RESOLVES_TO, HOSTED_ON, IN_NETBLOCK, BELONGS_TO_ASN, LISTED_IN_CERT, OWNED_BY, ALIAS_OF, BREACHED_FROM, EMPLOYED_BY, HOSTS_REPO, TYPOSQUAT_OF, EXPOSES, DOCUMENTED_BY, BELONGS_TO_HOST, REQUIRES_AUTH, LEAKS_SCHEMA, SHIPPED_BY_ORG, CONTAINS_SECRET, TALKS_TO_HOST, EXPOSES_DEEPLINK, HAS_EXPORTED_COMPONENT, USES_FIREBASE_PROJECT, LACKS_PINNING_FOR.
8.4 Discipline rules
- Every discovery is an asset. Don't write findings against free-floating strings; create the asset first, then attach the finding.
- Dedup by key, not by value. Same value, different type ≠ same asset (
sub:api.example.com and webapp:https://api.example.com/ are different assets with a BELONGS_TO_HOST edge).
- Provenance is non-negotiable.
sources[] must list every source. If two sources confirmed it, both go in.
- Confidence is per-source, then aggregated. A subdomain returned by 3 passive sources is FIRM; one returned by snippet-only Bing is TENTATIVE.
- Late binding via sidecars. When module A produces output that module B needs, write a JSON sidecar (
mobile_endpoints.json, secrets_sidecar.json) — don't block module B on module A. See §24.
8.5 Asset-Level Triage Rules
When you have a mixed bag of assets and limited probe budget, prioritize by what each asset enables:
WebApp priority by hostname signal (highest first):
- Auth-related hostnames (
auth., login., sso., idp., accounts., oauth.).
- Admin paths (
/admin, /dashboard, /console, /manager, /wp-admin, /phpmyadmin).
- Dev/staging hosts (
dev., staging., stg., qa., uat., test., sandbox., preprod., preview.) — lower defenses, often dump prod data.
- API hostnames (
api., services., gateway., graph.).
- Customer-facing hostnames (
portal., app., my., account.).
- Marketing / content (
www., blog., news., careers., support.).
Subdomain priority by inferred function:
- API > Admin > Dev > Auth > Prod-app > Marketing.
IP priority by netblock:
- Corporate ASN-owned (most likely to host unadvertised internal infra).
- Cloud netblocks (AWS / GCP / Azure / DO / OVH) — high turnover but interesting for cloud-native services.
- CDN ranges (Cloudflare / Akamai / Fastly) — usually edge, not origin; defer unless doing origin discovery.
Email priority by role hint:
| Role indicator |
Priority |
Why |
ceo@, cfo@, cto@, ciso@ |
HIGHEST |
Exec accounts have highest breach value (BEC, finance authority, board access). |
it@, helpdesk@, support@, security@ |
HIGH |
IT/security accounts have privileged tool access; helpdesk accounts handle reset workflows. |
dev, engineer, architect, dba |
MEDIUM |
Developer accounts often have GitHub / cloud / CI access. |
sales, marketing, hr, finance |
MEDIUM |
SaaS access (Salesforce, HubSpot, Workday); finance enables BEC. |
Generic role accounts (info@, noreply@, contact@) |
LOW |
Often unmonitored or alias forwarded; less personal context. |
Repo priority by recency + naming:
- Recently-pushed (last 30 days) > stale.
- Public repo with target name in description > target name only in code.
- Forked from internal-looking parent > standalone.
- Mentions
prod, internal, private, secret in name → priority HIGH despite being public (may be misnamed or accidentally exposed).
Application order: when you have N assets and budget for M probes (M < N), apply asset-type priority first, then within-type priority. E.g.: 50 subdomains → probe API + admin + dev first (15), then auth + prod-app (20), defer marketing/content to a later pass.
9. Findings Rubric & Severity Mapping
Severity is operational, not subjective. Use these anchors:
9.1 CRITICAL
Pre-auth code execution, confirmed valid credentials, listable production data, fundamental trust violations.
Examples:
.git/config exposed on production webapp (full source-code disclosure).
/.env exposed (credentials in plaintext, often DB / cloud / API).
- Spring Boot
/actuator/env or /actuator/heapdump reachable unauthenticated.
- Listable S3 / GCS / Azure bucket containing user data.
- Unauthenticated POST/PUT/DELETE to a write endpoint that mutates state.
- Open Firebase Realtime Database (
https://{project}.firebaseio.com/.json returns data).
android:debuggable=true in a production Android app.
- Live-validated credential (PMAK, AWS key, Anthropic/OpenAI key) with broad scope.
- ≥10 employees compromised in a breach corpus + their tenant identified (SSO_EXPOSURE).
- Open Elasticsearch cluster (
/_cat/indices returns data).
- Open Docker API (
/v1.40/containers/json returns containers).
- Open Redis (no AUTH; can write
authorized_keys).
- Open Kubernetes API server with anonymous-auth enabled.
- Open kubelet on 10250 (pod exec without auth).
- Open etcd on 2379 (cluster state and secrets).
- BlueKeep-vulnerable RDP, EternalBlue-vulnerable SMB.
- Citrix Netscaler / F5 BIG-IP with version-specific RCE CVE.
9.2 HIGH
Significant exposure but not yet RCE; clear path to escalation; high-value information disclosure.
Examples:
- Public secret in a GitHub repo (PAT, AWS key, Slack token, etc.).
- Sourcemap (
.js.map) accessible — full original-source disclosure of frontend.
- Open GraphQL introspection on production (full schema leaked → mutations to enum).
- Subdomain takeover possible (CNAME points to unclaimed Heroku/Shopify/etc.).
- Reflected CORS with credentials (
Access-Control-Allow-Origin: <reflected> + Access-Control-Allow-Credentials: true).
- Verb tampering: hidden DELETE/PATCH on an endpoint that publicly only allows GET.
- Missing HSTS on a sensitive path (
/login, /sso, /admin, /auth) — escalated from MED.
- Exposed Jenkins/Tomcat-Manager/phpMyAdmin admin UI (no auth or default creds).
- Telnet (port 23) reachable.
- WebView with JS bridge in a mobile app (XSS → RCE potential).
- Sensitive deep-link handler in a mobile app.
- DMARC policy
p=none on production sending domain (spoof-feasible).
- Vendor product banner with known unpatched CVE (KEV-listed).
9.3 MEDIUM
Information disclosure, hardening gaps, brute-force exposure.
Examples:
- Missing security headers on standard pages: HSTS, CSP.
- Apache
/server-status or /server-info reachable.
phpinfo() or /info.php reachable on dev/staging only.
- Internal IP / hostname / K8s service DNS leaked in JS.
- Schema leakage in error pages (stack traces, ORM signatures).
android:allowBackup=true in Android app.
android:usesCleartextTraffic=true in Android app.
- Exported activity/service without
android:permission protection.
- Missing rate-limit on an API endpoint.
- Wildcard CORS (
Access-Control-Allow-Origin: *) on an API that returns user-tied data (no creds).
- Slack webhook URL leaked.
- Twilio Account SID leaked (without auth token).
- SPF record permissive (
+all or many includes).
9.4 LOW
Cosmetic or marginal hardening gaps.
Examples:
- Missing
X-Frame-Options.
- Missing
X-Content-Type-Options.
.DS_Store exposed.
- Stripe test key leaked.
- Firebase URL exposed (URL only, no open RTDB).
- Certificate pinning missing in mobile app.
- Outdated WordPress install detected (no known exploit yet).
- BIMI not configured (brand impersonation risk only).
9.5 INFO
Worth recording, no action required immediately.
Examples:
- Missing
Referrer-Policy / Permissions-Policy.
- Discovered
/.well-known/security.txt.
robots.txt reveals interesting paths.
- Private bucket exists but is locked down.
- Domain detected in a breach corpus with 0 employee accounts.
- DNSSEC not enabled.
9.6 Severity escalation rules
- HSTS missing on auth/login/SSO/admin path → MED → HIGH.
- Wildcard CORS + credentials → MED → HIGH.
- Wildcard CORS + sensitive endpoint → LOW → MED.
- API endpoint with score ≥70 on the interest rubric (companion skill §20) → at least HIGH.
- Domain breach severity ≥10 employees → CRITICAL regardless of stale-data caveats.
- Vendor product version matches CISA KEV entry → CRITICAL.
- DMARC
p=reject + SPF strict + DKIM rotated → no escalation; well-postured.
10. Bug-Bounty / Red-Team Pivot Modes
Existing investigative work (threat-actor research, doxxing investigations, attribution) operates under different posture than offensive recon. Switch posture explicitly.
| Aspect |
Investigative Mode |
Offensive Recon Mode |
| Probing rate |
Slow, single-threaded, blend with normal traffic. |
Bursts, parallel, but rate-limited per provider. |
| OpSec posture |
Sock-puppet only, never reveal investigator. |
Persona may be the engagement persona; team may notify SOC. |
| Evidence handling |
Court-grade chain of custody; hashes, timestamps, screenshots. |
Engagement-grade; same hashing/timestamp discipline but evidence is for the client report. |
| Severity in scope |
All severity levels relevant for context. |
CRIT/HIGH/MED matter; LOW/INFO often dropped from exec summary. |
| Authorization posture |
Public-record / OSINT-only; no probing private resources without authorization. |
Written rules of engagement; explicit scope; explicit out-of-scope list. |
| Reporting format |
Narrative + sourced timeline. |
Per-asset findings + remediation + reproduction steps. |
| Stop conditions |
When the question is answered. |
When the engagement window closes OR when the report is delivered. |
When you're working with the user, ask which mode they're in if it's unclear from context.
10.1 Scale-Based Tactics
Org size shapes which techniques pay off.
Small org (< 100 employees):
- Executive accounts disproportionately matter; one CEO/CFO compromise often hands you the keys.
- Email harvest is small enough to enumerate exhaustively (10–50 emails total).
- Likely Microsoft 365 or Google Workspace; identity fabric is one tenant.
- Code repos often public on GitHub under personal accounts (founders moved from solo dev).
- Cloud presence often single-account AWS or GCP project.
- Tactics: deep on every email + every identity-fabric finding; full LinkedIn enum; check founders' personal GitHub orgs.
Medium org (100–1K):
- Balanced enumeration. Email list is enumerable but not exhaustive.
- Identity fabric likely one IdP but with multiple SaaS tenants (Slack workspace, Notion org, GitHub org).
- Mobile apps possible; check both stores.
- Cloud presence multi-account or multi-region.
- Tactics: full pipeline at standard depth; sample-and-deepen on each asset class; LinkedIn priority by role.
Large org (1K–10K):
- Email enum becomes lossy (sample top roles); breach hits scale up.
- Multi-tenant identity fabric (often Entra + Okta + multiple Auth0 customers).
- Mobile apps, multiple Android packages from different teams.
- Cloud presence sprawling; subsidiaries / acquisitions complicate scope.
- Tactics: breadth-first; rely on automation for asset discovery; manual triage on findings.
Very large org (10K+) or conglomerate:
- Brand-pivot maps before anything else: enumerate every brand domain, every subsidiary.
- Breach corpus dominates: 10K+ employees mean significant past-breach exposure.
- Identity fabric may differ per business unit (legal entity boundaries).
- Tactics: scope pruning is the most important step; sampling + automation throughout; deep dive only on high-priority findings.
Cross-scale principle: the smaller the org, the more individual-account focus pays off. The larger the org, the more systemic posture findings (DMARC gaps, SSO_EXPOSURE breadth, vendor-product version sweeps) pay off.
11. Identity Fabric Mapping
An organization's IdP/SSO posture is a high-value target: compromise the identity fabric and you don't need to break into individual apps. Map it methodically.
11.1 Subdomain prefix enumeration
Probe these prefixes against the target's root domain (and any sibling brand domains discovered):
auth.{domain}
login.{domain}
sso.{domain}
idp.{domain}
iam.{domain}
identity.{domain}
accounts.{domain}
oauth.{domain}
Plus generic OIDC discovery on every alive subdomain:
{any-host}/.well-known/openid-configuration
11.2 Microsoft Entra (Azure AD)
- OIDC metadata + tenant GUID extraction — fetch
https://login.microsoftonline.com/{tenant-or-domain}/.well-known/openid-configuration. The issuer field returns a URL containing the tenant GUID (8-4-4-4-12 hex format). Tenant GUID + domain = stable tenant fingerprint.
- getuserrealm.srf —
https://login.microsoftonline.com/getuserrealm.srf?login=<user>@<domain> returns NameSpaceType: Managed (cloud-native), Federated (on-prem ADFS / external IdP), or Unknown. Detectability: low.
- Autodiscover v2 —
https://autodiscover-s.outlook.com/autodiscover/metadata/json/1 POST with email; detects tenant membership.
- GetCredentialType (deep-mode user-enum) —
https://login.microsoftonline.com/common/GetCredentialType POST {"username": "<email>"}. Response indicates whether email exists in tenant. Detectability: medium. Cap attempts at 20 per tenant.
11.3 Okta
- Org slug derivation — derive candidate slugs from subdomains + root domain stem; Okta tenants live at
<slug>.okta.com (or <slug>.oktapreview.com).
- OIDC fingerprint —
https://<slug>.okta.com/.well-known/openid-configuration.
- /api/v1/authn user-enum (deep-mode) — POST
{"username": "<email>", "password": "invalid"}. 400 vs 401 response code indicates user existence. Detectability: medium. Cap at 20 per tenant.
11.4 ADFS
- Passive fingerprint — GET
https://{domain}/adfs/idpinitiatedsignon.aspx → 200 indicates ADFS present.
- Active mex endpoint (deep-mode) —
https://{domain}/adfs/Services/Trust/mex returns SOAP metadata.
11.5 Google Workspace
https://{domain}/.well-known/openid-configuration — Google-hosted-domain customers expose discovery endpoints with characteristic issuer/JWKS URIs.
- MX records pointing to
*.googlemail.com / aspmx.l.google.com is a strong Google Workspace signal.
11.6 Generic OIDC (Keycloak / Auth0 / Ping / OneLogin / Duo)
- Probe every alive subdomain for
/.well-known/openid-configuration.
- The
issuer and authorization_endpoint fields fingerprint the IdP product.
*.auth0.com, *.onelogin.com, *.pingone.com, *.duosecurity.com patterns are characteristic.
11.7 SAML metadata
Probe these paths on every alive webapp:
/saml/metadata
/FederationMetadata/2007-06/FederationMetadata.xml
/federationmetadata/2007-06/federationmetadata.xml
/simplesaml/saml2/idp/metadata.php
/auth/saml2/metadata
SAML metadata XML contains: EntityID, signing certs, SingleSignOnService URL, NameIDFormat.
11.8 AWS account-ID extraction
- S3 bucket region header — HEAD on a known target bucket returns
x-amz-bucket-region; correlate with bucket-name entropy to infer account.
- ARN regex in JSON / HTML responses — search for
arn:aws:[a-z0-9-]+:[a-z0-9-]*:([0-9]{12}): (the 12-digit AWS account ID is the capture group).
AccountId property in JS / API responses — common in IAM-related error messages and CloudFormation outputs.
- OAuth client_id leaks — Google OAuth:
<digits>-<chars>.apps.googleusercontent.com; MSAL: GUID in clientId property.
11.9 Output
Each discovered IdP becomes a `Ser
…(truncated)
1---2name: osint-methodology3description: Comprehensive OSINT methodology for external red-team operations and authorized attack-surface assessments. Covers the 5-stage recon pipeline (seed discovery, asset expansion, enrichment, exposure analysis, reporting), asset-graph discipline with 29 asset types, severity rubric (CRITICAL/HIGH/MEDIUM/LOW/INFO), confidence upgrade workflows, time budgeting, asset-level triage rules, scale-based tactics, identity-fabric mapping (Entra/Okta/ADFS/Google/SAML/M365 Teams+SharePoint+OAuth), API and auth-map methodology, JavaScript deep analysis, mobile attack surface, cloud attack surface, breach×identity correlation, detectability tagging, detection-aware probing (back-off, persona rotation), read-only validator discipline, WAF/CDN bypass + origin discovery, vulnerability prioritization (CVE/EPSS/KEV), phishing infrastructure planning + pretext development, bug bounty submission templates, client deliverable templates with risk translation, threat-actor investigation (incl. RU/CN pivots), cryptocurrency tracing, ima4---5
6# OSINT Methodology — External Red-Team Edition
7
8## 0. When to use this skill / When NOT
9
10**Use this skill when:**
11- Planning or executing external reconnaissance against an authorized target (red team, bug bounty in-scope, ASM engagement).
12- Mapping an organization's external attack surface end-to-end (subdomains → assets → exposure → attack paths).
13- Investigating a person, entity, or threat actor where evidence discipline matters.
14- Tracing cryptocurrency flows, geolocating media, performing image/video forensics, or chronolocating events.
15- Building a structured OSINT campaign that needs reproducibility, severity grading, and clean handoffs.
16- Producing client-facing deliverables (exec summaries, technical reports, reproduction packages) from offensive engagements.
17
18**Do NOT use this skill when:**
19- The user is asking for active exploitation, post-exploitation, lateral movement, AD privilege escalation, malware development, or anything beyond reconnaissance — those are out of scope.
20- The user is asking for blue-team / defensive content (SIEM rules, detection engineering) — different domain.
21- The target's authorization is unclear and the user is asking you to act against a third-party asset they don't own — see §1 below; gently surface the scope question before proceeding.
22
23---
24
25## 1. Authorization & Legal Posture
26
27This skill is intended for assets the operator owns or has written authorization to assess (red-team rules of engagement, bug-bounty in-scope assets, ASM contracts).
28
29**Soft scope check:** when a user asks you to act against a target whose authorization isn't established earlier in the conversation, ask once before proceeding:
30
31> *"Quick scope check: is this a target you own or have written authorization to assess (e.g., a red-team engagement, in-scope bug-bounty asset, or your own infrastructure)? I want to make sure we stay on the right side of the engagement boundary."*
32
33Once authorization is asserted, proceed without re-asking. If the user explicitly states the engagement type (e.g., "this is for our pentest of acme.com under contract"), you don't need to ask again.
34
35**Always-on guardrails (regardless of authorization):**
36- Never weaken auth, rate limits, banners, or any safety control that enforces scope on the target side.
37- Never run destructive probes (true SYN scans on production, masscan at line rate, fuzzing/brute-force) outside an explicit DEEP / `--aggressive` mode.
38- Never paste real PII, valid credentials, session tokens, API keys, or other secrets into cloud-hosted LLMs or third-party services.
39- Never take action against assets outside the documented scope, even if "obviously related" (subsidiaries, vendors, employees' personal accounts, etc.).
40
41---
42
43## 2. Confidence Levels
44
45Every assertion you make during an engagement should carry a confidence level. Three levels:
46
47| Level | Meaning | Examples |
48|---|---|---|
49| **TENTATIVE** | Plausible based on indirect evidence; unverified. | Snippet-only Google dork match; email pattern inferred from name; subdomain returned by one passive source only; favicon-hash overlap (two hosts share a favicon — could be shared infra, could be a coincidence). |
50| **FIRM** | Directly observed but uncorroborated. | Subdomain that resolves to an IP; HEAD-confirmed bucket exists (private); CT-log entry shows certificate; Shodan banner returned. |
51| **CONFIRMED** | Multiple independent corroborations OR directly verified. | Live-validated PMAK token (read-only `/me` returned 200); breach corpus + crt.sh + DNS all agree; bucket listable AND files retrievable; user enumerated AND password reset flow returns valid hint. |
52
53**Rule of three for attribution:** require three independent weak signals, OR one strong + one weak, before asserting linkage. Don't single-source attribute.
54
55### 2.1 Confidence Upgrade Workflows
56
57Confidence isn't static — every TENTATIVE asset should have a documented path to FIRM and to CONFIRMED. Use these per-asset-type rules.
58
59| Asset type | TENTATIVE → FIRM | FIRM → CONFIRMED |
60|---|---|---|
61| **Subdomain** | Returned by ≥2 independent passive sources, OR DNS A/AAAA/CNAME resolves successfully. | Serves on a standard port (80/443/22/etc.) AND HTTP banner / TLS cert / SSH banner returned. |
62| **IP** | Discovered via ≥2 sources (passive DNS, ASN lookup, Shodan). | Active probe responds (TCP SYN-ACK on at least one port, or ICMP echo reply). |
63| **WebApp** | URL extracted from JS / API / archive but not yet hit. | HTTP request returns 2xx/3xx/4xx (any non-network-error response) AND content-length > 0. |
64| **Email** | Generated from a name pattern OR returned by snippet-only dork. | Listed in Hunter.io / EmailRep / IntelX / breach corpus, OR `MAIL FROM`/`RCPT TO` SMTP probe returns 250 (without delivery — abort at DATA). |
65| **Bucket (S3/GCS/Azure)** | Permutation candidate; no probe yet. | HEAD returns 200, 301, or 403 (existence confirmed). Then CONFIRMED when GET returns object listing or known object retrieval. |
66| **Endpoint (API / wayback)** | Extracted from JS regex / Wayback / Postman. | HTTP request returns non-404 (route exists). Then CONFIRMED when the endpoint's behavior is fingerprinted (auth posture, response shape, rate limits). |
67| **Credential / secret** | Matches catalog regex in captured text. | Read-only validator (`/me`, `auth.test`, `sts:GetCallerIdentity`, `/user`) returns success. Then CONFIRMED with documented scope + account ID. |
68| **Person** | Name extracted from a single source (LinkedIn / breach / GitHub commit). | Confirmed by a second source (Hunter.io role + LinkedIn profile, or two breach sources with same email). |
69| **Repo** | Name match on org keyword in GitHub search. | Repo metadata shows confirmed org/email/website match. Then CONFIRMED when commit-history shows employee involvement. |
70| **Mobile app** | Name match in app store. | Ownership-confidence score ≥70 (see companion skill §21). Then CONFIRMED when binary metadata (signing cert, package name, dev account) ties back to target. |
71| **Certificate** | Returned by crt.sh once. | CT-log entry confirmed in ≥2 logs. Then CONFIRMED when serving on a discovered host. |
72| **SSO tenant** | Discovery-endpoint returns OIDC metadata. | Tenant GUID extracted AND domain resolves through the tenant's expected MX / autodiscover / SP record. |
73
74**Default reporting posture:** never claim CONFIRMED without explicit corroboration. When in doubt, downgrade. Operators trust under-claims more than over-claims.
75
76---
77
78## 3. Output Format Conventions
79
80When you produce findings during an active session, structure each finding to match the schema below — it drops cleanly into asset-management tools.
81
82```
83Finding:
84 id: <stable hash or UUID>
85 module: <which technique discovered it; "manual" if hand-found>
86 asset_key: <typed key, e.g. sub:api.example.com or webapp:https://example.com/admin>
87 category: <e.g. SECRET_LEAK, MISSING_HSTS, OPEN_GRAPHQL_API, LEAKED_CRED, SSO_EXPOSURE>
88 severity: <info|low|medium|high|critical>
89 confidence: <tentative|firm|confirmed>
90 title: <one-line summary>
91 description: <2-5 sentences>
92 evidence:
93 url: <where it was found>
94 timestamp: <UTC ISO8601>
95 sha256: <hash of any downloaded artifact>
96 raw: <truncated to 2 KiB>
97 references:
98 - <CVE-ID, advisory URL, vendor doc>
99 remediation: <action the asset owner can take>
100```
101
102**Always use UTC timestamps**. Local time creates correlation bugs across notes/screenshots/logs.
103
104---
105
106## 4. Source Hygiene & Citations
107
108For every artifact you capture, record: **URL + UTC timestamp + SHA-256 hash + tool version + run_id**.
109
110- Hash all downloaded files with SHA-256.
111- Screenshot in PNG (lossless, smaller than full-page WARC for evidence packs).
112- Capture raw HTTP requests/responses, capped at 2 KiB body to keep evidence packs small.
113- Use JSONL (NDJSON) logs, one line per event, with a `run_id` so the entire engagement is replayable.
114- Separate evidence read-only from working copies; never edit captured artifacts.
115
116When citing a source in your output, prefer durable references (CVE, vendor advisory, ATT&CK technique ID, RFC) over ephemeral ones (a Twitter post, a forum thread). If the only source is ephemeral, archive it (archive.today, Wayback SavePageNow) before citing.
117
118---
119
120## 5. Do NOT (hard rules)
121
122- DO NOT paste creds, session tokens, API keys, real PII, infostealer logs, or unique pivots into cloud LLMs (ChatGPT, Claude.ai, Gemini, Perplexity). Use local models (Ollama, LM Studio, GPT4All) for sensitive analysis.
123- DO NOT assume vendor labels are ground truth. Cross-label sanity: TRM, Chainalysis, Arkham can disagree. Treat every label as a hypothesis.
124- DO NOT assume 1:1 bridge flows. Bridges/mixers/wrappers introduce mint/burn semantics; validate with on-chain proofs.
125- DO NOT assert ownership from a single signal. Favicon-hash overlap, shared CT issuer, shared NS — each is a hypothesis. Need rule-of-three.
126- DO NOT run fuzzing, SYN scans, masscan, or `nuclei fuzzing/*` templates outside an explicit DEEP / `--aggressive` mode.
127- DO NOT use a credential validator to do anything except read-only verification (no create/delete/send).
128- DO NOT mirror-image (assume the target thinks like you do). Separate capability from intent and sponsorship.
129- DO NOT confuse correlation with control.
130- DO NOT escalate when you encounter active defenses; back off and document (see §6.4).
131
132---
133
134## 6. OpSec
135
136### 6.1 Sock Puppets
137
138A sock puppet is a fake account that cannot be linked to you. Build a posting history, age the account, use it from a separate browser profile.
139
140Resources & techniques:
141- Persona generation: [Fake Name Generator](https://www.fakenamegenerator.com/), [This Person Does Not Exist](https://thispersondoesnotexist.com/).
142- Browser isolation: [Firefox Multi-Account Containers](https://addons.mozilla.org/firefox/addon/multi-account-containers/), or dedicated profiles per persona.
143- Disposable phone numbers: Burner, Silent Link (some platforms reject VoIP — keep a backlog of numbers).
144- Hardware passkeys for any high-value persona; store recovery codes offline.
145- Audit every browser extension before installation. Supply-chain attacks on popular extensions have repeatedly targeted investigators — assume the popular ones are at higher risk, not lower.
146- Maintain chain-of-custody: timestamp every action, hash every key artifact, record tool versions per case.
147- Personas should look like real low-engagement accounts: profile photo (synthetic), bio, a few low-effort posts spread across weeks before the persona is "used."
148
149References:
150- [Effective Sock Puppets](https://medium.com/@unseeable06/creating-an-effective-sock-puppet-for-your-osint-investigation-95fdbb8b075a)
151- [Ultimate Guide to Sock Puppets](https://osintteam.blog/the-ultimate-guide-to-sockpuppets-in-osint-how-to-create-and-utilize-them-effectively-d088c2ed6e36)
152
153### 6.2 Detectability & OpSec Tagging
154
155Every probe leaves a footprint. Tag every operation in your notes with a detectability level so you can reason about the SIEM trail you're leaving on the target's side.
156
157| Tag | Examples |
158|---|---|
159| **Low** | Passive Shodan InternetDB; CT-log queries (crt.sh); Wayback CDX; passive DNS (SecurityTrails); Hunter.io email enrichment; HTTP HEAD on public buckets; `getuserrealm.srf`; Microsoft OIDC metadata fetch. |
160| **Medium** | Microsoft `GetCredentialType` user-enum; Okta `/api/v1/authn` user-enum; Postman API key validation; AWS `sts:GetCallerIdentity` (logs to CloudTrail); Slack `auth.test`; full-page screenshots; Swagger/GraphQL probes against a 28/13-path wordlist; targeted favicon-hash + JARM fingerprinting. |
161| **High** | Active port scans (naabu / masscan / nmap); Nuclei full template runs against production; subdomain brute-force at scale; APK download from third-party mirrors; deep-mode user enumeration past N attempts per tenant; SMTP `RCPT TO` enumeration; web fuzzing (ffuf/gobuster). |
162
163When working with a client, document the operations actually run and their detectability tag in the engagement report — clients appreciate knowing what their detection stack should have caught.
164
165**Defaults:** passive by default. Active probes only when (a) explicitly authorized, (b) within agreed maintenance windows, and (c) with the operator's awareness of the resulting log volume.
166
167### 6.3 Validator Discipline
168
169When you discover a credential in the wild (a leaked API key, a sourcemap-exposed token, a hard-coded PMAK in a public Postman workspace), you may want to confirm it's live. Do this with **read-only validators only**.
170
171Discipline:
172- Read-only endpoint only (e.g., `/me`, `/whoami`, `auth.test`, `sts:GetCallerIdentity`).
173- Never use the validated credential to create, modify, delete, or send anything.
174- Tag the validation attempt with detectability — every validator generates an audit-log entry on the provider side.
175- Record `checked_at` (UTC), the response (truncated), and the scope/account-ID returned.
176- If the operator's rules of engagement forbid validation, mark the credential `validation_skipped_by_policy` and stop.
177
178Concrete validator endpoints (Postman, AWS, GitHub, Slack, Anthropic, OpenAI, npm, Atlassian, DataDog) live in the companion `offensive-osint` skill.
179
180### 6.4 Detection-Aware Probing (signs of detection + back-off)
181
182Your probes will eventually hit detection. Recognize the signs and back off **before** you trip an active response.
183
184**Signs you've been detected (in roughly increasing severity):**
185
1861. **Rate-limit responses** — `429 Too Many Requests`, `Retry-After` header set, `X-RateLimit-Remaining: 0`.
1872. **Captcha interstitials** — Cloudflare interstitial page, hCaptcha challenge, AWS WAF page.
1883. **WAF page** — explicit "Access denied" with provider branding (Cloudflare, Akamai, Imperva, F5 ASM, AWS WAF, Sucuri).
1894. **Status code drift** — endpoints that previously returned 200/401 now return 403 only from your IP.
1905. **Banner change** — server header shape or response timing changes consistently.
1916. **DNS poisoning back to NXDOMAIN** — target's authoritative servers stop resolving subdomains (probably their CDN took over).
1927. **Honeypot bait** — endpoints that look too good (`/admin/db_dump.sql`, exposed `.env` with credentials that don't validate). Real exposures rarely look this clean.
1938. **Direct contact** — your sock-puppet email gets a "we noticed unusual activity" message; or, in extreme cases, your IP gets a courtesy abuse-contact email.
194
195**Back-off ladder:**
196
1971. **Slow down.** Halve your concurrency. Add 2–10s jitter between requests.
1982. **Switch endpoints.** Stop hitting the path that triggered. Move to a different module of the recon pipeline.
1993. **Switch persona.** New User-Agent (rotate among realistic browsers), new TLS fingerprint (different httpx/curl version).
2004. **Switch IP.** Rotate to a new egress (residential proxy, Tor for sensitive lookups, a different cloud region).
2015. **Pause.** Wait 1–24 hours. Many WAFs have rolling-window IP-based reputation; passive time often resets it.
2026. **Document and consult.** If you've hit (3) WAF, (4) status drift, or (8) direct contact, **stop active probing and consult the engagement lead**. Continued probing past these signals risks scope violation.
203
204**Persona / IP rotation rules:**
205- Never rotate persona to one that's been used in a prior engagement against the same target.
206- Use residential proxies (Bright Data, Smartproxy, IPRoyal) for high-detectability work — but be aware they're sometimes IP-blocklisted by Cloudflare.
207- Tor exit nodes are useful for **passive lookups** (CT logs, archive sites) but are blocked by most active-probe targets.
208- Cloud egress IPs (AWS / GCP / Azure) are often blocklisted aggressively for recon. Use sparingly.
209- Document every rotation with timestamp + reason; reviewers will ask.
210
211**Don't:**
212- Don't try to "outsmart" a confirmed WAF block by sending more aggressive payloads. That's how clients get extra logs and how you get caught.
213- Don't switch source IPs to evade an explicit block-list — that crosses into evasion territory and may breach the rules of engagement.
214- Don't ignore signals because the dashboard says "still up." The probe is being silently logged; the response will come later.
215
216---
217
218## 7. External Red-Team Recon Pipeline
219
220A 5-stage pipeline for any authorized external assessment. Stages are sequential; modules within a stage can run concurrently.
221
222### Stage 1 — Seed Discovery
223Establish the ground truth of who/what the target is.
224
225- WHOIS on the seed domain (registrant, dates, name servers).
226- ASN enumeration: which AS does the org own/use? (Hurricane Electric BGP Toolkit, RIPEstat, BGPView.)
227- DNS records (A/AAAA/MX/TXT/NS/SOA/CAA) — records-only, no walking yet.
228- Certificate Transparency history for the root domain (crt.sh, Censys).
229
230### Stage 2 — Asset Expansion
231Discover everything that might belong to the target.
232
233- Subdomain enumeration (passive sources first: crt.sh, VirusTotal, AlienVault OTX, Shodan, then permutations and bruteforce).
234- Cloud bucket enumeration (S3/GCS/Azure permutations from company name + subdomain stems — see §15).
235- Typosquat domain generation (dnstwist variants → resolve → WHOIS) — for both phishing risk and adjacent corp assets.
236- Wayback CDX archive endpoints for forgotten paths.
237- Mobile app discovery (Android via google-play-scraper, iOS via iTunes Search API — see §14).
238- DNS deep walking (NSEC walk on misconfigured zones, AXFR opportunism).
239- LinkedIn employee enumeration → email-pattern derivation.
240
241### Stage 3 — Enrichment
242Add depth to the discovered assets.
243
244- Port + service detection (Shodan InternetDB free → naabu/masscan if authorized).
245- Live TLS handshakes (cert chain, JARM, favicon mmh3 hash).
246- Web tech detection (Wappalyzer-style ~600 signatures via httpx).
247- WAF/CDN inference (header markers).
248- Origin discovery if behind CDN (see §27).
249- Security header audit.
250- Bulk screenshots (triage 1000s of hosts visually).
251- Email harvesting (6 parallel sources).
252- Email security audit (SPF/DMARC/DKIM/BIMI/MTA-STS).
253- GitHub code-search dorking (13 dork templates × 29+ secret regexes).
254- JavaScript deep analysis (sourcemaps, secrets, endpoints, internal-host leakage).
255- SSO/IdP tenant fingerprinting (Entra, Okta, ADFS, Google, SAML, M365 Teams/SharePoint/OAuth — see §11).
256- API & auth-map discovery (Swagger/OpenAPI, GraphQL, Postman).
257- Secrets-beyond-GitHub sweep (Postman public workspaces, Stack Exchange, Trello/Notion/Atlassian dorks).
258- Vendor product fingerprinting (Citrix/F5/PaloAlto/Pulse/Fortinet/Cisco/VMware/Exchange).
259- Container / CI-CD / cloud-native exposure check.
260- Job posting harvest for tech-stack inference.
261
262### Stage 4 — Exposure Analysis
263Convert assets into findings.
264
265- Nuclei (15 always-on built-in checks + optional binary).
266- TLS deep audit (sslyze / testssl.sh).
267- Breach × identity correlation (HudsonRock Cavalier, HIBP, DeHashed, IntelX, local corpus → SSO_EXPOSURE findings).
268- Targeted misconfiguration probes (`.git/config`, `.env`, `phpinfo.php`, `/actuator/env`, `/actuator/heapdump`, `_cat/indices`, `/console`, `/manager/html`).
269- Vulnerability prioritization (CVE × EPSS × CISA KEV × public-POC availability — see §28).
270
271### Stage 5 — Reporting
272Make the work usable.
273
274- Risk scoring per finding (CVSS + program-specific weights).
275- Asset graph export (D3-friendly nodes/links, GraphML, JSON).
276- Client-facing report (executive summary + technical detail + remediation — see §31).
277- Reproduction package (run_id, tool versions, raw evidence, JSONL log).
278- Bug bounty submission (if applicable — see §30).
279
280### 7.5 Pipeline Priority Order (highest signal density first)
281
282When budget is constrained, work in this order:
283
2841. **Breaches** — infostealer logs (HudsonRock Cavalier free tier) + HIBP + DeHashed. Highest ROI for red teams; often gives valid plaintext creds for corp SSO. Requires emails as input.
2852. **GitHub recon** — code-search dorks. Finds AWS keys, Slack tokens, JWT secrets, `.env` files. Fastest path to cloud pivot.
2863. **Nuclei misconfig sweep** — exposed admin panels, CVEs with public POCs.
2874. **Cloud buckets** — permutate company name + subdomain stems. Listable bucket = CRITICAL.
2885. **Ports** — Shodan InternetDB first (free, keyless). VPN concentrators, RDP, Jenkins, GitLab-CE, Elasticsearch are the high-value pivot points.
2896. **Email OSINT** — feeds breaches; feeds phishing list.
2907. **Web tech / WAF / screenshots** — triage thousands of hosts; know the stack before probing.
2918. **Wayback** — archived JS often has hard-coded keys; archived endpoints reveal removed admin/dev paths.
2929. **DNS deep + email security** — SPF/DMARC gaps enable email spoofing; TXT verification tokens reveal SaaS tenancies.
29310. **Certificates** — CT-log timeline catches forgotten subdomains; weak ciphers = cheap findings.
29411. **ASN + reverse DNS** — corporate IP space hosts unadvertised infra.
29512. **WHOIS** — registrant PII reveals adjacent corp assets.
29613. **Typosquat** — actively-registered squats are findings; unregistered ones go on the phishing-domain shortlist.
29714. **Security headers** — low standalone value but required for client reports.
298
299### 7.6 Time Budgeting & Engagement Profiles
300
301Stage and asset count drive how long a recon takes. Rough estimates (single operator on a typical SaaS-style target):
302
303| Stage | Small org (<100 employees) | Medium (100–1K) | Large (1K+) |
304|---|---|---|---|
305| 1. Seed discovery | 30 min | 30 min | 30 min |
306| 2. Asset expansion | 1–2 h | 2–4 h | 4–8 h |
307| 3. Enrichment (per 100 alive webapps) | ~1 h | ~1 h | ~1 h |
308| 4. Exposure analysis | 1–3 h | 3–6 h | 6–12 h |
309| 5. Reporting | 2–4 h | 4–8 h | 1–2 days |
310
311**Engagement profiles:**
312
313- **1-hour rapid recon ("how exposed is X?")** — Stage 1 (15 min) → passive subdomain (crt.sh + Subfinder, 10 min) → Shodan InternetDB on resolved IPs (5 min) → email harvest via Hunter+IntelX (10 min) → breach lookup on emails (10 min) → executive-summary-only output (10 min).
314- **4-hour focused recon ("phish-readiness check")** — adds: full email harvest, LinkedIn employee enum, SPF/DMARC analysis, typosquat candidate generation, SSO/IdP fingerprinting. Output: phishing-feasibility report + target email list.
315- **1-day standard recon** — full Stages 1–4 with the priority order above. Output: per-asset finding list + asset graph + exec summary.
316- **1-week deep recon** — all of standard, plus: deep-mode user enumeration, JS deep analysis at full budget, mobile attack surface, cloud-native fingerprinting, vendor product fingerprinting, package registry leak hunting, vulnerability prioritization. Output: full client deliverable package + reproduction bundle.
317- **Ongoing monitoring (weekly diff)** — re-run Stages 1–3 weekly; diff against baseline; alert on new asset / new finding / asset disappeared.
318
319**When to abort early:**
320- After Stage 1 if scope is wrong (target turns out to be subsidiary of unrelated corp; rules of engagement need clarification).
321- After Stage 2 if attack surface is below threshold (no public webapps + no exposed services + no leaked emails → little to find externally).
322- During any stage if you hit the WAF / detection signs in §6.4.
323
324---
325
326## 8. Asset Graph Discipline
327
328Treat every discovery as a typed asset in a graph, not a free-floating string.
329
330### 8.1 Asset Taxonomy (29 types)
331
332| Category | Asset Types |
333|---|---|
334| **DNS / Network** | `domain`, `subdomain`, `ip`, `netblock`, `asn` |
335| **Service** | `port`, `service`, `certificate` |
336| **Identity** | `email`, `person`, `credential` |
337| **Code / Config** | `repo`, `secret` |
338| **Cloud / Storage** | `bucket`, `firebase_project` |
339| **Web** | `webapp`, `wayback_endpoint`, `api_endpoint`, `api_spec`, `graphql_schema` |
340| **Mobile** | `mobile_app`, `deep_link`, `exported_component` |
341| **Phishing / Adversarial** | `typosquat_domain` |
342| **Collaboration / SaaS** | `postman_collection`, `postman_workspace`, `postman_api_key`, `stack_post`, `saas_public_surface` |
343
344### 8.2 Asset Schema
345
346Every asset carries:
347- `type` — one of the 29 above.
348- `key` — unique dedup id (typed prefix, e.g. `sub:api.example.com`, `email:alice@example.com`).
349- `value` — the actual string/object.
350- `sources[]` — every source that confirmed this asset (deduplicated).
351- `confidence` — TENTATIVE / FIRM / CONFIRMED.
352- `first_seen`, `last_seen` — UTC timestamps.
353- `attrs{}` — type-specific metadata (e.g., for a `webapp`: status_code, title, tech-stack list, JARM, favicon mmh3, screenshot path).
354
355### 8.3 Edge Taxonomy
356
357Relationships are typed edges, not text:
358`RESOLVES_TO`, `HOSTED_ON`, `IN_NETBLOCK`, `BELONGS_TO_ASN`, `LISTED_IN_CERT`, `OWNED_BY`, `ALIAS_OF`, `BREACHED_FROM`, `EMPLOYED_BY`, `HOSTS_REPO`, `TYPOSQUAT_OF`, `EXPOSES`, `DOCUMENTED_BY`, `BELONGS_TO_HOST`, `REQUIRES_AUTH`, `LEAKS_SCHEMA`, `SHIPPED_BY_ORG`, `CONTAINS_SECRET`, `TALKS_TO_HOST`, `EXPOSES_DEEPLINK`, `HAS_EXPORTED_COMPONENT`, `USES_FIREBASE_PROJECT`, `LACKS_PINNING_FOR`.
359
360### 8.4 Discipline rules
361
362- **Every discovery is an asset.** Don't write findings against free-floating strings; create the asset first, then attach the finding.
363- **Dedup by key, not by value.** Same value, different type ≠ same asset (`sub:api.example.com` and `webapp:https://api.example.com/` are different assets with a `BELONGS_TO_HOST` edge).
364- **Provenance is non-negotiable.** `sources[]` must list every source. If two sources confirmed it, both go in.
365- **Confidence is per-source, then aggregated.** A subdomain returned by 3 passive sources is FIRM; one returned by snippet-only Bing is TENTATIVE.
366- **Late binding via sidecars.** When module A produces output that module B needs, write a JSON sidecar (`mobile_endpoints.json`, `secrets_sidecar.json`) — don't block module B on module A. See §24.
367
368### 8.5 Asset-Level Triage Rules
369
370When you have a mixed bag of assets and limited probe budget, prioritize by what each asset *enables*:
371
372**WebApp priority by hostname signal (highest first):**
373
3741. Auth-related hostnames (`auth.`, `login.`, `sso.`, `idp.`, `accounts.`, `oauth.`).
3752. Admin paths (`/admin`, `/dashboard`, `/console`, `/manager`, `/wp-admin`, `/phpmyadmin`).
3763. Dev/staging hosts (`dev.`, `staging.`, `stg.`, `qa.`, `uat.`, `test.`, `sandbox.`, `preprod.`, `preview.`) — lower defenses, often dump prod data.
3774. API hostnames (`api.`, `services.`, `gateway.`, `graph.`).
3785. Customer-facing hostnames (`portal.`, `app.`, `my.`, `account.`).
3796. Marketing / content (`www.`, `blog.`, `news.`, `careers.`, `support.`).
380
381**Subdomain priority by inferred function:**
382
383- API > Admin > Dev > Auth > Prod-app > Marketing.
384
385**IP priority by netblock:**
386
387- Corporate ASN-owned (most likely to host unadvertised internal infra).
388- Cloud netblocks (AWS / GCP / Azure / DO / OVH) — high turnover but interesting for cloud-native services.
389- CDN ranges (Cloudflare / Akamai / Fastly) — usually edge, not origin; defer unless doing origin discovery.
390
391**Email priority by role hint:**
392
393| Role indicator | Priority | Why |
394|---|---|---|
395| `ceo@`, `cfo@`, `cto@`, `ciso@` | HIGHEST | Exec accounts have highest breach value (BEC, finance authority, board access). |
396| `it@`, `helpdesk@`, `support@`, `security@` | HIGH | IT/security accounts have privileged tool access; helpdesk accounts handle reset workflows. |
397| `dev`, `engineer`, `architect`, `dba` | MEDIUM | Developer accounts often have GitHub / cloud / CI access. |
398| `sales`, `marketing`, `hr`, `finance` | MEDIUM | SaaS access (Salesforce, HubSpot, Workday); finance enables BEC. |
399| Generic role accounts (`info@`, `noreply@`, `contact@`) | LOW | Often unmonitored or alias forwarded; less personal context. |
400
401**Repo priority by recency + naming:**
402
403- Recently-pushed (last 30 days) > stale.
404- Public repo with target name in description > target name only in code.
405- Forked from internal-looking parent > standalone.
406- Mentions `prod`, `internal`, `private`, `secret` in name → priority HIGH despite being public (may be misnamed or accidentally exposed).
407
408**Application order:** when you have N assets and budget for M probes (M < N), apply asset-type priority first, then within-type priority. E.g.: 50 subdomains → probe API + admin + dev first (~15), then auth + prod-app (~20), defer marketing/content to a later pass.
409
410---
411
412## 9. Findings Rubric & Severity Mapping
413
414Severity is operational, not subjective. Use these anchors:
415
416### 9.1 CRITICAL
417
418Pre-auth code execution, confirmed valid credentials, listable production data, fundamental trust violations.
419
420Examples:
421- `.git/config` exposed on production webapp (full source-code disclosure).
422- `/.env` exposed (credentials in plaintext, often DB / cloud / API).
423- Spring Boot `/actuator/env` or `/actuator/heapdump` reachable unauthenticated.
424- Listable S3 / GCS / Azure bucket containing user data.
425- Unauthenticated POST/PUT/DELETE to a write endpoint that mutates state.
426- Open Firebase Realtime Database (`https://{project}.firebaseio.com/.json` returns data).
427- `android:debuggable=true` in a production Android app.
428- Live-validated credential (PMAK, AWS key, Anthropic/OpenAI key) with broad scope.
429- ≥10 employees compromised in a breach corpus + their tenant identified (SSO_EXPOSURE).
430- Open Elasticsearch cluster (`/_cat/indices` returns data).
431- Open Docker API (`/v1.40/containers/json` returns containers).
432- Open Redis (no AUTH; can write `authorized_keys`).
433- Open Kubernetes API server with anonymous-auth enabled.
434- Open kubelet on 10250 (pod exec without auth).
435- Open etcd on 2379 (cluster state and secrets).
436- BlueKeep-vulnerable RDP, EternalBlue-vulnerable SMB.
437- Citrix Netscaler / F5 BIG-IP with version-specific RCE CVE.
438
439### 9.2 HIGH
440
441Significant exposure but not yet RCE; clear path to escalation; high-value information disclosure.
442
443Examples:
444- Public secret in a GitHub repo (PAT, AWS key, Slack token, etc.).
445- Sourcemap (`.js.map`) accessible — full original-source disclosure of frontend.
446- Open GraphQL introspection on production (full schema leaked → mutations to enum).
447- Subdomain takeover possible (CNAME points to unclaimed Heroku/Shopify/etc.).
448- Reflected CORS with credentials (`Access-Control-Allow-Origin: <reflected>` + `Access-Control-Allow-Credentials: true`).
449- Verb tampering: hidden DELETE/PATCH on an endpoint that publicly only allows GET.
450- Missing HSTS on a sensitive path (`/login`, `/sso`, `/admin`, `/auth`) — escalated from MED.
451- Exposed Jenkins/Tomcat-Manager/phpMyAdmin admin UI (no auth or default creds).
452- Telnet (port 23) reachable.
453- WebView with JS bridge in a mobile app (XSS → RCE potential).
454- Sensitive deep-link handler in a mobile app.
455- DMARC policy `p=none` on production sending domain (spoof-feasible).
456- Vendor product banner with known unpatched CVE (KEV-listed).
457
458### 9.3 MEDIUM
459
460Information disclosure, hardening gaps, brute-force exposure.
461
462Examples:
463- Missing security headers on standard pages: HSTS, CSP.
464- Apache `/server-status` or `/server-info` reachable.
465- `phpinfo()` or `/info.php` reachable on dev/staging only.
466- Internal IP / hostname / K8s service DNS leaked in JS.
467- Schema leakage in error pages (stack traces, ORM signatures).
468- `android:allowBackup=true` in Android app.
469- `android:usesCleartextTraffic=true` in Android app.
470- Exported activity/service without `android:permission` protection.
471- Missing rate-limit on an API endpoint.
472- Wildcard CORS (`Access-Control-Allow-Origin: *`) on an API that returns user-tied data (no creds).
473- Slack webhook URL leaked.
474- Twilio Account SID leaked (without auth token).
475- SPF record permissive (`+all` or many includes).
476
477### 9.4 LOW
478
479Cosmetic or marginal hardening gaps.
480
481Examples:
482- Missing `X-Frame-Options`.
483- Missing `X-Content-Type-Options`.
484- `.DS_Store` exposed.
485- Stripe **test** key leaked.
486- Firebase URL exposed (URL only, no open RTDB).
487- Certificate pinning missing in mobile app.
488- Outdated WordPress install detected (no known exploit yet).
489- BIMI not configured (brand impersonation risk only).
490
491### 9.5 INFO
492
493Worth recording, no action required immediately.
494
495Examples:
496- Missing `Referrer-Policy` / `Permissions-Policy`.
497- Discovered `/.well-known/security.txt`.
498- `robots.txt` reveals interesting paths.
499- Private bucket exists but is locked down.
500- Domain detected in a breach corpus with 0 employee accounts.
501- DNSSEC not enabled.
502
503### 9.6 Severity escalation rules
504
505- HSTS missing on auth/login/SSO/admin path → **MED → HIGH**.
506- Wildcard CORS + credentials → **MED → HIGH**.
507- Wildcard CORS + sensitive endpoint → **LOW → MED**.
508- API endpoint with score ≥70 on the interest rubric (companion skill §20) → at least **HIGH**.
509- Domain breach severity ≥10 employees → **CRITICAL** regardless of stale-data caveats.
510- Vendor product version matches CISA KEV entry → **CRITICAL**.
511- DMARC `p=reject` + SPF strict + DKIM rotated → no escalation; well-postured.
512
513---
514
515## 10. Bug-Bounty / Red-Team Pivot Modes
516
517Existing investigative work (threat-actor research, doxxing investigations, attribution) operates under different posture than offensive recon. Switch posture explicitly.
518
519| Aspect | Investigative Mode | Offensive Recon Mode |
520|---|---|---|
521| **Probing rate** | Slow, single-threaded, blend with normal traffic. | Bursts, parallel, but rate-limited per provider. |
522| **OpSec posture** | Sock-puppet only, never reveal investigator. | Persona may be the engagement persona; team may notify SOC. |
523| **Evidence handling** | Court-grade chain of custody; hashes, timestamps, screenshots. | Engagement-grade; same hashing/timestamp discipline but evidence is for the client report. |
524| **Severity in scope** | All severity levels relevant for context. | CRIT/HIGH/MED matter; LOW/INFO often dropped from exec summary. |
525| **Authorization posture** | Public-record / OSINT-only; no probing private resources without authorization. | Written rules of engagement; explicit scope; explicit out-of-scope list. |
526| **Reporting format** | Narrative + sourced timeline. | Per-asset findings + remediation + reproduction steps. |
527| **Stop conditions** | When the question is answered. | When the engagement window closes OR when the report is delivered. |
528
529When you're working with the user, ask which mode they're in if it's unclear from context.
530
531### 10.1 Scale-Based Tactics
532
533Org size shapes which techniques pay off.
534
535**Small org (< 100 employees):**
536- Executive accounts disproportionately matter; one CEO/CFO compromise often hands you the keys.
537- Email harvest is small enough to enumerate exhaustively (10–50 emails total).
538- Likely Microsoft 365 or Google Workspace; identity fabric is one tenant.
539- Code repos often public on GitHub under personal accounts (founders moved from solo dev).
540- Cloud presence often single-account AWS or GCP project.
541- Tactics: deep on every email + every identity-fabric finding; full LinkedIn enum; check founders' personal GitHub orgs.
542
543**Medium org (100–1K):**
544- Balanced enumeration. Email list is enumerable but not exhaustive.
545- Identity fabric likely one IdP but with multiple SaaS tenants (Slack workspace, Notion org, GitHub org).
546- Mobile apps possible; check both stores.
547- Cloud presence multi-account or multi-region.
548- Tactics: full pipeline at standard depth; sample-and-deepen on each asset class; LinkedIn priority by role.
549
550**Large org (1K–10K):**
551- Email enum becomes lossy (sample top roles); breach hits scale up.
552- Multi-tenant identity fabric (often Entra + Okta + multiple Auth0 customers).
553- Mobile apps, multiple Android packages from different teams.
554- Cloud presence sprawling; subsidiaries / acquisitions complicate scope.
555- Tactics: breadth-first; rely on automation for asset discovery; manual triage on findings.
556
557**Very large org (10K+) or conglomerate:**
558- Brand-pivot maps before anything else: enumerate every brand domain, every subsidiary.
559- Breach corpus dominates: 10K+ employees mean significant past-breach exposure.
560- Identity fabric may differ per business unit (legal entity boundaries).
561- Tactics: scope pruning is the most important step; sampling + automation throughout; deep dive only on high-priority findings.
562
563**Cross-scale principle:** the smaller the org, the more individual-account focus pays off. The larger the org, the more systemic posture findings (DMARC gaps, SSO_EXPOSURE breadth, vendor-product version sweeps) pay off.
564
565---
566
567## 11. Identity Fabric Mapping
568
569An organization's IdP/SSO posture is a high-value target: compromise the identity fabric and you don't need to break into individual apps. Map it methodically.
570
571### 11.1 Subdomain prefix enumeration
572
573Probe these prefixes against the target's root domain (and any sibling brand domains discovered):
574
575```
576auth.{domain}
577login.{domain}
578sso.{domain}
579idp.{domain}
580iam.{domain}
581identity.{domain}
582accounts.{domain}
583oauth.{domain}
584```
585
586Plus generic OIDC discovery on every alive subdomain:
587```
588{any-host}/.well-known/openid-configuration
589```
590
591### 11.2 Microsoft Entra (Azure AD)
592
593- **OIDC metadata + tenant GUID extraction** — fetch `https://login.microsoftonline.com/{tenant-or-domain}/.well-known/openid-configuration`. The `issuer` field returns a URL containing the tenant GUID (8-4-4-4-12 hex format). Tenant GUID + domain = stable tenant fingerprint.
594- **getuserrealm.srf** — `https://login.microsoftonline.com/getuserrealm.srf?login=<user>@<domain>` returns NameSpaceType: `Managed` (cloud-native), `Federated` (on-prem ADFS / external IdP), or `Unknown`. Detectability: low.
595- **Autodiscover v2** — `https://autodiscover-s.outlook.com/autodiscover/metadata/json/1` POST with email; detects tenant membership.
596- **GetCredentialType** (deep-mode user-enum) — `https://login.microsoftonline.com/common/GetCredentialType` POST `{"username": "<email>"}`. Response indicates whether email exists in tenant. Detectability: medium. Cap attempts at 20 per tenant.
597
598### 11.3 Okta
599
600- **Org slug derivation** — derive candidate slugs from subdomains + root domain stem; Okta tenants live at `<slug>.okta.com` (or `<slug>.oktapreview.com`).
601- **OIDC fingerprint** — `https://<slug>.okta.com/.well-known/openid-configuration`.
602- **/api/v1/authn user-enum** (deep-mode) — POST `{"username": "<email>", "password": "invalid"}`. 400 vs 401 response code indicates user existence. Detectability: medium. Cap at 20 per tenant.
603
604### 11.4 ADFS
605
606- **Passive fingerprint** — GET `https://{domain}/adfs/idpinitiatedsignon.aspx` → 200 indicates ADFS present.
607- **Active mex endpoint** (deep-mode) — `https://{domain}/adfs/Services/Trust/mex` returns SOAP metadata.
608
609### 11.5 Google Workspace
610
611- `https://{domain}/.well-known/openid-configuration` — Google-hosted-domain customers expose discovery endpoints with characteristic issuer/JWKS URIs.
612- MX records pointing to `*.googlemail.com` / `aspmx.l.google.com` is a strong Google Workspace signal.
613
614### 11.6 Generic OIDC (Keycloak / Auth0 / Ping / OneLogin / Duo)
615
616- Probe every alive subdomain for `/.well-known/openid-configuration`.
617- The `issuer` and `authorization_endpoint` fields fingerprint the IdP product.
618- `*.auth0.com`, `*.onelogin.com`, `*.pingone.com`, `*.duosecurity.com` patterns are characteristic.
619
620### 11.7 SAML metadata
621
622Probe these paths on every alive webapp:
623
624```
625/saml/metadata
626/FederationMetadata/2007-06/FederationMetadata.xml
627/federationmetadata/2007-06/federationmetadata.xml
628/simplesaml/saml2/idp/metadata.php
629/auth/saml2/metadata
630```
631
632SAML metadata XML contains: `EntityID`, signing certs, `SingleSignOnService` URL, `NameIDFormat`.
633
634### 11.8 AWS account-ID extraction
635
636- **S3 bucket region header** — HEAD on a known target bucket returns `x-amz-bucket-region`; correlate with bucket-name entropy to infer account.
637- **ARN regex in JSON / HTML responses** — search for `arn:aws:[a-z0-9-]+:[a-z0-9-]*:([0-9]{12}):` (the 12-digit AWS account ID is the capture group).
638- **`AccountId` property in JS / API responses** — common in IAM-related error messages and CloudFormation outputs.
639- **OAuth client_id leaks** — Google OAuth: `<digits>-<chars>.apps.googleusercontent.com`; MSAL: GUID in `clientId` property.
640
641### 11.9 Output
642
643Each discovered IdP becomes a `Ser
644
645…(truncated)