package
0.0.0-20201110193006-ecac28734172
Repository: https://github.com/cesar-yoab/authservice.git
Documentation: pkg.go.dev
# Functions
ComparePasswords to check if they are equivalent.
ConnectMongo to database and return a pointer to a DB object.
CreateUser fills struct values for insertion in database.
HashPassword given password string.
IsValidEmail returns true if its a valid syntax email code taken from: https://golangcode.com/validate-an-email-address/.
RefreshJWT Provides a new token provided it has a least a minute left of lifetime.
ValidateAndPrepare user input for insertion to database.
ValidUserInput validates given passwords, email and username.