authorizer

package
v0.0.0-...-c1bceec Latest Latest
Warning

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

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

Documentation

Index

Constants

View Source
const (
	GetVerb    = "get"
	CreateVerb = "create"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Authorizer

type Authorizer struct {
	// contains filtered or unexported fields
}

func New

func New(c openshift.Client, l log.Logger, cc cache.Cacher, matcher *config.Matcher) *Authorizer

func (*Authorizer) Authorize

func (a *Authorizer) Authorize(
	token,
	user string, groups []string,
	verb, resource, resourceName, apiGroup string,
	namespaces []string, metadataOnly bool,
) (types.DataResponseV1, error)

type AuthzResponseData

type AuthzResponseData struct {
	Matchers  []*labels.Matcher `json:"matchers,omitempty"`
	MatcherOp config.MatcherOp  `json:"matcherOp,omitempty"`
}

type StatusCodeError

type StatusCodeError struct {
	SC int
	// contains filtered or unexported fields
}

func (*StatusCodeError) StatusCode

func (s *StatusCodeError) StatusCode() int

type StatusCoder

type StatusCoder interface {
	StatusCode() int
}

Jump to

Keyboard shortcuts

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