Пример #1
0
        public bool Invalid_hash_cannot_be_verified(ISecureHashProvider provider)
        {
            var hash   = provider.Password(Encoding.UTF8.GetBytes(Password));
            var result = provider.PasswordVerify(Encoding.UTF8.GetBytes("rosebowl"), hash);

            return(result == VerifyHashResult.Invalid);
        }
Пример #2
0
        public bool Hash_can_be_verified(ISecureHashProvider provider)
        {
            var hash   = provider.Password(Encoding.UTF8.GetBytes(Password));
            var result = provider.PasswordVerify(Encoding.UTF8.GetBytes(Password), hash);

            return(result == VerifyHashResult.Valid);
        }