jwt

package
v1.2.1 Latest Latest
Warning

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

Go to latest
Published: Jun 19, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GenerateAppToken

func GenerateAppToken(App *auth.App, expireTime time.Duration) (token string, err error)

GenerateAppToken 获取app应用的token expireTime 过期时间,单位秒

Types

type ServerClaims

type ServerClaims struct {
	ID      uint   `json:"id"`
	AppName string `json:"app_name"`
	AppID   string `json:"app_id"`
	jwt.RegisteredClaims
}

func ParseAppAuth

func ParseAppAuth(token string) (*ServerClaims, error)

Jump to

Keyboard shortcuts

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