oxidecomputer / oxidecomputer/third-party-api-clients

Google Drive: Changing client subject

Open
#87 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Rust
Stars
150
Forks
62
PR merge metrics
No merged PRs in 30d

Description

Hey folks! I'm using a service account as auth for a backend service. As a part of this, I need to assume the identity of another user. The Python equivalent of this w/ the official sdk is:

# Load Google Drive service account credentials
sa_json = json.loads(os.getenv("GOOGLE_SERVICE_ACCOUNT_JSON"))
_c = service_account.Credentials.from_service_account_info(
    sa_json,
    scopes=["https://www.googleapis.com/auth/drive"],
)
google_creds = _c.with_subject("another_email@service.com")

Wondering if you guys have thoughts on achieving something similar w/ the library

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

The issue names no repository files or tests. Start by locating the Google Drive client and its service-account credential setup, then compare it with the Python with_subject example; done means the client can make requests while assuming another user's identity.

Written by the indexing model from the issue text.

Assessment

Tech stack
google-cloud, rust
Domain
api, cloud
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.