/// <summary>Creates a SymmetricAlgorithm used by this SPI.</summary> public SymmetricAlgorithm CreateSymmetricAlgorithm() { SymmetricAlgorithm sa = null; if (Encryptor.Equals("NullEncryption")) { sa = new NullEncryption(); } else { sa = SymmetricAlgorithm.Create(Encryptor); } if (sa == null) { throw new Exception("Unsupported encryption algorithm: " + Encryptor); } return(sa); }
/// <summary>Creates a SymmetricAlgorithm used by this SPI.</summary> public SymmetricAlgorithm CreateSymmetricAlgorithm() { SymmetricAlgorithm sa = null; if(Encryptor.Equals("NullEncryption")) { sa = new NullEncryption(); } else { sa = SymmetricAlgorithm.Create(Encryptor); } if(sa == null) { throw new Exception("Unsupported encryption algorithm: " + Encryptor); } return sa; }