auth

package
v0.0.0-...-e33f0fe Latest Latest
Warning

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

Go to latest
Published: Aug 2, 2018 License: Apache-2.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetToken

func GetToken(endpoint string, insecure bool, credential Credential,
	scopes []*token.ResourceActions) (*models.Token, error)

GetToken requests a token against the endpoint using credetial provided

func NewRawTokenAuthorizer

func NewRawTokenAuthorizer(username, service string) modifier.Modifier

NewRawTokenAuthorizer returns a token authorizer which calls method to create token directly

func NewStandardTokenAuthorizer

func NewStandardTokenAuthorizer(client *http.Client, credential Credential,
	customizedTokenService ...string) modifier.Modifier

NewStandardTokenAuthorizer returns a standard token authorizer. The authorizer will request a token from token server and add it to the origin request If customizedTokenService is set, the token request will be sent to it instead of the server get from authorizer

func ParseChallengeFromResponse

func ParseChallengeFromResponse(resp *http.Response) []challenge.Challenge

ParseChallengeFromResponse ...

Types

type Credential

type Credential modifier.Modifier

Credential ...

func NewBasicAuthCredential

func NewBasicAuthCredential(username, password string) Credential

NewBasicAuthCredential ...

Jump to

Keyboard shortcuts

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