我使用python中的owasp zap模块创建了一个脚本来执行爬行器扫描。但是,启动脚本时,我会出现以下错误:
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/urllib3/connectionpool.py", line 670, in urlopen
httplib_response = self._make_request(
File "/usr/lib/python3/dist-packages/urllib3/connectionpool.py", line 426, in _`enter code here`make_request
six.raise_from(e, None)
File "<string>", line 3, in raise_from
File "/usr/lib/python3/dist-packages/urllib3/connectionpool.py", line 421, in _make_request
httplib_response = conn.getresponse()
File "/usr/lib/python3.9/http/client.py", line 1347, in getresponse
response.begin()
File "/usr/lib/python3.9/http/client.py", line 307, in begin
version, status, reason = self._read_status()
File "/usr/lib/python3.9/http/client.py", line 276, in _read_status
raise RemoteDisconnected("Remote end closed connection without"
http.client.RemoteDisconnected: Remote end closed connection without response
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/requests/adapters.py", line 439, in send
resp = conn.urlopen(
File "/usr/lib/python3/dist-packages/urllib3/connectionpool.py", line 724, in urlopen
retries = retries.increment(
File "/usr/lib/python3/dist-packages/urllib3/util/retry.py", line 439, in increment
raise MaxRetryError(_pool, url, error or ResponseError(cause))
urllib3.exceptions.MaxRetryError: HTTPConnectionPool(host='127.0.0.1', port=8080): Max retries exceeded with url: http://zap/JSON/spider/action/scan/?apikey=&url=http%3A%2F%2F10.0.2.23 (Caused by ProxyError('Cannot connect to proxy.', RemoteDisconnected('Remote end closed connection without response')))
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/kali/Desktop/vuln_discovery/main.py", line 27, in <module>
spider_scan(url)
File "/home/kali/Desktop/vuln_discovery/zap.py", line 12, in spider_scan
zap.spider.scan(url=url)
File "/home/kali/.local/lib/python3.9/site-packages/zapv2/spider.py", line 215, in scan
return six.next(six.itervalues(self.zap._request(self.zap.base + 'spider/action/scan/', params)))
File "/home/kali/.local/lib/python3.9/site-packages/zapv2/__init__.py", line 192, in _request
data = self._request_api(url, get)
File "/home/kali/.local/lib/python3.9/site-packages/zapv2/__init__.py", line 172, in _request_api
response = self.session.get(url, params=query, proxies=self.__proxies, verify=False)
File "/usr/lib/python3/dist-packages/requests/sessions.py", line 543, in get
return self.request('GET', url, **kwargs)
File "/usr/lib/python3/dist-packages/requests/sessions.py", line 530, in request
resp = self.send(prep, **send_kwargs)
File "/usr/lib/python3/dist-packages/requests/sessions.py", line 643, in send
r = adapter.send(request, **kwargs)
File "/usr/lib/python3/dist-packages/requests/adapters.py", line 510, in send
raise ProxyError(e, request=request)
enter code here
requests.exceptions.ProxyError: HTTPConnectionPool(host='127.0.0.1', port=8080): Max retries exceeded with url: http://zap/JSON/spider/action/scan/?apikey=&url=http%3A%2F%2F10.0.2.23 (Caused by ProxyError('Cannot connect to proxy.', RemoteDisconnected('Remote end closed connection without response')))`
目前没有回答
相关问题 更多 >
编程相关推荐