myjwt

package
v0.0.0-...-1c779d3 Latest Latest
Warning

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

Go to latest
Published: Jul 13, 2020 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AdminAuthorizator

func AdminAuthorizator(data interface{}, c *gin.Context) bool

role is admin can access

func AllUserAuthorizator

func AllUserAuthorizator(data interface{}, c *gin.Context) bool

func GinJWTMiddlewareInit

func GinJWTMiddlewareInit(jwtAuthorizator JwtAuthorizator) (authMiddleware *jwt.GinJWTMiddleware)

func NoRouteHandler

func NoRouteHandler(c *gin.Context)

404 handler

func TestAuthorizator

func TestAuthorizator(data interface{}, c *gin.Context) bool

username is test can access

Types

type JwtAuthorizator

type JwtAuthorizator func(data interface{}, c *gin.Context) bool

Jump to

Keyboard shortcuts

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