Documentation
¶
Index ¶
- type Configuration
- type Introspection
- type Provider
- type ProviderRepository
- type Service
- func (s *Service) ApplyMapping(ctx context.Context, tenantID string, provider Provider) error
- func (s *Service) BlockMapping(ctx context.Context, tenantID string) error
- func (s *Service) RemoveMapping(ctx context.Context, tenantID string) error
- func (s *Service) UnblockMapping(ctx context.Context, tenantID string) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Configuration ¶ added in v0.5.0
type Configuration struct {
Issuer string `json:"issuer,omitempty"`
AuthorizationEndpoint string `json:"authorization_endpoint,omitempty"`
TokenEndpoint string `json:"token_endpoint,omitempty"`
UserinfoEndpoint string `json:"userinfo_endpoint,omitempty"`
JwksURI string `json:"jwks_uri,omitempty"`
IntrospectionEndpoint string `json:"introspection_endpoint,omitempty"`
ResponseTypesSupported []string `json:"response_types_supported,omitempty"`
GrantTypesSupported []string `json:"grant_types_supported,omitempty"`
SubjectTypesSupported []string `json:"subject_types_supported,omitempty"`
IDTokenSigningAlgValuesSupported []string `json:"id_token_signing_alg_values_supported,omitempty"`
ScopesSupported []string `json:"scopes_supported,omitempty"`
TokenEndpointAuthMethodsSupported []string `json:"token_endpoint_auth_methods_supported,omitempty"`
ClaimsSupported []string `json:"claims_supported,omitempty"`
}
Configuration. Usually accessible from the well-known openid-configuration URL. It's a subset of https://openid.net/specs/openid-connect-discovery-1_0.html#ProviderMetadata
type Introspection ¶ added in v0.11.0
type Provider ¶
type Provider struct {
IssuerURL string
Blocked bool
JWKSURI string
Audiences []string
Properties map[string]string
QueryParametersIntrospect []string
}
func (*Provider) GetOpenIDConfig ¶ added in v0.11.0
func (*Provider) IntrospectToken ¶ added in v0.11.0
type ProviderRepository ¶
type ProviderRepository interface {
Get(ctx context.Context, tenantID string) (Provider, error)
Create(ctx context.Context, tenantID string, provider Provider) error
Delete(ctx context.Context, tenantID string) error
Update(ctx context.Context, tenantID string, provider Provider) error
}
ProviderRepository allows to read OIDC provider data for a tenant stored in the context.
type Service ¶ added in v0.1.0
type Service struct {
// contains filtered or unexported fields
}
func NewService ¶ added in v0.1.0
func NewService(repo ProviderRepository) *Service
func (*Service) ApplyMapping ¶ added in v0.1.0
func (*Service) BlockMapping ¶ added in v0.6.0
BlockMapping sets the Blocked flag to true for the OIDC provider associated with the given tenantID. If the provider is already blocked, it does nothing. Returns an error if the provider cannot be retrieved or updated.
func (*Service) RemoveMapping ¶ added in v0.1.0
func (*Service) UnblockMapping ¶ added in v0.12.0
UnblockMapping sets the Blocked flag to false for the OIDC provider associated with the given tenantID. If the provider is not blocked, it does nothing. Returns an error if the provider cannot be retrieved or updated.