Configuring a remote with google drive fails: no client secret copied from browser

What is the problem you are having with rclone?

Configuring a remote for google drive finishes successfully, but no client secret is copied. The client secret stays empty. No file like "oauth-project-.json" is copied or created. Nor used. This seems a problem with modern browsers. I've tried Vivaldi, Chrome, Firefox. Got all times the same: no access. Google Drive is shown empty. No files found.

With an other, older config (configured to access Google Drive config only) it works. But the config is different here:

type = drive
client_id = <id>
scope = drive
root_folder_id = <root-folder-id>
service_account_file = ${HOME}/.config/rclone/oauth-project-<id>.json

Run the command 'rclone version' and share the full output of the command.

rclone v1.64.0

  • os/version: ubuntu 23.04 (64 bit)
  • os/kernel: 6.2.0-33-generic (x86_64)
  • os/type: linux
  • os/arch: amd64
  • go/version: go1.21.1
  • go/linking: static
  • go/tags: none

Which cloud storage system are you using? (eg Google Drive)

Google Drive

The command you were trying to run (eg rclone copy /tmp remote:tmp)

The rclone config contents with secrets removed.

type = drive
client_id = <removed>
scope = drive
acknowledge_abuse = true

A log from the command with the -vv flag

There is of course some chance that you discovered a new bug but otherwise google drive configuration works without any issues with all latest browsers I use.

If you post step by step what you are doing it can help to diagnose the issue. It is impossible to guess details from your description.

as far as i know, rclone does not create service files, that is done at the gdrive website.
well, that is the way i have always done it.

as of last week, latest firefox works fine with gdrive oauth.

If you are using a service account, they have their own client ID/secret so if you are using a service account, you should leave both fields blank anyway.

Yes, this was the solution. You can use the cient_id and client_secret OR service_account_file, but not both. Even having the client_id and service_account_file defined does not good with 1.64.0, while it works with 1.63.1.

This is poorly documented.

Good opportunity to improve it then. Would be great if you could make required clarifications in docs.

You can edit it directly in github and submit PR:

If you want to make changes in flags descriptions edit:

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.