PTZ/profile_files/.zsh/agro_detection_parser.py

11 lines
319 B
Python
Raw Normal View History

2017-01-12 19:41:16 +00:00
#!/usr/bin/python2.7
with open('2_ports_and_service_top1000_on_alive_hosts.out') as f:
curip=""
for curline in f:
if "Nmap scan report for " in curline:
curip=curline
curip=curip[21:]
if "open" in curline:
print curip.strip('\n') + " " + curline.strip('\n')