Documentation ¶
Index ¶
- func CheckPasswordHash(password, hash string) bool
- func GetJwtClaims(userID int, email string) jwt.MapClaims
- func GetJwtToken(userID int, email string) (string, error)
- func HashPassword(password string) (string, error)
- func VerifyJwtToken(token string) (map[string]string, bool)
- func VerifyUserPassword(password string, passwordHash string) (string, bool)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckPasswordHash ¶
This function checks HASH of the password with the database hash saved
func GetJwtClaims ¶
GetJwtClaims create claims and return for use in JWT
func GetJwtToken ¶
GetJwtToken creates JWT token from UserID & email address
func HashPassword ¶
This function creates HASH of the password using bcrypt
func VerifyJwtToken ¶
ValidateJwtToken as name suggests validates JWT Token
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.