Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

请问以下问题是因为google API key 的问题吗? #49

Open
ramontest opened this issue May 20, 2020 · 3 comments
Open

请问以下问题是因为google API key 的问题吗? #49

ramontest opened this issue May 20, 2020 · 3 comments

Comments

@ramontest
Copy link

[*] Activate Google API
Traceback (most recent call last):
File "/home/tools/expliot/POC-T-2.0/lib/cli.py", line 45, in main
loadPayloads()
File "/home/tools/expliot/POC-T-2.0/lib/controller/loader.py", line 49, in loadPayloads
api_mode()
File "/home/tools/expliot/POC-T-2.0/lib/controller/loader.py", line 88, in api_mode
file = runApi()
File "/home/tools/expliot/POC-T-2.0/lib/controller/api.py", line 27, in runApi
anslist = GoogleSearch(query=dork, limit=limit, offset=conf.API_OFFSET)
File "/home/tools/expliot/POC-T-2.0/lib/api/google/pack.py", line 60, in GoogleSearch
service = build("customsearch", "v1", http=_initHttpClient(), developerKey=key)
File "/usr/local/lib/python2.7/dist-packages/googleapiclient/_helpers.py", line 134, in positional_wrapper
return wrapped(*args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/googleapiclient/discovery.py", line 225, in build
requested_url, discovery_http, cache_discovery, cache, developerKey
File "/usr/local/lib/python2.7/dist-packages/googleapiclient/discovery.py", line 282, in _retrieve_discovery_doc
resp, content = http.request(actual_url)
File "/home/tools/expliot/POC-T-2.0/thirdparty/httplib2/init.py", line 1609, in request
(response, content) = self._request(conn, authority, uri, request_uri, method, body, headers, redirections, cachekey)
File "/home/tools/expliot/POC-T-2.0/thirdparty/httplib2/init.py", line 1351, in _request
(response, content) = self._conn_request(conn, request_uri, method, body, headers)
File "/home/tools/expliot/POC-T-2.0/thirdparty/httplib2/init.py", line 1272, in _conn_request
conn.connect()
File "/home/tools/expliot/POC-T-2.0/thirdparty/httplib2/init.py", line 1059, in connect
raise SSLHandshakeError(e)
SSLHandshakeError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:727)

[!] It seems like you reached a unhandled exception, please report it to author's mail:[email protected] or raise a issue via:https://github.com/Xyntax/POC-T/issues/new.

@kiang70
Copy link

kiang70 commented May 20, 2020

是!

@ramontest
Copy link
Author

真心不知道怎么申请了,我已经有了一个key但是还是报错。有相关文档吗?大侠。

@ramontest
Copy link
Author

经过排查验证发现是你代码的问题,哈哈。。。
/home/tools/expliot/POC-T-2.0/lib/api/google/pack.py

service = build("customsearch", "v1", http=_initHttpClient(), developerKey=key) 这行代码中http 这个参数需要去掉即可解决问题。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants