HEDnsExtractor is back. Version 1.1 reads the PTR column of bgp.he.net, gets past the 1000 records the site shows per network, and replaces the flat list of domains with a report you can investigate from. This post shows what changed and five ways to use it.

The demo is a rendering of real output from version 1.1.1, captured on 2026-12-04. The waiting time between request and result was cut.

Installation

go install -v github.com/HuntDownProject/hednsextractor/cmd/hednsextractor@latest

Version 1.1.1 needs Go 1.26 or newer.

What is new

PTR records

The “DNS Records” tab of a network on bgp.he.net has three columns: the IP address, its reverse name (PTR) and the hostnames that resolve to it (A). Older versions only read the A column, so an IP address that had a PTR and no A record was thrown away.

Version 1.1 keeps both. On 191.96.225.0/24, that takes the result from 65 hostnames to 176.

PTR names come in two kinds. Some are set by whoever runs the server (mail.example.com); most are generated by the provider from the IP address (191-96-225-7.isp.net). The second kind says who owns the address space and nothing else, so the report collapses them into a single line per network. Use -all-ptr to list them one by one.

Networks with more than 1000 records

bgp.he.net shows at most 1000 IP addresses per network page. When a page comes back full, HEDnsExtractor now halves the network and queries each half, again and again, until every piece fits.

The /16 in the demo has 12534 IP addresses with DNS records. Before, the tool stopped at the first 1000. -split-depth sets how many times a network may be halved (default 8) and -delay sets the pause between requests (default 300 ms).

A report instead of a list

The default output groups hostnames by network and IP address and ends with a summary:

== Summary
  networks: 1   IPs with DNS records: 254
  hostnames from A records: 65   from PTR: 111 (+101 auto-generated PTRs)
  registrable domains: 128
  PTR owners:        as270353.com.br (125), lurahosting.com.br (14), cubo.net.br (7), +69 more
  top TLDs (A):      com (25), sbs (8), fun (6), site (6), app (4), top (4), +9 more
  busiest IPs (A):   191.96.225.7 (14), 191.96.225.202 (6), 191.96.225.143 (5), +7 more

Each line answers a question you would otherwise have to script:

  • PTR owners tells you who operates the address space.
  • top TLDs shows the mix of the hosted names; a network full of .sbs, .fun and .top reads differently from one full of .org.
  • busiest IPs points at the addresses that host the most names, which is where shared hosting and bulk registrations show up.
  • most subdomains lists the registrable domains with the most hostnames in the range.

Results go to stdout and log messages go to stderr, so the report can be piped or saved with -o without the banner getting in the way.

Use cases

1. Pivot from one indicator to its neighbours

You have a single domain or IP address from an alert. The target can be either; HEDnsExtractor first finds the networks that announce it, then lists everything else that lives there.

# which networks is this domain on?
hednsextractor -target example.com -only-networks

# everything hosted next to it
hednsextractor -target example.com

Infrastructure that is set up in bulk tends to sit together, so the neighbours of one confirmed indicator are a good place to look for the next.

2. Map a whole allocation

For an inventory of your own address space, or of a provider you are studying, give the network itself. The 1000 records limit no longer applies:

hednsextractor -target 143.107.0.0/16 -o report.txt

In the demo this takes about 40 seconds for 12534 IP addresses.

3. Find the names that point into a network

-source a keeps only the hostnames that resolve to the range and drops the reverse names:

hednsextractor -target 143.107.0.0/16 -source a

On your own network, this is a quick way to find domains you did not know were pointing at you: forgotten projects, records left behind after a migration, names registered by someone outside the IT team. -source ptr does the opposite and shows only how the owner named the hosts.

4. Hunt by naming pattern

-regex filters hostnames, in any output format:

# name servers announced in the reverse zone
hednsextractor -target 143.107.0.0/16 -source ptr -regex '^ns[0-9]*\.' -csv

# look-alikes of a brand in a hosting range
hednsextractor -target 191.96.225.0/24 -regex '(acme|acrne|4cme)'

For a hunt you repeat, put the targets and the regex in a workflow file:

# brand.yaml
domains:
  - example.com
networks:
  - 191.96.225.0/24
regex: "^(login|secure|account)[.-]"
hednsextractor -workflow brand.yaml -silent | sort > today.txt
comm -13 yesterday.txt today.txt   # what is new since the last run

5. Feed other tools

-silent prints one hostname per line, ready for a pipeline:

hednsextractor -target 191.96.225.0/24 -silent | httpx -title -tech-detect -status-code

-json writes one object per line with the context needed to pivot again, and -csv writes the same fields for a spreadsheet:

{"host":"ns1.fea.usp.br","apex":"usp.br","source":"PTR","ip":"143.107.88.2","ptr":"ns1.fea.usp.br","network":"143.107.0.0/16"}
# registrable domains with the most hostnames in the range
hednsextractor -target 191.96.225.0/24 -json | jq -r .apex | sort | uniq -c | sort -rn | head

With a VirusTotal API key, -vt -vt-api-key <key> -vt-score 5 adds the score to every hostname and keeps only the ones at or above the threshold.

Also in this release

  • The web interface and the API listen on localhost by default and accept a bearer token (HEDNS_API_TOKEN).
  • Dependencies were updated; all open security alerts on the repository are closed.
  • The full list of options is in the README.

Everything HEDnsExtractor shows is public data from bgp.he.net. A hostname in a result is a lead, not a verdict: check it before acting on it.