Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateToken ¶
Create token by user id.If operation is success return token.Otherwise return error.
func ExtractToken ¶
Parameter is a gin.Context. Extract string token.
func GetUserIdByToken ¶
func GetUserIdByToken(token *jwt.Token) interface{}
Send token and getting the user id.
func TokenValid ¶
tokenString type is string.If token is invalid return false otherwise returns true.
func VerifyToken ¶
Parameter is string token. Return *jwt.Token type.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.