site  contact  subhomenews

btrfs-progs with fscrypt take-2

March 20, 2024 — BarryK

I posted yesterday about compiling Josef Bacik's fscrypt branch of 'btrfs-progs':

There were some things that I didn't understand, and sent an inquiry email to Josef. Here is part of my email:

With ext4, "mkfs.ext4 -O encrypt,..." will enable fscrypt; however
"mkfs.btrfs -O list-all" does not show "encrypt" as an available

So that is my question, is it just the documentation that is lagging,
and "-O encrypt" will work?

And if so, how do I check? With ext4, can use "tune4fs -l ..." to list
features. I'm new to btrfs, not familiar with the tools.

And here is part of Josef's reply:

You need to make sure when you're configuring btrfs-progs you use

./configure --enable-experimental

so you get the encryption support. However you don't need that to
enable encryption. If you just use the normal fscrypt tools to enable
encryption it'll work properly, we don't do anything specific at mkfs
time like ext4 does, we do it all live.

Good. I have recompiled 'btrfs-progs' and updated the PET. Also recompiled it statically in OE for use of the utilities in the initrd.  

Tags: quirky