Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FileTokeStoreSetting ¶
type FileTokeStoreSetting struct {
FileName string `json:"fileName" yaml:"fileName"`
}
type RedisTokenStoreSetting ¶
type TokeStoreSetting ¶
type TokeStoreSetting struct { Mode string `json:"mode" yaml:"mode"` Redis *RedisTokenStoreSetting `json:"redis" yaml:"redis"` Database *DatabaseTokeStoreSetting `json:"database" yaml:"database"` File *FileTokeStoreSetting `json:"file" yaml:"file"` }
type TokenSetting ¶
type TokenSetting struct { BindContextKey string `json:"bindContextKey"` HeaderTokenKey string `json:"headerTokenKey"` Cache bool `json:"cache"` Store *TokeStoreSetting `json:"store" yaml:"store"` OnlineUsers int `json:"onlineUsers" yaml:"onlineUsers"` ReuseAccessToken bool `json:"reuseAccessToken" yaml:"reuseAccessToken"` ReuseRefreshToken bool `json:"reuseRefreshToken" yaml:"reuseRefreshToken"` AccessTokenExpireTime time.Duration `json:"accessTokenExpireTime" yaml:"accessTokenExpireTime"` RefreshTokenExpireTime time.Duration `json:"refreshTokenExpireTime" yaml:"refreshTokenExpireTime"` UseJwtToken bool `json:"useJwtToken"` Jwt *jwt.JwtSetting `json:"jwt" yaml:"jwt"` }
var Setting *TokenSetting = &TokenSetting{ OnlineUsers: 10, ReuseAccessToken: true, ReuseRefreshToken: true, AccessTokenExpireTime: time.Hour * 8, RefreshTokenExpireTime: time.Hour * 24 * 100, Store: &TokeStoreSetting{ Mode: "default", }, }
Click to show internal directories.
Click to hide internal directories.