util

package
v0.0.0-...-9cb7876 Latest Latest
Warning

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

Go to latest
Published: Jan 8, 2023 License: AGPL-3.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ParseUint

func ParseUint(key string) (uint, error)

ParseUint .

func Unsign

func Unsign(tokenString string) (uint, error)

Unsign token

Types

type Token

type Token struct {
	UserID   uint      `json:"userID"`
	Token    string    `json:"token"`
	ExpireAt time.Time `json:"expireAt"`
}

Token .

func Sign

func Sign(userID uint) (*Token, error)

Sign token

Jump to

Keyboard shortcuts

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