teknoraver / rpms / systemd

Forked from rpms/systemd 3 months ago
Clone

Blame SOURCES/0237-test-use-PBKDF2-instead-of-Argon2-in-cryptsetup.patch

Brian Stinson 2593d8
From a7f18f9ef4abc7e0732d1710ead2a18a38c3ec6d Mon Sep 17 00:00:00 2001
Brian Stinson 2593d8
From: Frantisek Sumsal <frantisek@sumsal.cz>
Brian Stinson 2593d8
Date: Fri, 15 Mar 2019 10:05:33 +0100
Brian Stinson 2593d8
Subject: [PATCH] test: use PBKDF2 instead of Argon2 in cryptsetup...
Brian Stinson 2593d8
Brian Stinson 2593d8
to reduce memory requirements for volume manipulation. Also,
Brian Stinson 2593d8
to further improve the test performance, reduce number of PBKDF
Brian Stinson 2593d8
iterations to 1000 (allowed minimum).
Brian Stinson 2593d8
Brian Stinson 2593d8
(cherry picked from commit 5b69d297c153478f6f5e74ba66e1f4e5b6422baf)
Brian Stinson 2593d8
Brian Stinson 2593d8
Related: #1761519
Brian Stinson 2593d8
---
Brian Stinson 2593d8
 test/TEST-02-CRYPTSETUP/test.sh | 2 +-
Brian Stinson 2593d8
 1 file changed, 1 insertion(+), 1 deletion(-)
Brian Stinson 2593d8
Brian Stinson 2593d8
diff --git a/test/TEST-02-CRYPTSETUP/test.sh b/test/TEST-02-CRYPTSETUP/test.sh
Brian Stinson 2593d8
index 545602e17a..c38e56f72e 100755
Brian Stinson 2593d8
--- a/test/TEST-02-CRYPTSETUP/test.sh
Brian Stinson 2593d8
+++ b/test/TEST-02-CRYPTSETUP/test.sh
Brian Stinson 2593d8
@@ -29,7 +29,7 @@ check_result_qemu() {
Brian Stinson 2593d8
 test_setup() {
Brian Stinson 2593d8
     create_empty_image
Brian Stinson 2593d8
     echo -n test >$TESTDIR/keyfile
Brian Stinson 2593d8
-    cryptsetup -q luksFormat ${LOOPDEV}p2 $TESTDIR/keyfile
Brian Stinson 2593d8
+    cryptsetup -q luksFormat --pbkdf pbkdf2 --pbkdf-force-iterations 1000 ${LOOPDEV}p2 $TESTDIR/keyfile
Brian Stinson 2593d8
     cryptsetup luksOpen ${LOOPDEV}p2 varcrypt <$TESTDIR/keyfile
Brian Stinson 2593d8
     mkfs.ext4 -L var /dev/mapper/varcrypt
Brian Stinson 2593d8
     mkdir -p $TESTDIR/root