traefik_auth_converter

package module
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Oct 29, 2023 License: MIT Imports: 5 Imported by: 0

README

Simple Traefik middleware that can convert authorization type between Basic, Bearer, Digest with optional token extraction from username\password for Basic auth and base64 encoding\decoding

Documentation

Index

Constants

View Source
const (
	HeaderName string = "Authorization"
)

Variables

This section is empty.

Functions

func New

func New(ctx context.Context, next http.Handler, config *Config, name string) (http.Handler, error)

Types

type AuthConverter

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

Main struct

func (*AuthConverter) ServeHTTP

func (e *AuthConverter) ServeHTTP(rw http.ResponseWriter, req *http.Request)

Entry point from Traefik

type AuthType added in v0.2.0

type AuthType string

type Config

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

Config structure

func CreateConfig

func CreateConfig() *Config

type TokenSource

type TokenSource string

Jump to

Keyboard shortcuts

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