type

AuthStrategy

type AuthStrategy struct { // Name is a stable lowercase kebab-case identifier used in diagnostics. Name string // Authenticate returns Authenticated false when the request does not belong // to this strategy. It must not return raw credentials or untrusted user data. Authenticate func(AuthStrategyContext) (AuthStrategyResult, error) }

One compiled application-owned request authentication strategy.

Source core/auth_contract.go:93

@param Name
A stable lowercase kebab-case identifier used in diagnostics.
@param Authenticate
Recognizes and authenticates the request without returning raw credentials or untrusted user data.

Strategies run in declaration order after built-in session and API-key authentication. Return Authenticated false when the request does not belong to the strategy.

Related types