常用服务对应的正则

        socket.setdefaulttimeout(timeout/2)
        sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
        sock.connect((str(host),int(port)))
        data = sock.recv(512)
        sock.close()

 

 

ftp|21|^220.*?ftp|^220-
ssh|22|^ssh-
telnet|23|^\xff[\xfa-\xfe]|^\x54\x65\x6c
smtp|25|^220.*?smtp
dns|53|
pop3|110|\+OK.*?pop3
NetBIOS|139|
imap|143|^\* OK.*?imap
ldap|389|
smb|445|
smtps|465|
rsync|873|^@RSYNCD|^@ERROR
imaps|993|
pop3|995|\+OK
proxy|1080|
pptp|1723|
mssql|1433|
oracle|1521|
mysql|3306|^.\0\0\0.*?mysql|^.\0\0\0\n|.*?MariaDB server
rdp|3389|
svn|3690|
PostgreSql|5432|
vnc|5800|^RFB
vnc|5900|^RFB
redis|6379|-ERR|^\$\d+\r\nredis_version
Elasticsearch|9200|
Elasticsearch|9300|
memcached|11211|
mongodb|27017|
mongodb|27018|

posted on 2016-04-14 22:25  lly001  阅读(186)  评论(0编辑  收藏  举报

导航