asn-infrastructure-mapping

asn-infrastructure-mapping is a skill for Claude Code, Codex from uphiago/recon-skills. It costs 24 tokens per session (1,828 once invoked), scanned A, original, MIT.

An infrastructure-mapping procedure that traces an organization’s domain to its network ranges, related hostnames, and services. An ASN is a public identifier for a network, while CIDR ranges describe blocks of IP addresses.

In plain words
What is it for?
Authorized security assessments that map an organization’s owned IP space, related top-level domains, reverse-DNS names, and services on unusual ports.
Why use it?
It can reveal systems that ordinary subdomain searches or website-only checks miss.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: positional $N argument.

Good fit Authorized security assessments that map an organization’s owned IP space, related top-level domains, reverse-DNS names, and services on unusual ports.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/uphiago/recon-skills/asn-infrastructure-mapping
About the project

Recon Skills is a pack of security-testing skills covering reconnaissance, web applications, APIs, authentication, vulnerability validation, cloud infrastructure, and reporting. Security professionals use it for authorized assessments of systems they own or have written permission to test. The catalogue entries are individual skills from the pack.

uphiago/recon-skills · 1,251 stars · on GitHub · hiago.sh

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add uphiago/recon-skills --skill asn-infrastructure-mapping
Clone the repo
git clone --depth 1 https://github.com/uphiago/recon-skills

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for asn-infrastructure-mapping

