4
votes

I'm totally new to Google Cloud Storage (GCS).

Here is my scenario.

I create a GCS for my app users to upload their media files. All the users can upload to GCS without login Google account but required an authenticated user from my app. And the upload via client browser to GCS (no server code).

After reading the documents, the authentication part confusing me.

  1. OAuth 2.0 Authentication (Required Google account)
  2. Cookie-based Authentication (Required Google account)
  3. Using Service Accounts for Authentication

Can someone explain number 2 and 3 to me? especially number 3 because it then bring me to

Signed url, browser upload using post, oauth2.0 for server to server application.

Which cause me no idea how to start.

Thanks

1

1 Answers

5
votes

You can use Signed URLs for your use case.

Depending on your use case, you can generate and display a link to a signed URL on your dynamic website, or you can provide a download link that goes through your app, sending a 302 redirect to the signed URL after authenticating the user.