# Install asnmap on Windows, macOS and Linux

Map an organisation, domain or IP to its ASNs and network ranges.

asnmap answers the question of who owns a block of the internet. Give it an organisation, a domain, an IP address or an AS number and it returns the matching network ranges, ready to hand to a port scanner. It needs a free ProjectDiscovery Cloud API key.

## How to install asnmap

```
ot install asnmap
```

ot downloads asnmap 1.2.0 as a prebuilt binary from [github.com/projectdiscovery/asnmap](https://github.com/projectdiscovery/asnmap/releases) and verifies its SHA-256 checksum before installing it. Nothing has to be compiled.

If you do not have ot yet:

macOS and Linux:

```
curl -fsSL https://otinstaller.com/install.sh | sh
```

Windows (PowerShell):

```
irm https://otinstaller.com/install.ps1 | iex
```

Current version: 0.3.0. Both scripts verify the download against its [SHA-256 checksum](https://otinstaller.com/releases/v0.3.0/checksums.txt) before installing.

## How to use asnmap

Arguments after the tool's name go straight to asnmap.

List the network ranges behind a domain.

```
ot run asnmap -d example.com
```

List the ranges registered to an organisation.

```
ot run asnmap -org GOOGLE -silent
```

Expand one AS number into its ranges.

```
ot run asnmap -a AS15169
```

`ot run asnmap --help` lists every option.

An AI agent can run asnmap too: `ot mcp` serves it over the Model Context Protocol. See [OSINT with AI agents](https://otinstaller.com/mcp/).

## API keys for asnmap

asnmap reads these environment variables. Store one with `ot keys set NAME` and ot passes it to asnmap on every run.

| Variable | Purpose |
|---|---|
| `PDCP_API_KEY` | ProjectDiscovery Cloud Platform key |

## asnmap licence, platforms and versions

- Project: https://github.com/projectdiscovery/asnmap
- Licence: MIT
- Runs on: Windows, macOS and Linux
- Takes: domain, ip
- Categories: network, asn, recon
- Sends traffic to the target: no
- Release binary: version 1.2.0 from github.com/projectdiscovery/asnmap, verified by SHA-256

## Questions about asnmap

### How do I install asnmap on Windows?

Open PowerShell and install ot with `irm https://otinstaller.com/install.ps1 | iex`. Then run `ot install asnmap`. ot fetches a pinned version of asnmap and keeps it under `~/.ot`, apart from the rest of your system.

### Is asnmap free?

Yes. asnmap is open source, released under the MIT licence. ot, which installs it, is free under the Apache 2.0 licence.

### Do I need Go or a compiler to install asnmap?

No. ot downloads the prebuilt asnmap binary for your platform and checks its SHA-256 checksum. A mismatch installs nothing.

### How do I update or remove asnmap?

`ot update asnmap` moves it to the version pinned in ot's registry, and `ot update asnmap --latest` to the newest upstream release. `ot remove asnmap` uninstalls it.

## Tools related to asnmap

- [naabu](https://otinstaller.com/tools/naabu/): Fast port scanner for finding open ports on hosts.
- [nmap](https://otinstaller.com/tools/nmap/): Network mapper for host discovery, port scanning and service detection.
- [amass](https://otinstaller.com/tools/amass/): In-depth attack surface mapping and subdomain discovery from many data sources.
- [bbot](https://otinstaller.com/tools/bbot/): Recursive OSINT automation: subdomains, emails, web and cloud findings in one run.
- [cdncheck](https://otinstaller.com/tools/cdncheck/): Identify the CDN, cloud provider or WAF in front of an IP or domain.
- [dnsx](https://otinstaller.com/tools/dnsx/): Fast DNS toolkit for resolving and probing large lists of hostnames.

More: [Networks and hosts](https://otinstaller.com/osint-tools/networks/).
