generator

package module
v0.0.0-...-75ed8a4 Latest Latest
Warning

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

Go to latest
Published: Jul 2, 2023 License: Apache-2.0 Imports: 9 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AccessGenerate

type AccessGenerate struct {
}

AccessGenerate generate the access token

func NewAccessGenerate

func NewAccessGenerate() *AccessGenerate

NewAccessGenerate create to generate the access token instance

func (*AccessGenerate) Token

func (ag *AccessGenerate) Token(ctx context.Context, data *definition.GenerateBasic, isGenRefresh bool) (body definition.GenerateTokenBody, err error)

Token based on the UUID generated token

type AuthorizeGenerate

type AuthorizeGenerate struct{}

AuthorizeGenerate generate the authorize code

func NewAuthorizeGenerate

func NewAuthorizeGenerate() *AuthorizeGenerate

NewAuthorizeGenerate create to generate the authorize code instance

func (*AuthorizeGenerate) Token

Token based on the UUID generated token

type JWTAccessClaims

type JWTAccessClaims struct {
	jwt.RegisteredClaims
	Scope string `json:"scp,omitempty"`
}

JWTAccessClaims jwt claims

type JWTAccessGenerate

type JWTAccessGenerate struct {
	SignedKeyID  string
	SignedKey    []byte
	SignedMethod jwt.SigningMethod
}

JWTAccessGenerate generate the jwt access token

func NewJWTAccessGenerate

func NewJWTAccessGenerate(kid string, key []byte, method jwt.SigningMethod) *JWTAccessGenerate

NewJWTAccessGenerate create to generate the jwt access token instance

func (*JWTAccessGenerate) Token

func (a *JWTAccessGenerate) Token(ctx context.Context, data *definition.GenerateBasic, isGenRefresh bool) (body definition.GenerateTokenBody, err error)

Token based on the UUID generated token

Jump to

Keyboard shortcuts

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