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

Fix #478. #479

Merged
merged 1 commit into from
Feb 9, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 12 additions & 12 deletions protocols/profiles/google_client_id.md
Original file line number Diff line number Diff line change
@@ -1,22 +1,16 @@
Custom OAuth 2.0 Client ID for Google Cloud Storage and Google Drive
====

> To use OAuth 2.0 in your application, you need an OAuth 2.0 client ID, which your application uses when requesting an OAuth 2.0 access token.

## Verification Issue

Login using OAuth is currently failing with the default OAuth Client ID application registration in Cyberduck. When attempting to allow access for Cyberduck to Google Drive, the following error is displayed.

```{error}
Sign in with Google temporarily disabled for this app. This app has not been verified yet by Google in order to use Google Sign In.
```
Instructions to register a custom OAuth 2.0 Client ID in the [Google Cloud Console](https://console.cloud.google.com/apis/credentials). to connect to [Google Drive](../googledrive.md). For [Google Storage](../googlecloudstorage.md).

As a workaround, you can register your own OAuth Client ID to connect to [Google Drive](../googledrive.md). For [Google Storage](../googlecloudstorage.md) you can use [Interoperable Access](../googlecloudstorage.md#interoperable-access) as a workaround.
> To use OAuth 2.0 in your application, you need an OAuth 2.0 client ID, which your application uses when requesting an OAuth 2.0 access token.

## Register Client ID

Follow the steps in [Setting up OAuth 2.0](https://support.google.com/googleapi/answer/6158849?hl=en). From Credentials copy the client ID and client secret by choosing the action Edit OAuth client.

* Choose _Desktop app_ as the _Application type_ which will result in a Client ID with a suffix like `number-id.apps.googleusercontent.com`.

```{image} _images/Google_Create_OAuth_Client_ID.png
:alt: Google Create OAuth Client ID
:width: 600px
Expand All @@ -26,14 +20,20 @@ Follow the steps in [Setting up OAuth 2.0](https://support.google.com/googleapi/
:width: 600px
```

*Edit the OAuth Consent Screen* to add the scopes *Google Cloud Storage JSON API* `../auth/devstorage.read_write` and/or *Google Drive API* `../auth/drive`. You will first need to enable *Google Drive* in the Google API Library.
* Edit the OAuth Consent Screen* to add the scopes *Google Cloud Storage JSON API* `../auth/devstorage.read_write` and/or *Google Drive API* `../auth/drive`. You will first need to enable *Google Drive* in the Google API Library.

## Edit Custom Connection Profile

Create a custom [connection profile](index.md) with the following properties.

- `OAuth Client ID`. Override the registered application client id.
- `OAuth Client Secret`. Override the registered application client secret.
- `OAuth Client Secret`. Optional. Override the registered application client secret.
- `OAuth Redirect Url`. Use the reverse notation of the client id and set it like

```
<key>OAuth Redirect Url</key>
<string>com.googleusercontent.apps.number-id:oauth</string>
```

### Sample Google Drive with Custom OAuth Client ID Connection Profile

Expand Down
Loading