Skip to content

Instantly share code, notes, and snippets.

@stevenswafford stevenswafford/
Last active Aug 29, 2015

What would you like to do?
Maps DNS from a given domain.
#!/usr/bin/env python
# Description : Maps DNS from a given domain.
import socket
import sys
domain = raw_input("Enter domain: ")
ip = socket.gethostbyname(domain)
except socket.gaierror:
print "Invalid Domain: " + domain
print "DNS: " + ip
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.