Skip to content

Instantly share code, notes, and snippets.

@dadevel
Last active January 23, 2025 08:32
Show Gist options
  • Save dadevel/a5ca7b489ae0533dddc33ff3db5f6a81 to your computer and use it in GitHub Desktop.
Save dadevel/a5ca7b489ae0533dddc33ff3db5f6a81 to your computer and use it in GitHub Desktop.
Shodan InternetDB Reverse DNS Lookup
#!/usr/bin/env bash
set -euo pipefail
# usage: cat ./subnets.txt | mapcidr | inetdb-rdns
xargs -I {} -n 1 -P 16 -r -- curl -sS https://internetdb.shodan.io/{} | \
jq -r 'select(.hostnames!=null)|.hostnames[]' | \
sort -Vu
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment