basicauth

package module
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Jun 21, 2024 License: MIT Imports: 3 Imported by: 0

README

basicauth

golang middleware for constant-time basic auth

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Builder added in v0.0.2

func Builder(providedCreds map[string]string, opts ...Option) (func(http.HandlerFunc) http.HandlerFunc, error)

Builder is a factory-type function that returns middleware that middleware function can be handed an http.HandlerFunc and returns one anything that middleware is wrapped around should require and authenticate with constant-time comparison basic auth

Types

type BasicAuthConfig

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

type Option

type Option func(*BasicAuthConfig)

func WithUnsafeHTTP

func WithUnsafeHTTP() Option

Directories

Path Synopsis
cmd

Jump to

Keyboard shortcuts

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