Documentation
¶
Index ¶
Constants ¶
View Source
const (
ContextJWTKey = "user"
)
View Source
const EnvPrefix = "JWT"
Variables ¶
View Source
var ErrJWTTokenNotFound = errors.New("jwt token not found")
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
PrivateKey string `env:"_PRIVATE_KEY,required,expand" envDefault:"${PWD}/testdata/test-jwt.key"`
PublicKey string `env:"_PUBLIC_KEY,required,expand" envDefault:"${PWD}/testdata/test-jwt.pem"`
}
func GetConfigFromEnv ¶
func (Config) GetPrivateKey ¶
func (Config) GetPublicKey ¶
type Payload ¶
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
func (*Service) GetSigningKey ¶
func (j *Service) GetSigningKey() jwtware.SigningKey
Click to show internal directories.
Click to hide internal directories.