authentication

package
v2.0.0-...-0c29eb5 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InitToken

func InitToken(app app.Application)

InitToken initializes the token by weither loading the keys from the filesystem with the loadToken() function or by generating temporarily ones with the generateToken() function

Types

type CustomClaims

type CustomClaims struct {
	*jwt.StandardClaims
	TokenType string
	User      models.LoggedUser
	Scopes    map[string]bool
}

CustomClaims Auth Claims

func VerifyJWT

func VerifyJWT(tokenString string) (*CustomClaims, error)

VerifyJWT extracts and verifies the validity of the JWT

Jump to

Keyboard shortcuts

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