Skip to content

Commit e894eff

Browse files
docs: explain unused audience in GCP ADC strategy
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
1 parent c931998 commit e894eff

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

  • cloudsmith_cli/core/credentials/oidc/detectors

cloudsmith_cli/core/credentials/oidc/detectors/gcp.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -127,6 +127,9 @@ def _token_from_service_account_file(self, audience: str) -> str | None:
127127
return None
128128

129129
def _token_from_adc(self, audience: str) -> str | None:
130+
# audience is unused here: ADC user credentials mint an id_token whose
131+
# aud is gcloud's OAuth client id, not a custom audience. The signature
132+
# stays uniform so get_token can call every strategy as strategy(audience).
130133
try:
131134
import google.auth # pylint: disable=import-error
132135
from google.auth.transport.requests import ( # pylint: disable=import-error

0 commit comments

Comments
 (0)