From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from gate001.proxmox.com (gate001.proxmox.com [IPv6:2a0f:8001:1:32::40]) by lore.proxmox.com (Postfix) with ESMTPS id B2ECA1FF0B3 for ; Thu, 26 Nov 2026 17:05:44 +0100 (CET) Received: from gate001.proxmox.com (localhost.localdomain [127.0.0.1]) by gate001.proxmox.com (Proxmox) with ESMTP id 6CB1521709; Thu, 26 Nov 2026 17:05:43 +0100 (CET) Mime-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=UTF-8 Date: Thu, 26 Nov 2026 17:05:36 +0100 Message-Id: Subject: Re: [PATCH installer 1/5] install: encrypt the system disks with LUKS2 or native ZFS encryption To: "Thomas Lamprecht" , X-Mailer: aerc 0.20.0 References: <20261117234330.801935-1-t.lamprecht@proxmox.com> <20261117234330.801935-3-t.lamprecht@proxmox.com> In-Reply-To: <20261117234330.801935-3-t.lamprecht@proxmox.com> From: "Shannon Sterz" X-Bm-Milter-Handled: 55990f41-d878-4baa-be0a-ee34c49e34d2 X-Bm-Transport-Timestamp: 1795709136834 X-SPAM-LEVEL: Spam detection results: 0 AWL 0.530 Adjusted score from AWL reputation of From: address DMARC_MISSING 0.1 Missing DMARC policy KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment (newer systems) RCVD_IN_DNSWL_MED -2.3 Sender listed at https://www.dnswl.org/, medium trust SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record Message-ID-Hash: U4KM5MPA3Z77BH2TSLINSE5MKDMLXYSZ X-Message-ID-Hash: U4KM5MPA3Z77BH2TSLINSE5MKDMLXYSZ X-MailFrom: s.sterz@proxmox.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.10 Precedence: list List-Id: Proxmox VE development discussion List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: On Wed Nov 18, 2026 at 12:42 AM CET, Thomas Lamprecht wrote: -->8 snip 8<-- > @@ -216,7 +270,24 @@ sub zfs_create_rpool { > my $cmd =3D "zpool create -f -o cachefile=3Dnone"; > $cmd .=3D " -o ashift=3D$zfs_opts->{ashift}" if defined($zfs_opts->{= ashift}); > > - syscmd("$cmd $pool_name $vdev") =3D=3D 0 || die "unable to create zf= s root pool\n"; > + if (my $enc =3D Proxmox::Install::Config::get_encryption()) { > + # the pool is the encryption root, so all datasets inherit its k= ey > + with_secret_keyfile( > + $enc->{passphrase}, > + sub { > + my ($keyfile) =3D @_; > + my $opts =3D "-O encryption=3Daes-256-gcm -O keyformat= =3Dpassphrase" > + . " -O keylocation=3Dfile://$keyfile"; Small question: Since above you try to control most of the default settings for cryptsetup, should we here also set `pbkdf2iters`? By default zfs seems to use 350 000 iterations (`man zfsprops`), but OWASP recommends at least 600 000 iterations [1]. [1]: https://cheatsheetseries.owasp.org/cheatsheets/Password_Storage_Cheat_= Sheet.html -->8 snip 8<--