jwt

package
v2.2.4 Latest Latest
Warning

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

Go to latest
Published: Nov 20, 2020 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetJwk

func GetJwk(url string, httpClient http.Client) (*jwk.Set, error)

Types

type JwtService

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

func NewJwtService

func NewJwtService(jwkResourceUrl string, clock clock.Clock) (*JwtService, error)

func (*JwtService) GetJwtToken added in v2.2.2

func (j *JwtService) GetJwtToken(authHeader string) (*JwtStruct, error)

func (*JwtService) GetJwtTokenFromContext added in v2.2.3

func (j *JwtService) GetJwtTokenFromContext(ctx context.Context) (*JwtStruct, error)

func (*JwtService) GetJwtTokenFromRequest added in v2.2.4

func (j *JwtService) GetJwtTokenFromRequest(req *http.Request) (*JwtStruct, error)

type JwtStruct

type JwtStruct struct {
	UserName       string   `json:"user_name"`
	Uxid           string   `json:"uxid"`
	SessionID      string   `json:"sessionId"`
	CustomerNumber string   `json:"customerNumber"`
	Locale         string   `json:"locale"`
	DeviceID       string   `json:"deviceId"`
	Authorities    []string `json:"authorities"`
	ClientID       string   `json:"client_id"`
	Site           string   `json:"site"`
	Scope          []string `json:"scope"`
}

Jump to

Keyboard shortcuts

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