Documentation
¶
Index ¶
Constants ¶
View Source
const COOKIE_NAME = "Eclair-+-Token"
View Source
const SECRET = "Eclair-#&#-Secret"
Variables ¶
This section is empty.
Functions ¶
func CheckJWToken ¶
func CheckJWToken(w http.ResponseWriter, r *http.Request)
CheckJWToken проверяет валидность пользователя
func SetHandles ¶
func SetHandles()
SetHandles устанавливает все обработчики запросов к Web-серверу, вызывается из main()
Types ¶
type JWTCustomClaims ¶
type JWTCustomClaims struct {
Login string `json:"login"`
Role int `json:"role"`
jwt.StandardClaims
}
JWTCustomClaims is a struct Public part of claims.
Click to show internal directories.
Click to hide internal directories.