jwt

package
v0.2.9 Latest Latest
Warning

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

Go to latest
Published: Apr 12, 2024 License: GPL-3.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DummyJwtGenerator added in v0.1.4

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

func NewDummyJwtGenerator added in v0.1.4

func NewDummyJwtGenerator(issuer string, exp int64, secret string) *DummyJwtGenerator

func (DummyJwtGenerator) GenerateToken added in v0.1.4

func (d DummyJwtGenerator) GenerateToken(auth *domain.Auth, payload map[string]interface{}) (string, error)

func (DummyJwtGenerator) VerifyToken added in v0.1.4

func (d DummyJwtGenerator) VerifyToken(token string) (*domain.Auth, map[string]interface{}, error)

type JwtGenerator

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

func NewJwtGenerator

func NewJwtGenerator() *JwtGenerator

func (JwtGenerator) GenerateToken

func (j JwtGenerator) GenerateToken(auth *domain.Auth, payload map[string]interface{}) (string, error)

func (JwtGenerator) VerifyToken

func (j JwtGenerator) VerifyToken(token string) (*domain.Auth, map[string]interface{}, error)

Jump to

Keyboard shortcuts

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