You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
with open(masscan_file, 'r') as fr:
tmp_lines = fr.readlines()
lines = tmp_lines[1:-1]
global total_ports
total_ports = len(lines)
lines = lines[::2]
lines2 = []
for i, item in enumerate(lines):
processed_item = item.replace("\n", "")
lines2.append(processed_item)
for line in lines2:
line_json = json.loads(line)
# print(line_json)
# extract ip & port
ip = line_json['ip']
port = line_json['ports'][0]['port']
# combine ip:port, and add to queue
ip_port = '{}:{}'.format(ip, port)
task_queue.put(ip_port)
print(ip_port+'\n')
# exit()
pass
The text was updated successfully, but these errors were encountered:
with open(masscan_file, 'r') as fr:
tmp_lines = fr.readlines()
lines = tmp_lines[1:-1]
global total_ports
total_ports = len(lines)
lines = lines[::2]
lines2 = []
for i, item in enumerate(lines):
processed_item = item.replace("\n", "")
lines2.append(processed_item)
for line in lines2:
line_json = json.loads(line)
# print(line_json)
# extract ip & port
ip = line_json['ip']
port = line_json['ports'][0]['port']
# combine ip:port, and add to queue
ip_port = '{}:{}'.format(ip, port)
task_queue.put(ip_port)
print(ip_port+'\n')
# exit()
pass
The text was updated successfully, but these errors were encountered: