Add Host Duplication Detection

This commit is contained in:
Narbeh 2018-04-18 16:39:40 +04:30
parent 6a14ff3796
commit 9d471bdd76

View File

@ -84,6 +84,11 @@ def show_result(hosts):
print('Analyzing {} hosts:\n'.format(len(hosts))) print('Analyzing {} hosts:\n'.format(len(hosts)))
for host in hosts: for host in hosts:
host, port = filter_hostname(host) host, port = filter_hostname(host)
# Check duplication
if host in context.keys():
continue
cert = get_cert(host, port) cert = get_cert(host, port)
if cert: if cert:
context[host] = get_cert_info(cert) context[host] = get_cert_info(cert)