Help us shape the future of Go! Take the 2026 Go Developer Survey

passport

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Apr 26, 2023 License: BSD-3-Clause Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Claims

type Claims struct {
	UserId string
	jwt.RegisteredClaims
}

type Option added in v0.0.7

type Option func(x *Passport)

func SetKey added in v0.0.7

func SetKey(v string) Option

func SetNamespace added in v0.0.7

func SetNamespace(v string) Option

type Passport

type Passport struct {
	Namespace string
	Key       string
}

func New added in v0.0.7

func New(options ...Option) *Passport

func (*Passport) Create

func (x *Passport) Create(userId string, jti string) (tokenString string, err error)

func (*Passport) Verify

func (x *Passport) Verify(tokenString string) (claims Claims, err error)

Jump to

Keyboard shortcuts

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