Documentation ¶
Index ¶
- Constants
- func AuthRequired() gin.HandlerFunc
- func AuthUser(c *gin.Context, userPtr model.IUser) (isAbort bool)
- func AuthUserId(c *gin.Context) (userId uint, isAbort bool)
- func Locale() gin.HandlerFunc
- func RequestLogger() gin.HandlerFunc
- func Revoke(c *gin.Context) error
- func Throttle(maxAttempts uint, decayMinutes uint) gin.HandlerFunc
- type TokenRevokeError
- type UserNotExistError
- type UserNotLoginError
Constants ¶
View Source
const ( CLAIM_KEY = "CLAIM" TOKEN_KEY = "TOKEN" )
Variables ¶
This section is empty.
Functions ¶
func AuthRequired ¶
func AuthRequired() gin.HandlerFunc
func Locale ¶ added in v0.2.0
func Locale() gin.HandlerFunc
func RequestLogger ¶ added in v0.2.0
func RequestLogger() gin.HandlerFunc
Types ¶
type TokenRevokeError ¶ added in v0.3.0
type TokenRevokeError struct{}
func (TokenRevokeError) Error ¶ added in v0.3.0
func (e TokenRevokeError) Error() string
type UserNotExistError ¶ added in v0.8.0
type UserNotExistError struct{}
func (UserNotExistError) Error ¶ added in v0.8.0
func (e UserNotExistError) Error() string
type UserNotLoginError ¶ added in v0.3.0
type UserNotLoginError struct{}
func (UserNotLoginError) Error ¶ added in v0.3.0
func (e UserNotLoginError) Error() string
Click to show internal directories.
Click to hide internal directories.