internal

package
v0.0.0-...-c098392 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 15, 2021 License: MIT Imports: 10 Imported by: 0

Documentation

Index

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 CredentialTypeFromJSON(credentialJSON []byte) (string, error)

func InferADCCredentialType

func InferADCCredentialType(cred *google.Credentials) (string, error)

func ParseDelegateChain

func ParseDelegateChain(s string) (targetPrincipal string, delegates []string)

ParseDelegateChain split impersonate target principal and delegate chain. s must be non-empty string.

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL