clients

package
v11.1.4-modfix Latest Latest
Warning

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

Go to latest
Published: Aug 20, 2024 License: AGPL-3.0 Imports: 44 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type APIKey

type APIKey struct {
	// contains filtered or unexported fields
}

func ProvideAPIKey

func ProvideAPIKey(apiKeyService apikey.Service) *APIKey

func (*APIKey) Authenticate

func (s *APIKey) Authenticate(ctx context.Context, r *authn.Request) (*authn.Identity, error)

func (*APIKey) Hook

func (s *APIKey) Hook(ctx context.Context, identity *authn.Identity, r *authn.Request) error

func (*APIKey) IsEnabled

func (s *APIKey) IsEnabled() bool

func (*APIKey) Name

func (s *APIKey) Name() string

func (*APIKey) Namespace

func (s *APIKey) Namespace() string

func (*APIKey) Priority

func (s *APIKey) Priority() uint

func (*APIKey) ResolveIdentity

func (s *APIKey) ResolveIdentity(ctx context.Context, orgID int64, namespaceID authn.NamespaceID) (*authn.Identity, error)

func (*APIKey) Test

func (s *APIKey) Test(ctx context.Context, r *authn.Request) bool

type Basic

type Basic struct {
	// contains filtered or unexported fields
}

func ProvideBasic

func ProvideBasic(client authn.PasswordClient) *Basic

func (*Basic) Authenticate

func (c *Basic) Authenticate(ctx context.Context, r *authn.Request) (*authn.Identity, error)

func (*Basic) IsEnabled

func (c *Basic) IsEnabled() bool

func (*Basic) Name

func (c *Basic) Name() string

func (*Basic) Priority

func (c *Basic) Priority() uint

func (*Basic) String

func (c *Basic) String() string

func (*Basic) Test

func (c *Basic) Test(ctx context.Context, r *authn.Request) bool

type ExtendedJWT

type ExtendedJWT struct {
	// contains filtered or unexported fields
}

func ProvideExtendedJWT

func ProvideExtendedJWT(cfg *setting.Cfg) *ExtendedJWT

func (*ExtendedJWT) Authenticate

func (s *ExtendedJWT) Authenticate(ctx context.Context, r *authn.Request) (*authn.Identity, error)

func (*ExtendedJWT) IsEnabled

func (s *ExtendedJWT) IsEnabled() bool

func (*ExtendedJWT) Name

func (s *ExtendedJWT) Name() string

func (*ExtendedJWT) Priority

func (s *ExtendedJWT) Priority() uint

func (*ExtendedJWT) Test

func (s *ExtendedJWT) Test(ctx context.Context, r *authn.Request) bool

type Form

type Form struct {
	// contains filtered or unexported fields
}

func ProvideForm

func ProvideForm(client authn.PasswordClient) *Form

func (*Form) Authenticate

func (c *Form) Authenticate(ctx context.Context, r *authn.Request) (*authn.Identity, error)

func (*Form) IsEnabled

func (c *Form) IsEnabled() bool

func (*Form) Name

func (c *Form) Name() string

type Grafana

type Grafana struct {
	// contains filtered or unexported fields
}

func ProvideGrafana

func ProvideGrafana(cfg *setting.Cfg, userService user.Service) *Grafana

func (*Grafana) AuthenticatePassword

func (c *Grafana) AuthenticatePassword(ctx context.Context, r *authn.Request, username, password string) (*authn.Identity, error)

func (*Grafana) AuthenticateProxy

func (c *Grafana) AuthenticateProxy(ctx context.Context, r *authn.Request, username string, additional map[string]string) (*authn.Identity, error)

func (*Grafana) String

func (c *Grafana) String() string

type IdentityClient

type IdentityClient struct {
	// contains filtered or unexported fields
}

func ProvideIdentity

func ProvideIdentity(identity *authn.Identity) *IdentityClient

func (*IdentityClient) Authenticate

func (i *IdentityClient) Authenticate(ctx context.Context, r *authn.Request) (*authn.Identity, error)

func (*IdentityClient) IsEnabled

func (i *IdentityClient) IsEnabled() bool

func (*IdentityClient) Name

func (i *IdentityClient) Name() string

type JWT

type JWT struct {
	// contains filtered or unexported fields
}

func ProvideJWT

func ProvideJWT(jwtService auth.JWTVerifierService, cfg *setting.Cfg) *JWT

func (*JWT) Authenticate

