Simple Port Finder Program Using Python
#Belgin Android
import socket
def port(hostname):
s=socket.socket(socket.AF_INET,socket.SOCK_STREAM)
try:
for i in range(225):
res=s.connect_ex((hostname,i))
if res==0:
print("Port is open At {} ".format(i))
else:
pass
except socket.error:
print("Could Not Resolve Host Name")
port(input("Enter The Host Name -- > "))
Comments
Post a Comment