Example #1
0
        public bool ValidateLoginAttempt(ObjectId userid, string username, byte[] enteredPassword)
        {
            User user = FindUserByID(userid);

            byte[] saltedHash = Authorize.GenerateSaltedHash(enteredPassword, user.password.passwordSalt);
            return(Authorize.IsValidHash(saltedHash, user.password.passwordHash));
        }