public string Decrypt(byte[] encryptedText) { if (encryptedText == null) { return(null); } AesManagedEncryption dec = new AesManagedEncryption(); return(dec.Decrypt(encryptedText)); }
public byte[] Encrypt(string plainText) { if (string.IsNullOrEmpty(plainText)) { return(null); } AesManagedEncryption enc = new AesManagedEncryption(); return(enc.Encrypt(plainText)); }