authorizer

package
v0.14.2 Latest Latest
Warning

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

Go to latest
Published: Oct 4, 2019 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Overview

Package authorizer provides authorization handlers to the server.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Decision added in v0.10.0

func Decision(ref func() ast.Ref) func(*Basic)

Decision returns an argument that sets the path of the authorization decision to query.

func NewBasic

func NewBasic(inner http.Handler, compiler func() *ast.Compiler, store storage.Store, opts ...func(*Basic)) http.Handler

NewBasic returns a new Basic object.

func Runtime added in v0.10.0

func Runtime(term *ast.Term) func(*Basic)

Runtime returns an argument that sets the runtime on the authorizer.

Types

type Basic

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

Basic provides policy-based authorization over incoming requests.

func (*Basic) ServeHTTP

func (h *Basic) ServeHTTP(w http.ResponseWriter, r *http.Request)

Jump to

Keyboard shortcuts

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