Documentation
¶
Overview ¶
Package jwt holds JWT related funcs
Index ¶
Constants ¶
View Source
const (
// Bearer is a prefix of JWT header value
Bearer = "Bearer"
)
Variables ¶
This section is empty.
Functions ¶
Types ¶
type App ¶
App - Класс сервера API
func (*App) Create ¶
func (a *App) Create(producer string, s *json.RawMessage) (*json.RawMessage, error)
Create - creates JWT
type CustomClaims ¶
type CustomClaims struct { Data *json.RawMessage `json:"data"` jwt.StandardClaims }
type Flags ¶
type Flags struct { Key string `long:"jwt_key" description:"Key to sign JWT results"` Age int `long:"jwt_age" default:"96" description:"JWT age to expire token (hours)"` Producer string `long:"jwt_producer" default:"dbrpc" description:"JWT producer name"` AuthHeader string `long:"auth_token_header" default:"X-SSO-Token" description:"Header field to store auth token"` }
Flags is a package flags sample in form ready for use with github.com/jessevdk/go-flags
type SessionSlice ¶
type SessionSlice struct { Data []Session `json:"data"` jwt.StandardClaims }
Click to show internal directories.
Click to hide internal directories.