entitlement

package
v0.0.0-...-21bb2c0 Latest Latest
Warning

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

Go to latest
Published: Apr 12, 2024 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CheckEntitlementHandler

func CheckEntitlementHandler(log logr.Logger, next http.Handler, publicRoutes []string) http.HandlerFunc

CheckEntitlementHandler looks for an entitlement in the request context and returns a 500 if the entitlement is not found or appends an HTTP header with an expired message.

func EntitlementHandler

func EntitlementHandler(ctx context.Context, log logr.Logger, c client.Client, key client.ObjectKey, next http.Handler) http.Handler

LoadEntitlementIntoContextHandler retrieves the entitlement from Kubernetes and adds it to the request context.

func IsPublicRoute

func IsPublicRoute(u *url.URL, publicRoutes []string) bool

Types

This section is empty.

Jump to

Keyboard shortcuts

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