Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewContext ¶
func NewContext(ctx context.Context, a *AuthContext) context.Context
Types ¶
type AuthContext ¶
func FromContext ¶
func FromContext(ctx context.Context) (*AuthContext, bool)
type AuthProvider ¶
type AuthProvider interface { // Returns HTTP middleware for performing authentication. Middleware() func(http.Handler) http.Handler }
Abstracts the authentication backend for the server.
func NewBasicAuth ¶
func NewBasicAuth(realm, username, password string) (AuthProvider, error)
func NewFromURL ¶
func NewFromURL(cfg *config.Config, authURL string) (AuthProvider, error)
Click to show internal directories.
Click to hide internal directories.