Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RegisterGenericProvider ¶
func RegisterGenericProvider(factory GenericProviderFactory)
RegisterGenericProvider registers GenericProviderFactory with the specified type
func RegisterOAuthProvider ¶
func RegisterOAuthProvider(factory OAuthProviderFactory)
RegisterOAuthProvider register OAuthProviderFactory with the specified type
func SetupWithOptions ¶
func SetupWithOptions(options []oauth.IdentityProviderOptions) error
SetupWithOptions will verify the configuration and initialize the identityProviders
Types ¶
type GenericProvider ¶
type GenericProvider interface { // Authenticate from remote server Authenticate(username string, password string) (Identity, error) }
func GetGenericProvider ¶
func GetGenericProvider(providerName string) (GenericProvider, error)
GetGenericProvider returns GenericProvider with given name
type GenericProviderFactory ¶
type GenericProviderFactory interface { // Type unique type of the provider Type() string // Apply the dynamic options from kubesphere-config Create(options options.DynamicOptions) (GenericProvider, error) }
type Identity ¶
type Identity interface { // GetUserID required // Identifier for the End-User at the Issuer. GetUserID() string // GetUsername optional // The username which the End-User wishes to be referred to kubesphere. GetUsername() string // GetEmail optional GetEmail() string }
Identity represents the account mapped to kubesphere
type OAuthProvider ¶
type OAuthProvider interface { // IdentityExchangeCallback handle oauth callback, exchange identity from remote server IdentityExchangeCallback(req *http.Request) (Identity, error) }
func GetOAuthProvider ¶
func GetOAuthProvider(providerName string) (OAuthProvider, error)
GetOAuthProvider returns OAuthProvider with given name
type OAuthProviderFactory ¶
type OAuthProviderFactory interface { // Type unique type of the provider Type() string // Create Apply the dynamic options Create(options options.DynamicOptions) (OAuthProvider, error) }
Click to show internal directories.
Click to hide internal directories.