Documentation ¶
Index ¶
- Constants
- Variables
- type Credentials
- func (s *Credentials) IsDerivedAuth(httpRequest *request.DefaultHttpRequest) bool
- func (s *Credentials) ProcessAuthParams(client *impl.DefaultHttpClient, region string) auth.ICredential
- func (s *Credentials) ProcessAuthRequest(client *impl.DefaultHttpClient, req *request.DefaultHttpRequest) (*request.DefaultHttpRequest, error)
- func (s *Credentials) ProcessDerivedAuthParams(derivedAuthServiceName, regionId string) auth.ICredential
- func (s *Credentials) UpdateSecurityTokenFromMetadata() error
- type CredentialsBuilder
- func (builder *CredentialsBuilder) Build() *Credentialsdeprecated
- func (builder *CredentialsBuilder) SafeBuild() (*Credentials, error)
- func (builder *CredentialsBuilder) WithAk(ak string) *CredentialsBuilder
- func (builder *CredentialsBuilder) WithDerivedPredicate(derivedPredicate func(*request.DefaultHttpRequest) bool) *CredentialsBuilder
- func (builder *CredentialsBuilder) WithDomainId(domainId string) *CredentialsBuilder
- func (builder *CredentialsBuilder) WithIamEndpointOverride(endpoint string) *CredentialsBuilder
- func (builder *CredentialsBuilder) WithIdTokenFile(idTokenFile string) *CredentialsBuilder
- func (builder *CredentialsBuilder) WithIdpId(idpId string) *CredentialsBuilder
- func (builder *CredentialsBuilder) WithSecurityToken(token string) *CredentialsBuilder
- func (builder *CredentialsBuilder) WithSk(sk string) *CredentialsBuilder
Constants ¶
View Source
const ( DomainIdInHeader = "X-Domain-Id" SecurityTokenInHeader = "X-Security-Token" GlobalRegionId = "globe" AuthTokenInHeader = "X-Auth-Token" )
Variables ¶
View Source
var DefaultDerivedPredicate = auth.GetDefaultDerivedPredicate()
Functions ¶
This section is empty.
Types ¶
type Credentials ¶
type Credentials struct { IamEndpoint string AK string SK string DomainId string SecurityToken string IdpId string IdTokenFile string DerivedPredicate func(*request.DefaultHttpRequest) bool // contains filtered or unexported fields }
func (*Credentials) IsDerivedAuth ¶ added in v0.0.79
func (s *Credentials) IsDerivedAuth(httpRequest *request.DefaultHttpRequest) bool
func (*Credentials) ProcessAuthParams ¶
func (s *Credentials) ProcessAuthParams(client *impl.DefaultHttpClient, region string) auth.ICredential
ProcessAuthParams This function may panic under certain circumstances.
func (*Credentials) ProcessAuthRequest ¶
func (s *Credentials) ProcessAuthRequest(client *impl.DefaultHttpClient, req *request.DefaultHttpRequest) (*request.DefaultHttpRequest, error)
func (*Credentials) ProcessDerivedAuthParams ¶ added in v0.0.79
func (s *Credentials) ProcessDerivedAuthParams(derivedAuthServiceName, regionId string) auth.ICredential
func (*Credentials) UpdateSecurityTokenFromMetadata ¶ added in v0.0.96
func (s *Credentials) UpdateSecurityTokenFromMetadata() error
type CredentialsBuilder ¶
type CredentialsBuilder struct { Credentials *Credentials // contains filtered or unexported fields }
func NewCredentialsBuilder ¶
func NewCredentialsBuilder() *CredentialsBuilder
func (*CredentialsBuilder) Build
deprecated
func (builder *CredentialsBuilder) Build() *Credentials
Deprecated: This function may panic under certain circumstances. Use SafeBuild instead.
func (*CredentialsBuilder) SafeBuild ¶ added in v0.1.84
func (builder *CredentialsBuilder) SafeBuild() (*Credentials, error)
func (*CredentialsBuilder) WithAk ¶
func (builder *CredentialsBuilder) WithAk(ak string) *CredentialsBuilder
func (*CredentialsBuilder) WithDerivedPredicate ¶ added in v0.0.79
func (builder *CredentialsBuilder) WithDerivedPredicate(derivedPredicate func(*request.DefaultHttpRequest) bool) *CredentialsBuilder
func (*CredentialsBuilder) WithDomainId ¶
func (builder *CredentialsBuilder) WithDomainId(domainId string) *CredentialsBuilder
func (*CredentialsBuilder) WithIamEndpointOverride ¶
func (builder *CredentialsBuilder) WithIamEndpointOverride(endpoint string) *CredentialsBuilder
func (*CredentialsBuilder) WithIdTokenFile ¶ added in v0.0.96
func (builder *CredentialsBuilder) WithIdTokenFile(idTokenFile string) *CredentialsBuilder
func (*CredentialsBuilder) WithIdpId ¶ added in v0.0.96
func (builder *CredentialsBuilder) WithIdpId(idpId string) *CredentialsBuilder
func (*CredentialsBuilder) WithSecurityToken ¶
func (builder *CredentialsBuilder) WithSecurityToken(token string) *CredentialsBuilder
func (*CredentialsBuilder) WithSk ¶
func (builder *CredentialsBuilder) WithSk(sk string) *CredentialsBuilder
Click to show internal directories.
Click to hide internal directories.