auth

package
v0.0.0-...-bd0de05 Latest Latest
Warning

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

Go to latest
Published: Oct 13, 2023 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	JWT_SECRET = os.Getenv("JWT_SECRET")
)

Functions

func CheckDefaultAuth

func CheckDefaultAuth(token string) (string, error)

func GetUserIdByToken

func GetUserIdByToken(token string) (int64, error)

Types

type User

type User struct {
	Id string `json:id`

	Username string `json:username`

	Nickname string `json:nickname`
}

func Parse

func Parse(credential string) (*User, error)

Jump to

Keyboard shortcuts

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