public static string Encryption(string plain, string key, IBlockCipherPadding padding) { AESEncryptor encriptor = new AESEncryptor(); encriptor.SetPadding(padding); return(encriptor.Encrypt(plain, key)); }
public static string Decryption(string cipher, string key, IBlockCipherPadding padding) { AESEncryptor encriptor = new AESEncryptor(); encriptor.SetPadding(padding); return(encriptor.Decrypt(cipher, key)); }