【发布时间】:2021-07-28 11:27:07
【问题描述】:
我有一个 cidr 符号列表,我有一个 python 程序,它从 cidr 符号生成一个 ip 地址列表。这是程序
from netaddr import IPNetwork
for ip in IPNetwork('104.24.0.0/6'):
print ('%s' % ip)
但我想让程序循环遍历每个 ip 地址并发送 http 请求,然后搜索一些特定的状态码,如果找到所需的状态码,它应该返回哪个 ip 地址具有该状态码
【问题讨论】:
-
你有什么问题?到目前为止,您尝试过什么?
标签: python python-3.x networking http-headers http-status-codes