hardcode

package
v0.0.0-...-3ce7580 Latest Latest
Warning

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

Go to latest
Published: Sep 2, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ISS           = "account-service"
	KID_HEADER    = "kid"
	PAYLOAD_CLAIM = "payload"
)

Variables

View Source
var (
	ErrInvalidSigningMethod  = errors.New("invalid signing method")
	ErrKeyIdentifierNotFound = errors.New("key identifier not found")
	ErrKeyIdentifierEmpty    = errors.New("key identifier empty")
	ErrInvalidToken          = errors.New("invalid token")
	ErrInvalidClaim          = errors.New("invalid claim")
	ErrInvalidPayload        = errors.New("invalid payload")
)

Functions

func EncodePEMPublicKey

func EncodePEMPublicKey(pub *ecdsa.PublicKey) (result []byte, err error)

func New

func New(issuer string) *defaultHandler

func ParsePEMPrivateKey

func ParsePEMPrivateKey(pem []byte) (*ecdsa.PrivateKey, error)

func ParsePEMPublicKey

func ParsePEMPublicKey(pem []byte) (*ecdsa.PublicKey, error)

Types

type CustomClaim

type CustomClaim struct {
	jwt.StandardClaims
	Payload string `json:"payload"`
}

Jump to

Keyboard shortcuts

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