auth

package
v0.0.0-...-c380036 Latest Latest
Warning

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

Go to latest
Published: Apr 7, 2022 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Authorize

type Authorize interface {
	CreateJWT(userId string) (string, error)
	ParseJWT(token string) (string, error)
}

type Manager

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

func NewManager

func NewManager(tokenTTL time.Duration) (*Manager, error)

func (*Manager) CreateJWT

func (m *Manager) CreateJWT(userId string) (string, error)

func (*Manager) ParseJWT

func (m *Manager) ParseJWT(tokenString string) (user_id string, err error)

Directories

Path Synopsis
Package mock_auth is a generated GoMock package.
Package mock_auth is a generated GoMock package.

Jump to

Keyboard shortcuts

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