mxrch / GHunt

🕵️‍♂️ Offensive Google framework.
Other
15.65k stars 1.3k forks source link

is 'ghunt.py doc' not working anymore? #360

Closed Donaid closed 1 year ago

Donaid commented 2 years ago

Describe the bug Everything is working except the document function. The email function working well, but the doc part gives an error. I tried with several google document links, but the results are all the same.

Traceback (most recent call last): File "ghunt.py", line 40, in doc_hunt(data) File "C:\Users\k\ghunt\modules\doc.py", line 78, in doc_hunt created_date = datetime.strptime(data["createdDate"], '%Y-%m-%dT%H:%M:%S.%fz') KeyError: 'createdDate'

Screenshots

Screenshot_9 download

00-Python commented 2 years ago

Any luck solving this? i have the same error.

hugobiais commented 2 years ago

same error here as well.

dbechrd commented 2 years ago

This is the real error if you inspect the response (at least in my case, I used GHunt companion in server mode to generate the token):

{
  "error": {
    "errors": [
      {
        "domain": "global",
        "reason": "required",
        "message": "Authentication token must be issued to a non-anonymous app.",
        "locationType": "header",
        "location": "authorization"
      }
    ],
    "code": 400,
    "message": "Authentication token must be issued to a non-anonymous app."
  }
}
Huderon commented 2 years ago

It's not a clean solution but if you follow along with this you can generate a new api key linked to a google cloud project, once you've got that you've just got to add google drive service to that project and it should work.

haroldKryptus commented 2 years ago

Same error here, didnt understand how to use a google project on ghunt

Huderon commented 2 years ago

Same error here, didnt understand how to use a google project on ghunt

Once you've got the API key for the project go to the data file in ./resources and replace the "internal" key with the new API key