#coding:utf8
import socket,time,re,thread,os
timeout=3
socket.setdefaulttimeout(timeout)
def socket_port...(ip,port):
s=socket.socket(socket.AF_INET,socket.SOCK_STREAM)
result=s.connect_ex((ip,port))... if result==0:
lock.acquire()
print '%s'%ip+',%s端口通过'%port+'\n'
lock.release...()
s.close()
else:
print '%s'%ip+',%s端口异常'%port+'\n'
def ip_scan(ip):
print""..."
*****************************************
端口号为 21,22,23,3389,1521,3940
***********