From 748c92984409cada6bd4315a5e95b4f62100c21a Mon Sep 17 00:00:00 2001 From: Hylke Bons Date: Thu, 2 Feb 2017 23:19:27 +0000 Subject: [PATCH] extensions: Shorter salt size for AES --- Sparkles/Extensions.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Sparkles/Extensions.cs b/Sparkles/Extensions.cs index 6a982836..5ee4fb61 100644 --- a/Sparkles/Extensions.cs +++ b/Sparkles/Extensions.cs @@ -57,7 +57,7 @@ namespace Sparkles { public static string AESEncrypt (this string plain_text, string password) { Random random = new Random (); - byte [] salt_bytes = new Byte [128]; + byte [] salt_bytes = new Byte [16]; random.NextBytes (salt_bytes); string salt = Convert.ToBase64String (salt_bytes);