Documentation ¶
Index ¶
- Constants
- func CalcAdcPlusConfig(opts ...adcplus.Option) (*config.AdcPlusConfig, error)
- func CredentialTypeFromJSON(credentialJSON []byte) (string, error)
- func InferADCCredentialType(cred *google.Credentials) (string, error)
- func ParseDelegateChain(s string) (targetPrincipal string, delegates []string)
Constants ¶
View Source
const ( ServiceAccountKey = "service_account" UserCredentialsKey = "authorized_user" ExternalAccountKey = "external_account" ComputeMetadataCredential = "compute_metadata" )
All patterns are defined in https://github.com/golang/oauth2/blob/f6687ab2804cbebdfdeef385bee94918b1ce83de/google/google.go#L93-L98
Variables ¶
This section is empty.
Functions ¶
func CalcAdcPlusConfig ¶
func CalcAdcPlusConfig(opts ...adcplus.Option) (*config.AdcPlusConfig, error)
* Apply opts * Detect misconfigurations. * Populate AdcPlusConfig.TargetPrincipal and AdcPlusConfig.Delegates from `CLOUDSDK_AUTH_IMPERSONATE_SERVICE_ACCOUNT` environment variable. * Populate AdcPlusConfig.CredentialsJSON from AdcPlusConfig.CredentialsFile.
func CredentialTypeFromJSON ¶
func InferADCCredentialType ¶
func InferADCCredentialType(cred *google.Credentials) (string, error)
func ParseDelegateChain ¶
ParseDelegateChain split impersonate target principal and delegate chain. s must be non-empty string.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.