Documentation ¶
Index ¶
- Constants
- func Addons(addonProviderGetter provider.AddonProviderGetter, ...) endpoint.Middleware
- func PrivilegedAddons(addonProviderGetter provider.AddonProviderGetter, ...) endpoint.Middleware
- func SetClusterProvider(clusterProviderGetter provider.ClusterProviderGetter, ...) endpoint.Middleware
- func SetPrivilegedClusterProvider(clusterProviderGetter provider.ClusterProviderGetter, ...) endpoint.Middleware
- func TokenExtractor(o auth.TokenExtractor) transporthttp.RequestFunc
- func TokenVerifier(tokenVerifier auth.TokenVerifier, userProvider provider.UserProvider) endpoint.Middleware
- func UserInfoUnauthorized(userProjectMapper provider.ProjectMemberMapper, ...) endpoint.Middleware
- func UserSaver(userProvider provider.UserProvider) endpoint.Middleware
Constants ¶
const ( // RawTokenContextKey key under which the current token (OpenID ID Token) is kept in the ctx RawTokenContextKey kubermaticcontext.Key = "raw-auth-token" // TokenExpiryContextKey key under which the current token expiry (OpenID ID Token) is kept in the ctx TokenExpiryContextKey kubermaticcontext.Key = "auth-token-expiry" // ClusterProviderContextKey key under which the current ClusterProvider is kept in the ctx ClusterProviderContextKey kubermaticcontext.Key = "cluster-provider" // PrivilegedClusterProviderContextKey key under which the current PrivilegedClusterProvider is kept in the ctx PrivilegedClusterProviderContextKey kubermaticcontext.Key = "privileged-cluster-provider" // UserInfoContextKey key under which the current UserInfoExtractor is kept in the ctx UserInfoContextKey kubermaticcontext.Key = "user-info" // AuthenticatedUserContextKey key under which the current User (from OIDC provider) is kept in the ctx AuthenticatedUserContextKey kubermaticcontext.Key = "authenticated-user" // AddonProviderContextKey key under which the current AddonProvider is kept in the ctx AddonProviderContextKey kubermaticcontext.Key = "addon-provider" // PrivilegedAddonProviderContextKey key under which the current PrivilegedAddonProvider is kept in the ctx PrivilegedAddonProviderContextKey kubermaticcontext.Key = "privileged-addon-provider" UserCRContextKey = kubermaticcontext.UserCRContextKey )
Variables ¶
This section is empty.
Functions ¶
func Addons ¶
func Addons(addonProviderGetter provider.AddonProviderGetter, seedsGetter provider.SeedsGetter) endpoint.Middleware
Addons is a middleware that injects the current AddonProvider into the ctx
func PrivilegedAddons ¶
func PrivilegedAddons(addonProviderGetter provider.AddonProviderGetter, seedsGetter provider.SeedsGetter) endpoint.Middleware
PrivilegedAddons is a middleware that injects the current PrivilegedAddonProvider into the ctx
func SetClusterProvider ¶
func SetClusterProvider(clusterProviderGetter provider.ClusterProviderGetter, seedsGetter provider.SeedsGetter) endpoint.Middleware
SetClusterProvider is a middleware that injects the current ClusterProvider into the ctx
func SetPrivilegedClusterProvider ¶
func SetPrivilegedClusterProvider(clusterProviderGetter provider.ClusterProviderGetter, seedsGetter provider.SeedsGetter) endpoint.Middleware
SetPrivilegedClusterProvider is a middleware that injects the current ClusterProvider into the ctx
func TokenExtractor ¶
func TokenExtractor(o auth.TokenExtractor) transporthttp.RequestFunc
TokenExtractor knows how to extract a token from the incoming request
func TokenVerifier ¶
func TokenVerifier(tokenVerifier auth.TokenVerifier, userProvider provider.UserProvider) endpoint.Middleware
TokenVerifier knows how to verify a token from the incoming request
func UserInfoUnauthorized ¶
func UserInfoUnauthorized(userProjectMapper provider.ProjectMemberMapper, userProvider provider.UserProvider) endpoint.Middleware
UserInfoUnauthorized tries to build userInfo for not authenticated (token) user instead it reads the user_id from the request and finds the associated user in the database
func UserSaver ¶
func UserSaver(userProvider provider.UserProvider) endpoint.Middleware
UserSaver is a middleware that checks if authenticated user already exists in the database next it creates/retrieve an internal object (kubermaticv1.User) and stores it the ctx under UserCRContexKey
Types ¶
This section is empty.