authenticator

package
v1.0.0-beta.231 Latest Latest
Warning

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

Go to latest
Published: Jul 14, 2026 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetAuthenticatedSubject

func GetAuthenticatedSubject(ctx context.Context) (string, bool)

GetAuthenticatedSubject returns the authenticated subject from the context.

Types

type Authenticator

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

func NewAuthenticator

func NewAuthenticator(portal portal.Service, errorHandler errorsx.Handler) Authenticator

func (Authenticator) NewAuthenticatorMiddlewareFunc

func (a Authenticator) NewAuthenticatorMiddlewareFunc(swagger *openapi3.T) func(http.Handler) http.Handler

NewAuthenticatorMiddlewareFunc returns a middleware function that authenticates requests based on the OpenAPI 3 security requirements. TODO: support custom claims

type AuthenticatorContextKey

type AuthenticatorContextKey string
const (
	AuthenticatorSubjectSessionKey AuthenticatorContextKey = "openmeter_subject"
)

Jump to

Keyboard shortcuts

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