jwt

package
v2.0.13 Latest Latest
Warning

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

Go to latest
Published: Jul 11, 2023 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MakeToken

func MakeToken(key string, userID uint32, ExpiresNum int64) (string, error)

MakeToken 创建token

Types

type MapClaims

type MapClaims struct {
	UserID uint32 `json:"user_id"`
	goJwt.RegisteredClaims
}

func ParseToken

func ParseToken(key, tokenStr string) (*MapClaims, error)

ParseToken 解析token

func (MapClaims) Validate

func (m MapClaims) Validate() error

Jump to

Keyboard shortcuts

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