我正在编写一个python脚本,它基本上扫描IP地址上的端口,我使用libnmap
库来完成这项工作,并参考了位于https://libnmap.readthedocs.org/en/latest/process.html#purpose-of-libnmap-process的文档
我希望读取一个包含要扫描的IP地址列表的外部文件,并将每个IP地址传递为:
file_object = open(file_containg_ip_to_be_port_scanned, r)
if __name__ == "__main__":
report = do_scan("pass_ip_here", "-sV")
if report:
print_scan(report)
我怎样才能做到这一点?在
看起来你想要这样的东西:
相关问题 更多 >
编程相关推荐