labbots / google-drive-upload

Bash scripts to upload files to google drive
https://labbots.github.io/google-drive-upload/
MIT License
698 stars 145 forks source link

Unable to authenticate (v4.4) #188

Closed manzolo closed 2 years ago

manzolo commented 2 years ago

I tried to run the gupload command, and after finishing the configuration I get the error Error: Cannot fetch refresh token, make sure the authorization code was correct.


Enter Client ID

-> [MY_CLIENT_ID].apps.googleusercontent.com


Enter Client SECRET

-> [MY_CLIENT_SECRET]

If you have a refresh token generated, then type the token, else leave blank and press return key..


Refresh Token

->


No Refresh token given, follow below steps to generate..

Visit the below URL, follow the instructions and then come back to commandline

https://accounts.google.com/o/oauth2/auth?client_id=[MY_CLIENT_ID].apps.googleusercontent.com&redirect_uri=http%3A//localhost%3A8080&scope=https://www.googleapis.com/auth/drive&response_type=code&code_challenge_method=plain&code_challenge=99999999authorization_code


Press enter if you have completed the process in browser

Error: Cannot fetch refresh token, make sure the authorization code was correct.

immagine

Roei639 commented 2 years ago

I'm unable to access authentication through localhost

Akianonymus commented 2 years ago

Will be fixed after the PR is merged. Until it is merged, can use this for now https://github.com/Akianonymus/google-drive-upload/raw/master/release/bash/gupload

Roei639 commented 2 years ago

When trying to access the link, an error is received:

This site cannot be accessed

Could not connect to localhost.

You should try:

check the connection

ERR_CONNECTION_REFUSED

Akianonymus commented 2 years ago

@Roei639 You should create another issue with logs.

manzolo commented 2 years ago

Will be fixed after the PR is merged. Until it is merged, can use this for now https://github.com/Akianonymus/google-drive-upload/raw/master/release/bash/gupload

It works perfectly