Beispiel #1
0
 public static byte[] ReadBytesEncrypted(byte[] encrypted, string password)
 {
     byte[] decrypted = AESThenHMAC.SimpleDecryptWithPassword(encrypted, password, Constants.NotSecretPayload.Length);
     return(decrypted);
 }
Beispiel #2
0
 public static byte[] WriteBytesEncrypted(byte[] data, string password)
 {
     byte[] encrypted = AESThenHMAC.SimpleEncryptWithPassword(data, password, Constants.NotSecretPayload);
     return(encrypted);
 }