Exemple #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));
        }
Exemple #2
0
        internal byte[] GetIV(byte[] saltBytes)
        {
            var finalSaltBytes = CloneBytes(ref saltBytes);

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

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