middleware

package
v0.0.0-...-4924b15 Latest Latest
Warning

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

Go to latest
Published: Apr 13, 2020 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Middleware

func Middleware(next http.Handler, role *string) http.Handler

Middleware ...

func VerifyToken

func VerifyToken(tokenString string) (jwt.Claims, error)

Types

type ResultParseJWT

type ResultParseJWT struct {
	UserID uint
	RoleID int
}

func ParseJWT

func ParseJWT(w http.ResponseWriter, r *http.Request) (J *ResultParseJWT, ok bool)

Jump to

Keyboard shortcuts

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