0

I'm trying to get the Cyberduck CLI (duck.sh) to work interfacing with a google drive (not "Google Cloud Storage") and I'm having problems getting the oAuth authorization to work. I found this thread but it's out of date - as the newer versions of Cyberduck do absolutely work with Google Drive. Using the regular cyberduck GUI I can browse and operate on my G-drive instance, but I can't quite quack the code (sorry!) for how to make this work using the CLI.

[lwobker:~]$ duck -l googledrive://<user>@gmail.com/                   
Authenticating as <user>…
OAuth2 Authentication. Paste the authentication code from your web browser.
Authentication Code: <pasted pass here>

Save password (y/n): n
Disconnecting www.googleapis.com…
Login failed. Malformed auth code. Please contact your web hosting service provider for assistance.

I've tried a number of different URLs, including: @gmail.com me@gmail.com@www.googleapis.com and a couple of others.

I also can't seem to figure out where the GUI version of cyberduck stores it's authorized credentials... if I could re-use those that would be fine, doing a one-time setup at the beginning doesn't break my use case.

I'm somewhat familiar with the Google Developers API, and I've created one for use with this project, but I can't seem to figure out how the Google "Client ID" and other credentials map to the Cyberduck tool.

pinoyyid
  • 21,499
  • 14
  • 64
  • 115
ljwobker
  • 832
  • 2
  • 10
  • 20
  • this might help https://stackoverflow.com/questions/19766912/how-do-i-authorise-an-app-web-or-installed-without-user-intervention/19766913#19766913 In response to "Authentication code" you say "pasted pass(word)" which of course is not an Authentication code – pinoyyid Nov 06 '18 at 22:06
  • Cyberduck saves passwords in the login keychain (macOS) or the credential manager (Windows). You will find OAuth Tokens saved as `Google Drive (@gmail.com) OAuth2 Access Token` – David Kocher Nov 15 '18 at 18:49
  • You will *not* need to register your own client in the Google API developer console. – David Kocher Nov 15 '18 at 18:50

1 Answers1

0

Make sure you paste the auth code obtained from the Google login page opened exactly as is without any line breaks. More information is available in the wiki.

David Kocher
  • 632
  • 4
  • 8