go_tokn

package module
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: May 23, 2023 License: MIT Imports: 4 Imported by: 0

README

Go-Jwt

Go-Jwt is a JWT token implementation for golang

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrRegenerateFailed    = err("failed to regenerate token")
	ErrTokenExpired        = err("token is expired")
	ErrTokenInvalid        = err("token is invalid")
	ErrRefreshTokenMissing = err("refresh token missing")
)

Functions

This section is empty.

Types

type TokenInt

type TokenInt interface {
	CreateTokenPair(customFields map[string]interface{}) (*models.Token, error)
	ValidateToken(refreshToken string) error
	RefreshToken(refreshToken string) (*models.Token, error)
}

func New

func New(store models.TokenStore, refreshSecret, accessSecret string, refreshTokenDuration, accessTokenDuration time.Duration) TokenInt

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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