Trying to get the Google Safebrowsing python script to work. https://github.com/Cisco-Talos/clamav-safebrowsing
It worked yesterday and downloaded the file, filled the database and created the gdb file. But since then I get:
sudo /usr/local/Cellar/python@3.9/3.9.2_4/bin/python3.9 ./clamsbsync.py --logfile /private/var/log/clamav_safebrowsing.log --debug
Password:
Traceback (most recent call last):
File "/Users/me/Downloads/clamav-safebrowsing-master/./clamsbsync.py", line 599, in
client.Sync()
File "/Users/me/Downloads/clamav-safebrowsing-master/./clamsbsync.py", line 464, in Sync
updates = self.Update(lists=lists)
File "/Users/me/Downloads/clamav-safebrowsing-master/./clamsbsync.py", line 340, in Update
return self._retrieve_updates(listobjs)
File "/Users/me/Downloads/clamav-safebrowsing-master/./clamsbsync.py", line 83, in _retrieve_updates
gapi_resp = self.gapi.get_threats_update(listobjs)
File "/Users/me/Downloads/clamav-safebrowsing-master/clamsb/googleapi.py", line 38, in get_threats_update
response = self._service.threatListUpdates().fetch(body=request_body).execute()
File "/usr/local/lib/python3.9/site-packages/googleapiclient/_helpers.py", line 134, in positional_wrapper
return wrapped(*args, **kwargs)
File "/usr/local/lib/python3.9/site-packages/googleapiclient/http.py", line 920, in execute
resp, content = _retry_request(
File "/usr/local/lib/python3.9/site-packages/googleapiclient/http.py", line 222, in _retry_request
raise exception
File "/usr/local/lib/python3.9/site-packages/googleapiclient/http.py", line 191, in _retry_request
resp, content = http.request(uri, method, *args, **kwargs)
File "/usr/local/lib/python3.9/site-packages/httplib2/init.py", line 1708, in request
(response, content) = self._request(
File "/usr/local/lib/python3.9/site-packages/httplib2/init.py", line 1424, in _request
(response, content) = self._conn_request(conn, request_uri, method, body, headers)
File "/usr/local/lib/python3.9/site-packages/httplib2/init.py", line 1346, in _conn_request
conn.connect()
File "/usr/local/lib/python3.9/site-packages/httplib2/init.py", line 1136, in connect
sock.connect((self.host, self.port))
socket.timeout: timed out
The log just shows:
2021-04-08 14:33:46,500 INFO:root:Running update.py CLI
2021-04-08 14:33:46,537 DEBUG:UpdateClient:retrieving threats updates...
2021-04-08 14:33:46,538 DEBUG:UpdateClient:retrieved MALWARE.URL.ALL_PLATFORMS @ Cg8IARAWTAEiAzAwMTABEMiJCRoQGAwrTbix
2021-04-08 14:33:46,538 DEBUG:UpdateClient:retrieved SOCIAL_ENGINEERING.URL.ALL_PLATFORMS @ Cg0IAhARRAEiAzAwMTABEJXiCxoCGAwP9SNj
2021-04-08 14:33:46,539 DEBUG:googleapiclient.discovery:URL being requested: POST https://safebrowsing.googleapis.com/v4/threatListUpdates:fetch?key=AIwzaSyTheRestOfMyKeyc&alt=json <https://safebrowsing.googleapis.com/v4/threatListUpdates:fetch?key=AIwzaSyTheRestOfMyKeyc&alt=json>
Can anyone help me with this?
I posted on the Issues page in GitHub but got no reply.
Any help would be much appreciated.
Thanks,
James.
It worked yesterday and downloaded the file, filled the database and created the gdb file. But since then I get:
sudo /usr/local/Cellar/python@3.9/3.9.2_4/bin/python3.9 ./clamsbsync.py --logfile /private/var/log/clamav_safebrowsing.log --debug
Password:
Traceback (most recent call last):
File "/Users/me/Downloads/clamav-safebrowsing-master/./clamsbsync.py", line 599, in
client.Sync()
File "/Users/me/Downloads/clamav-safebrowsing-master/./clamsbsync.py", line 464, in Sync
updates = self.Update(lists=lists)
File "/Users/me/Downloads/clamav-safebrowsing-master/./clamsbsync.py", line 340, in Update
return self._retrieve_updates(listobjs)
File "/Users/me/Downloads/clamav-safebrowsing-master/./clamsbsync.py", line 83, in _retrieve_updates
gapi_resp = self.gapi.get_threats_update(listobjs)
File "/Users/me/Downloads/clamav-safebrowsing-master/clamsb/googleapi.py", line 38, in get_threats_update
response = self._service.threatListUpdates().fetch(body=request_body).execute()
File "/usr/local/lib/python3.9/site-packages/googleapiclient/_helpers.py", line 134, in positional_wrapper
return wrapped(*args, **kwargs)
File "/usr/local/lib/python3.9/site-packages/googleapiclient/http.py", line 920, in execute
resp, content = _retry_request(
File "/usr/local/lib/python3.9/site-packages/googleapiclient/http.py", line 222, in _retry_request
raise exception
File "/usr/local/lib/python3.9/site-packages/googleapiclient/http.py", line 191, in _retry_request
resp, content = http.request(uri, method, *args, **kwargs)
File "/usr/local/lib/python3.9/site-packages/httplib2/init.py", line 1708, in request
(response, content) = self._request(
File "/usr/local/lib/python3.9/site-packages/httplib2/init.py", line 1424, in _request
(response, content) = self._conn_request(conn, request_uri, method, body, headers)
File "/usr/local/lib/python3.9/site-packages/httplib2/init.py", line 1346, in _conn_request
conn.connect()
File "/usr/local/lib/python3.9/site-packages/httplib2/init.py", line 1136, in connect
sock.connect((self.host, self.port))
socket.timeout: timed out
The log just shows:
2021-04-08 14:33:46,500 INFO:root:Running update.py CLI
2021-04-08 14:33:46,537 DEBUG:UpdateClient:retrieving threats updates...
2021-04-08 14:33:46,538 DEBUG:UpdateClient:retrieved MALWARE.URL.ALL_PLATFORMS @ Cg8IARAWTAEiAzAwMTABEMiJCRoQGAwrTbix
2021-04-08 14:33:46,538 DEBUG:UpdateClient:retrieved SOCIAL_ENGINEERING.URL.ALL_PLATFORMS @ Cg0IAhARRAEiAzAwMTABEJXiCxoCGAwP9SNj
2021-04-08 14:33:46,539 DEBUG:googleapiclient.discovery:URL being requested: POST https://safebrowsing.googleapis.com/v4/threatListUpdates:fetch?key=AIwzaSyTheRestOfMyKeyc&alt=json <https://safebrowsing.googleapis.com/v4/threatListUpdates:fetch?key=AIwzaSyTheRestOfMyKeyc&alt=json>
Can anyone help me with this?
I posted on the Issues page in GitHub but got no reply.
Any help would be much appreciated.
Thanks,
James.