README.md
[![agentmods](https://agentmods.dev/badge/skills/uphiago/recon-skills/asn-infrastructure-mapping/github.svg)](https://agentmods.dev/skills/uphiago/recon-skills/asn-infrastructure-mapping)
Your own site
<a href="https://agentmods.dev/skills/uphiago/recon-skills/asn-infrastructure-mapping"><img src="https://agentmods.dev/badge/skills/uphiago/recon-skills/asn-infrastructure-mapping/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for asn-infrastructure-mapping

Your own site · 80×15
<a href="https://agentmods.dev/skills/uphiago/recon-skills/asn-infrastructure-mapping"><img src="https://agentmods.dev/badge/skills/uphiago/recon-skills/asn-infrastructure-mapping.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 24 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,828 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector warn 7 Sept 2026
SkillSpector: 2 findings, up to high

These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →

  • high YARA Match · line 71
    YARA rule matched a hack tool or exploit indicator (offensive tools, reconnaissance, privilege escalation, or exploit frameworks).
    Fix: Remove offensive tool references and exploit code. Legitimate agent skills should not contain penetration testing tools, exploit frameworks, or reconnaissance utilities.
  • medium Data Exfiltration · line 124
    Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.
    Fix: Verify the destination URL is trusted and necessary. Remove or replace with documented APIs. Ensure no secrets, tokens, or PII are transmitted.
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00024 $0.01828
Opus 5 $0.00012 $0.00914
Sonnet 5 $0.00005 $0.00366
Haiku 4.5 $0.00002 $0.00183

Measured 10d ago against content hash f7f0bede906f, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-10, from the pricing page.

Security

Grade A, and why

asn-infrastructure-mapping scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 10d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

compatibility: Requires curl, dnsx, httpx
recon/asn-infrastructure-mapping/SKILL.md · 190 lines

How it starts

The opening of the file, as written. The whole thing — 190 lines — stays where its author put it; the contents beside it link to each section on GitHub.

ASN Infrastructure Mapping

Map an organization's entire IP infrastructure by pivoting from domain to ASN (Autonomous System Number), extracting CIDR ranges, and discovering every hostname and service across all owned IP blocks. Includes TLD expansion to find sibling domains on different top-level domains with separate infrastructure.

When to Use

  • You have a target domain and want to discover EVERY IP owned by the organization.
  • Passive subdomain enumeration found only a few hosts — the rest may be on sibling TLDs or different IP ranges.
  • The target has a known ASN that can be expanded to full CIDR blocks.
  • Services on non-standard ports are invisible to web-only recon.
  • Acquired subsidiaries or international domains may sit on different ASNs with weaker security.

Prerequisites

  • terminal whois, dnsx, mapcidr, httpx, and asnmap.
  • The target domain and/or a known IP belonging to the organization.
  • Shodan API key (optional, for deeper OSINT).

Quick Detection

# Start: domain → IP → ASN → CIDR ranges
IP=$(dig target.com +short | head -1)
ASN=$(whois $IP | grep -i "origin\|OriginAS" | awk '{print $NF}' | head -1)
echo "ASN: $ASN"
whois -h whois.radb.net -- "-i origin $ASN" | grep -Eo "([0-9.]+){4}/[0-9]+" | sort -u

Procedure

Phase 1 — Domain to ASN Discovery

# asnmap — automated domain → ASN
asnmap -d target.com

# Manual whois approach
IP=$(dig target.com +short | head -1)
whois $IP | grep -iE "origin|OriginAS|route:|descr:" | head -10

# spk — finds all ASNs for a company by name (including subsidiaries)
spk -json -s "Company Name"

# Webtools
# https://bgp.he.net — search by company name
# https://asnlookup.com — search by org name, ASN, or CIDR
# https://bgp.tools — modern BGP explorer

Phase 2 — ASN to CIDR Ranges

# asnmap — direct CIDR extraction
asnmap -a AS33905 -silent > cidr_ranges.txt

# RADB whois — full route objects
whois -h whois.radb.net -- "-i origin AS33905" \
  | grep -Eo "([0-9.]+){4}/[0-9]+" \
  | sort -u >> cidr_ranges.txt

# metabigor — multi-source IP intelligence
echo "Company Name" | metabigor net --org -o cidr_ranges.txt
echo "ASN33905" | metabigor net --asn -o cidr_ranges.txt

Read the full file on GitHub · 190 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 10d ago First seen · 190 lines · 24 tokens per session scan A f7f0bede906f

Subscribe to this mod's changes

asn-infrastructure-mapping is a skill published in the GitHub repository uphiago/recon-skills (1,251 stars, last pushed 8d ago), licensed MIT. It adds 24 tokens to every session and 1,828 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

implementing-cloud-dlp-for-data-protection

Implementing Cloud Data Loss Prevention (DLP) using Amazon Macie, Azure Information Protection, and Google Cloud DLP API to discover, classify, and protect sensitive data across cloud storage, databases, and data pipelines.

xalgorix/xalgorix · 54 tokens

auditing-gcp-iam-permissions

Auditing Google Cloud Platform IAM permissions to identify overly permissive bindings, primitive role usage, service account key proliferation, and cross-project access risks using gcloud CLI, Policy Analyzer, and IAM Recommender.

xalgorix/xalgorix · 51 tokens

auditing-terraform-infrastructure-for-security

Auditing Terraform infrastructure-as-code for security misconfigurations using Checkov, tfsec, Terrascan, and OPA/Rego policies to detect overly permissive IAM policies, public resource exposure, missing encryption, and insecure defaults before cloud deployment.

xalgorix/xalgorix · 59 tokens

detecting-compromised-cloud-credentials

Detecting compromised cloud credentials across AWS, Azure, and GCP by analyzing anomalous API activity, impossible travel patterns, unauthorized resource provisioning, and credential abuse indicators using GuardDuty, Defender for Identity, and SCC Event Threat Detection.

xalgorix/xalgorix · 55 tokens

detecting-misconfigured-azure-storage

Detecting misconfigured Azure Storage accounts including publicly accessible blob containers, missing encryption settings, overly permissive SAS tokens, disabled logging, and network access violations using Azure CLI, PowerShell, and Microsoft Defender for Storage.

xalgorix/xalgorix · 52 tokens

detecting-s3-data-exfiltration-attempts

Detecting data exfiltration attempts from AWS S3 buckets by analyzing CloudTrail S3 data events, VPC Flow Logs, GuardDuty findings, Amazon Macie alerts, and S3 access patterns to identify unauthorized bulk downloads and cross-account data transfers.

xalgorix/xalgorix · 63 tokens