Beispiel #1
0
        internal byte[] GetIV(string salt, Encoding encoding)
        {
            var finalSaltBytes = string.IsNullOrWhiteSpace(salt)
                ? new byte[0]
                : encoding.SafeEncodingValue().GetBytes(salt);

            return(SymmetricKeyHelper.ComputeRealValue(IV, finalSaltBytes, 128));
        }
Beispiel #2
0
        internal byte[] GetIV(byte[] saltBytes)
        {
            var finalSaltBytes = CloneBytes(ref saltBytes);

            return(SymmetricKeyHelper.ComputeRealValue(IV, finalSaltBytes, 128));
        }
Beispiel #3
0
        internal byte[] GetKey(byte[] saltBytes)
        {
            var finalSaltBytes = CloneBytes(ref saltBytes);

            return(SymmetricKeyHelper.ComputeRealValue(Key, finalSaltBytes, Size));
        }
Beispiel #4
0
 internal byte[] GetIV()
 {
     return(SymmetricKeyHelper.ComputeRealValue(IV, null, 128));
 }
Beispiel #5
0
 internal byte[] GetKey()
 {
     return(SymmetricKeyHelper.ComputeRealValue(Key, null, Size));
 }