Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type AppClaims ¶
type AppClaims struct { Scopes []string ScopeIDs []int64 Name string Email string //more... jwtLib.StandardClaims }
AppClaims App票据声明
type Conf ¶
type Conf struct { PublicKey string `yaml:"public_key" toml:"public_key" json:"public_key"` //公钥字符串或公钥文件地址 PrivateKey string `yaml:"private_key" toml:"private_key" json:"private_key"` //私钥字符串或私钥文件地址 Algorithm string `yaml:"algorithm" toml:"algorithm" json:"algorithm"` //加密算法: RS256 | RS512 | HS512 HmacSecret string `yaml:"hmac_secret" toml:"hmac_secret" json:"hmac_secret"` //密钥 TokenIssuer string `yaml:"token_issuer" toml:"token_issuer" json:"token_issuer"` //令牌颁发者 // contains filtered or unexported fields }
Conf 配置信息
type SigningMethod ¶
type SigningMethod string
SigningMethod 签名方法
const ( SigningMethodRS256 SigningMethod = "RS256" //SigningMethodRS256 rsa256方法 SigningMethodRS512 SigningMethod = "RS512" //SigningMethodRS512 rsa512方法 SigningMethodHS512 SigningMethod = "HS512" //SigningMethodHS512 hmac方法 )
Click to show internal directories.
Click to hide internal directories.