func (s *JWT) Authenticate(ctx context.Context, r *authn.Request) (*authn.Identity, error)

func (*JWT) IsEnabled

func (s *JWT) IsEnabled() bool

func (*JWT) Name

func (s *JWT) Name() string

func (*JWT) Priority

func (s *JWT) Priority() uint

func (*JWT) Test

func (s *JWT) Test(ctx context.Context, r *authn.Request) bool

type LDAP

type LDAP struct {
	// contains filtered or unexported fields
}

func ProvideLDAP

func ProvideLDAP(cfg *setting.Cfg, ldapService ldapService, userService user.Service, authInfoService login.AuthInfoService) *LDAP

func (*LDAP) AuthenticatePassword

func (c *LDAP) AuthenticatePassword(ctx context.Context, r *authn.Request, username, password string) (*authn.Identity, error)

func (*LDAP) AuthenticateProxy

func (c *LDAP) AuthenticateProxy(ctx context.Context, r *authn.Request, username string, _ map[string]string) (*authn.Identity, error)

func (*LDAP) String

func (c *LDAP) String() string

type OAuth

type OAuth struct {
	// contains filtered or unexported fields
}

func ProvideOAuth

func ProvideOAuth(
	name string, cfg *setting.Cfg, oauthService oauthtoken.OAuthTokenService,
	socialService social.Service, settingsProviderService setting.Provider, features featuremgmt.FeatureToggles,
) *OAuth

func (*OAuth) Authenticate

func (c *OAuth) Authenticate(ctx context.Context, r *authn.Request) (*authn.Identity, error)

func (*OAuth) IsEnabled

func (c *OAuth) IsEnabled() bool

func (*OAuth) Logout

func (c *OAuth) Logout(ctx context.Context, user authn.Requester) (*authn.Redirect, bool)

func (*OAuth) Name

func (c *OAuth) Name() string

func (*OAuth) RedirectURL

func (c *OAuth) RedirectURL(ctx context.Context, r *authn.Request) (*authn.Redirect, error)

type Password

type Password struct {
	// contains filtered or unexported fields
}

func ProvidePassword

func ProvidePassword(loginAttempts loginattempt.Service, clients ...authn.PasswordClient) *Password

func (*Password) AuthenticatePassword

func (c *Password) AuthenticatePassword(ctx context.Context, r *authn.Request, username, password string) (*authn.Identity, error)

type Proxy

type Proxy struct {
	// contains filtered or unexported fields
}

func ProvideProxy

func ProvideProxy(cfg *setting.Cfg, cache proxyCache, clients ...authn.ProxyClient) (*Proxy, error)

func (*Proxy) Authenticate

func (c *Proxy) Authenticate(ctx context.Context, r *authn.Request) (*authn.Identity, error)

func (*Proxy) Hook

func (c *Proxy) Hook(ctx context.Context, identity *authn.Identity, r *authn.Request) error

func (*Proxy) IsEnabled

func (c *Proxy) IsEnabled() bool

func (*Proxy) Name

func (c *Proxy) Name() string

func (*Proxy) Priority

func (c *Proxy) Priority() uint

func (*Proxy) Test

func (c *Proxy) Test(ctx context.Context, r *authn.Request) bool

type Render

type Render struct {
	// contains filtered or unexported fields
}

func ProvideRender

func ProvideRender(renderService rendering.Service) *Render

func (*Render) Authenticate

func (c *Render) Authenticate(ctx context.Context, r *authn.Request) (*authn.Identity, error)

func (*Render) IsEnabled

func (c *Render) IsEnabled() bool

func (*Render) Name

func (c *Render) Name() string

func (*Render) Priority

func (c *Render) Priority() uint

func (*Render) Test

func (c *Render) Test(ctx context.Context, r *authn.Request) bool

type Session

type Session struct {
	// contains filtered or unexported fields
}

func ProvideSession

func ProvideSession(cfg *setting.Cfg, sessionService auth.UserTokenService, authInfoService login.AuthInfoService) *Session

func (*Session) Authenticate

func (s *Session) Authenticate(ctx context.Context, r *authn.Request) (*authn.Identity, error)

func (*Session) IsEnabled

func (s *Session) IsEnabled() bool

func (*Session) Name

func (s *Session) Name() string

func (*Session) Priority

func (s *Session) Priority() uint

func (*Session) Test

func (s *Session) Test(ctx context.Context, r *authn.Request) bool

Jump to

Keyboard shortcuts

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