filters

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Jul 1, 2019 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BasicAuthenticationFilter

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

BasicAuthenticationFilter provides security with basic authentication mechanism

func NewBasicAuthenticationFilter

func NewBasicAuthenticationFilter(repository storage.Repository) *BasicAuthenticationFilter

NewBasicAuthenticationFilter returns new basic auth filter for given repository

func (*BasicAuthenticationFilter) Filter

func (ba *BasicAuthenticationFilter) Filter(r *http.Request) (int, error)

Filter filters http request on some conditions

func (*BasicAuthenticationFilter) MatchingEndpoints

func (ba *BasicAuthenticationFilter) MatchingEndpoints() []web.Endpoint

MatchingEndpoints returns all the endpoints that the filter should be attached before.

Jump to

Keyboard shortcuts

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