Help us shape the future of Go! Take the 2026 Go Developer Survey

middleware

package
v0.56.0 Latest Latest
Warning

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

Go to latest
Published: Jan 29, 2024 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func WithAuthzMiddleware

func WithAuthzMiddleware(enforcer Enforcer, logger *log.Helper) middleware.Middleware

Check Authorization for the current API operation against the current user/token

Types

type Enforcer

type Enforcer interface {
	Enforce(...interface{}) (bool, error)
}

type ServerOperationMap

type ServerOperationMap map[string][]*authz.Policy

Contains a map of server operations to the ResourceAction tuples that are required to perform the operation If it contains more than one, a single match will suffice

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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