Documentation
¶
Index ¶
- Constants
- func AddAsResponseHeader(w http.ResponseWriter, token *Token)
- func ContainsLatest(ctx context.Context) bool
- func WarrantTokenMiddleware(next http.Handler) http.Handler
- func WithLatest(parent context.Context) context.Context
- type ClientPassedWookieCtxKey
- type ServerCreatedWookieCtxKey
- type Token
- type WarrantTokenCtxKey
Constants ¶
View Source
const HeaderName = "Warrant-Token"
View Source
const Latest = "latest"
Variables ¶
This section is empty.
Functions ¶
func AddAsResponseHeader ¶ added in v0.42.0
func AddAsResponseHeader(w http.ResponseWriter, token *Token)
func ContainsLatest ¶
Returns true if ctx contains wookie set to 'latest', false otherwise.
func WarrantTokenMiddleware ¶ added in v0.43.0
Types ¶
type ClientPassedWookieCtxKey ¶ added in v0.42.0
type ClientPassedWookieCtxKey struct{}
type ServerCreatedWookieCtxKey ¶ added in v0.42.0
type ServerCreatedWookieCtxKey struct{}
type Token ¶ added in v0.39.0
func FromString ¶ added in v0.39.0
De-serialize token from string (from header).
func GetClientPassedWookieFromRequestContext ¶ added in v0.42.0
func GetServerCreatedWookieFromRequestContext ¶ added in v0.42.0
type WarrantTokenCtxKey ¶ added in v0.43.0
type WarrantTokenCtxKey struct{}
Click to show internal directories.
Click to hide internal directories.