provider

package
v3.3.4+incompatible Latest Latest
Warning

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

Go to latest
Published: Jul 31, 2017 License: Apache-2.0 Imports: 7 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetProviders

func GetProviders() map[string]TeamProvider

func Register

func Register(providerName string, providerConstructor TeamProvider)

Types

type AuthConfig

type AuthConfig interface {
	IsConfigured() bool
	Validate() error
	AuthMethod(oauthBaseURL string, teamName string) atc.AuthMethod
}

type AuthConfigs

type AuthConfigs map[string]AuthConfig

type OAuthClient

type OAuthClient interface {
	AuthCodeURL(string, ...oauth2.AuthCodeOption) string
	Exchange(context.Context, string) (*oauth2.Token, error)
	Client(context.Context, *oauth2.Token) *http.Client
}

type Provider

type Provider interface {
	PreTokenClient() (*http.Client, error)

	OAuthClient
	Verifier
}

func NewProvider

func NewProvider(
	auth *json.RawMessage,
	providerName string,
	redirectURL string,
) (Provider, bool)

type TeamProvider

type TeamProvider interface {
	ProviderConstructor(AuthConfig, string) (Provider, bool)
	AddAuthGroup(*flags.Group) AuthConfig
	UnmarshalConfig(*json.RawMessage) (AuthConfig, error)
}

type Verifier

type Verifier interface {
	Verify(lager.Logger, *http.Client) (bool, error)
}

Directories

Path Synopsis
Code generated by counterfeiter.
Code generated by counterfeiter.

Jump to

Keyboard shortcuts

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