[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 4/6] crypto: remove bogus /= 2 for pbkdf iterations
From: |
Daniel P. Berrange |
Subject: |
[Qemu-devel] [PATCH 4/6] crypto: remove bogus /= 2 for pbkdf iterations |
Date: |
Thu, 8 Sep 2016 17:27:25 +0100 |
When calculating iterations for pbkdf of the key slot
data, we had a /= 2, which was copied from identical
code in cryptsetup. It was always unclear & undocumented
by cryptsetup had this division and it was recently
removed too.
Signed-off-by: Daniel P. Berrange <address@hidden>
---
crypto/block-luks.c | 3 ---
1 file changed, 3 deletions(-)
diff --git a/crypto/block-luks.c b/crypto/block-luks.c
index 11047fa..7d5893a 100644
--- a/crypto/block-luks.c
+++ b/crypto/block-luks.c
@@ -1154,9 +1154,6 @@ qcrypto_block_luks_create(QCryptoBlock *block,
/* iter_time was in millis, but count_iters reported for secs */
iters /= 1000;
- /* Why /= 2 ? That matches cryptsetup, but there's no
- * explanation why they chose /= 2... */
- iters /= 2;
if (iters > UINT32_MAX) {
error_setg(errp, "Too many PBKDF iterations for LUKS format");
goto error;
--
2.7.4
- Re: [Qemu-devel] [PATCH 2/6] crypto: clear out buffer after timing pbkdf algorithm, (continued)
- [Qemu-devel] [PATCH 1/6] crypto: make PBKDF iterations configurable for LUKS format, Daniel P. Berrange, 2016/09/08
- [Qemu-devel] [PATCH 3/6] crypto: use correct derived key size when timing pbkdf, Daniel P. Berrange, 2016/09/08
- [Qemu-devel] [PATCH 6/6] crypto: support more hash algorithms for pbkdf, Daniel P. Berrange, 2016/09/08
- [Qemu-devel] [PATCH 4/6] crypto: remove bogus /= 2 for pbkdf iterations,
Daniel P. Berrange <=
- [Qemu-devel] [PATCH 5/6] crypto: increase default pbkdf2 time for luks to 2 seconds, Daniel P. Berrange, 2016/09/08
- Re: [Qemu-devel] [PATCH 0/6] crypto: misc tweaks & improvements to pbkdf code, no-reply, 2016/09/08