tollbooth

package
v0.0.0-...-98dad3e Latest Latest
Warning

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

Go to latest
Published: Dec 6, 2024 License: Apache-2.0 Imports: 13 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ExtractToken

func ExtractToken(r *http.Request) (string, error)

ExtractToken extracts the token from an auth request. In the case of a request to Tollbooth, the token is the entire contents of the request body.

func NewAuthorizer

func NewAuthorizer(logger log.Logger, c *http.Client, to *url.URL) *authorizer

func NewMock

func NewMock(logger log.Logger, tokenSet map[string]struct{}) *mock

Types

type Key

type Key struct {
	Token   string
	Cluster string
}

Jump to

Keyboard shortcuts

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