tools

package
v1.16.23 Latest Latest
Warning

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

Go to latest
Published: Nov 23, 2023 License: AGPL-3.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Http *tool.Http

Functions

func GenCallback

func GenCallback(callback, token string) (string, error)

func GetUserInfo

func GetUserInfo(c *gin.Context) *jwt.UserToken

func NewMfa

func NewMfa(uid uint) (*otp.Key, error)

func SoftHttpSrv

func SoftHttpSrv(E *gin.Engine) error

func VerifyMfa

func VerifyMfa(code, secret string) (bool, error)

Types

type UintSlice

type UintSlice []uint

func (UintSlice) Len

func (a UintSlice) Len() int

func (UintSlice) Less

func (a UintSlice) Less(i, j int) bool

func (UintSlice) Swap

func (a UintSlice) Swap(i, j int)

Jump to

Keyboard shortcuts

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