googleapis / googleapis/google-cloud-rust

Inject environment variables when calling executable to fetch subject token

Open
#2,496 0 comments 0 reactions 0 assignees View on GitHub
priority: p2 type: feature request
Dominant language
Rust
Stars
955
Forks
144
Avg merge
1d 5h
Merged PRs (30d)
279

Description

Per [AIP-4117](https://google.aip.dev/auth/4117#determining-the-subject-token-in-executable-sourced-credentials), some environment variables with extra information about the external account, needs to be injected and made available to the program.

```
Ensure the following environment variables will be available to the executable:
GOOGLE_EXTERNAL_ACCOUNT_AUDIENCE: The audience field from the credential configuration. Must always be present.
GOOGLE_EXTERNAL_ACCOUNT_TOKEN_TYPE: The subject token type. Must always be present.
GOOGLE_EXTERNAL_ACCOUNT_IMPERSONATED_EMAIL: The service account email. Only present when service account impersonation is used.
GOOGLE_EXTERNAL_ACCOUNT_OUTPUT_FILE: The output file location from the credential configuration. Only present when specified in the credential configuration.
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.