jwt

package
v0.6.0 Latest Latest
Warning

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

Go to latest
Published: May 7, 2024 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const FakeJWT = "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIn0.dozjgNryP4J3jVmNHl0w5N_XgL0n3I9PlFUP0THsR8U"

Variables

This section is empty.

Functions

This section is empty.

Types

type JWTWriter

type JWTWriter struct {
	Token *jwt.Token
}

func NewJWTWriter

func NewJWTWriter(token string) (*JWTWriter, error)

func (*JWTWriter) IsHMACAlg added in v0.4.3

func (j *JWTWriter) IsHMACAlg() bool

func (*JWTWriter) SignWithKey

func (j *JWTWriter) SignWithKey(key interface{}) (string, error)

func (*JWTWriter) SignWithMethodAndKey

func (j *JWTWriter) SignWithMethodAndKey(method jwt.SigningMethod, key interface{}) (string, error)

func (*JWTWriter) SignWithMethodAndRandomKey added in v0.4.4

func (j *JWTWriter) SignWithMethodAndRandomKey(method jwt.SigningMethod) (string, error)

func (*JWTWriter) WithAlgNone

func (j *JWTWriter) WithAlgNone() (string, error)

func (*JWTWriter) WithoutSignature

func (j *JWTWriter) WithoutSignature() (string, error)

Jump to

Keyboard shortcuts

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