![]() |
|
Python - Website Recon Tool - Printable Version +- Sinisterly (https://sinister.ly) +-- Forum: Hacking (https://sinister.ly/Forum-Hacking) +--- Forum: Hacking Tools (https://sinister.ly/Forum-Hacking-Tools) +--- Thread: Python - Website Recon Tool (/Thread-Python-Website-Recon-Tool) |
Python - Website Recon Tool - Eclipse - 09-28-2014 ![]() Python - Website Recon Tool ![]() WebsiteRecon.py Code: Code: import socket
import dns.resolver
import urllib.request
#Coded for SL by Eclipse
print()
print("==================================================")
print("--------------------------------------------------")
print("==================================================")
print()
print()
print(" =-=-=-=-=-Website Recon-=-=-=-=-= ")
print()
print()
print("==================================================")
print("--------------------------------------------------")
print("==================================================")
def main():
print()
url = input("Enter the website URL (Don't include 'http://')~: ")
http = 'http://'
http_url = str(http + url)
print()
print("Analyzing", http_url)
print()
try:
hostname = socket.gethostbyname(url)
nameserver = dns.resolver.query(url,'NS')
print("[+]Server IP: ", hostname)
for server in nameserver:
print("[+]Nameserver: ", server)
print("[+]Grabbing banner...")
banner_grab = urllib.request.urlopen(http_url).info()
print("----------")
print(banner_grab)
print("----------")
except:
print("[+]Unknown Error!")
main()
main()
main()Github: https://github.com/Eclipse-kun/eclipse/blob/master/WebsiteRecon.py RE: Python - Website Recon Tool - Kizaru - 09-28-2014 What are all these empty prints for? Code: print()
print()
print(" =-=-=-=-=-Website Recon-=-=-=-=-= ")
print()
print()RE: Python - Website Recon Tool - Shebang - 09-28-2014 (09-28-2014, 09:17 PM)Yagmi Wrote: What are all these empty prints for? I mean, they're clearly for spacing the text, but @Eclipse, you should really just do this: Code: print("\n\n =-=-=-=-=-Website Recon-=-=-=-=-= \n\n")RE: Python - Website Recon Tool - Adorapuff - 09-28-2014 You should check if http is included in the string instead of telling people how they should input the string. Otherwise good job. RE: Python - Website Recon Tool - Dyme - 09-28-2014 (09-28-2014, 09:31 PM).Shebang Wrote: I mean, they're clearly for spacing the text, but @Eclipse, you should really just do this: ooor because python is soo gangster at making your life easier: ![]() EDIT: (09-28-2014, 08:33 PM)Eclipse Wrote: lol what happened to raw_input()? RE: Python - Website Recon Tool - Shebang - 09-28-2014 (09-28-2014, 09:50 PM)Dyme Wrote: ooor because python is soo gangster at making your life easier: Presumably he's using Python 3.x+. raw_input() became input(). Before that, input() worked like how eval(input()) works in Python 3.x. RE: Python - Website Recon Tool - Dyme - 09-28-2014 (09-28-2014, 10:06 PM).Shebang Wrote: Presumably he's using Python 3.x+. raw_input() became input(). Oi, then forget everything I posted. Didn't know people actually used python 3 lol... RE: Python - Website Recon Tool - Shebang - 09-28-2014 (09-28-2014, 10:14 PM)Dyme Wrote: Oi, then forget everything I posted. Didn't know people actually used python 3 lol... I was forced to for school. Kinda sucked, a lot of stuff isn't compatible. RE: Python - Website Recon Tool - Reiko - 09-29-2014 What is the difference with your tool and using curl?? RE: Python - Website Recon Tool - Eclipse - 09-29-2014 (09-28-2014, 09:44 PM)Adorapuff Wrote: You should check if http is included in the string instead of telling people how they should input the string. Otherwise good job. I'm lazy, but I'll add that. (09-28-2014, 09:50 PM)Dyme Wrote: lol what happened to raw_input()? That's Python2, this is Py3. (09-29-2014, 04:30 AM)Reiko Wrote: What is the difference with your tool and using curl?? Nothing much really, it just simplifies it into one Py script. |