package
0.0.12
Repository: https://github.com/m-lab/access.git
Documentation: pkg.go.dev

# Functions

GetClaim attempts to extract the monitoring value from the given context.
IsMonitoring reports whether (possibly nil) claim is from a monitoring issuer.
NewTokenController creates a new token controller that requires tokens (or not) and the default expected claims.
NewTxController creates a new instance and runs TxController.Watch in a goroutine to observe the current rate every 100 msec.
SetClaim returns a derived context with the given value.
Setup creates a sequence of access control http.Handlers.

# Variables

ErrInvalidVerifier may be returned when creating a new TokenController.
ErrNilPaths is returned when a nil Paths value is given.
ErrNoDevice is returned when device is empty or not found in procfs.

# Structs

TokenController manages access control for clients providing access_token parameters in HTTP requests.
TxController calculates the bytes transmitted every period from the named device.

# Interfaces

Controller is the interface that all access control types should implement.
Verifier is used by the TokenController to verify JWT claims in access tokens.

# Type aliases

Paths is used to specify resource names (paths) operated on by access controllers.