Skip to content

Instantly share code, notes, and snippets.

@lrckt
Created June 1, 2022 05:48
Show Gist options
  • Save lrckt/7ab9044c6c2dcdd910428cfa5d7ccbaf to your computer and use it in GitHub Desktop.
Save lrckt/7ab9044c6c2dcdd910428cfa5d7ccbaf to your computer and use it in GitHub Desktop.
import dns.resolver
f = open("subdomains.txt","r").readlines()
for i in f:
tmp = i.replace("\n","")
try:
result = dns.resolver.resolve(tmp, 'CNAME')
print("%s,%s" % ( tmp , result[0]))
except:
pass
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment