middlewares

package
v1.1.8 Latest Latest
Warning

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

Go to latest
Published: Apr 16, 2020 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Logging

func Logging(next web.View) web.View

Logging middleware

func Recover

func Recover(next web.View) web.View

Recover middleware

Types

type BasicAuth added in v1.1.1

type BasicAuth struct {
	Resolve func(username, password string) bool
}

BasicAuth middleware

func (*BasicAuth) View added in v1.1.1

func (mid *BasicAuth) View(nextView web.View) web.View

View middleware

type CSRF

type CSRF struct {
	CookiePath  string
	CookieName  string
	HeaderName  string
	TokenLength int
	MaxAge      int // in seconds
	HTTPOnly    bool
}

CSRF middleware

func (*CSRF) View

func (csrf *CSRF) View(nextView web.View) web.View

View middleware

Jump to

Keyboard shortcuts

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