From 5e7547f8b732c5c3e7b222e61600d79c123774d4 Mon Sep 17 00:00:00 2001 From: Sean Whitton Date: Fri, 22 Jul 2022 13:52:08 -0700 Subject: add support for passing --cipher to cryptsetup luksFormat Signed-off-by: Sean Whitton --- src/property/disk.lisp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/property') diff --git a/src/property/disk.lisp b/src/property/disk.lisp index 6806bab..40f7809 100644 --- a/src/property/disk.lisp +++ b/src/property/disk.lisp @@ -611,6 +611,7 @@ possible. Ignored if VOLUME-SIZE is also bound.")) "The value of the --type parameter to cryptsetup luksFormat. Note that GRUB2 older than 2.06 cannot open the default LUKS2 format, so specify \"luks1\" if this is needed.") + (luks-cipher :type string :initarg :luks-cipher :accessor luks-cipher) (crypttab-options :type list :initform '("luks" "discard" "initramfs") :initarg :crypttab-options :accessor crypttab-options) @@ -638,6 +639,8 @@ specify \"luks1\" if this is needed.") "cryptsetup" "--type" luks-type (and (member luks-type '("luks" "luks2") :test #'string=) `("--label" ,volume-label)) + (and (slot-boundp volume 'luks-cipher) + `("--cipher" ,(luks-cipher volume))) "luksFormat" file "-"))) (defmethod close-volume ((volume opened-luks-container)) -- cgit v1.2.3