jwt

package module
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Jul 18, 2021 License: MIT Imports: 3 Imported by: 2

README

jwt

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GenerateToken

func GenerateToken(content string) (string, error)

GenerateToken 生成token

func Init

func Init(key string, expireTimeStr string) error

Init 初始化

func VerifyToken

func VerifyToken(tokens string) (string, error)

VerifyToken 格式化token

Types

type JWT

type JWT struct {
	// contains filtered or unexported fields
}

JWT JWT

func (*JWT) GenerateToken

func (receiver *JWT) GenerateToken(content string) (token string, err error)

GenerateToken 生成token

func (*JWT) Init

func (receiver *JWT) Init(key string, expireTimeStr string) (err error)

Init 初始化

func (*JWT) VerifyToken

func (receiver *JWT) VerifyToken(tokens string) (string, error)

VerifyToken 格式化token

Jump to

Keyboard shortcuts

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