Luks encrpted disk with a blake2b checksumed btrfs fs is better than cryptsetup --integrity option ??
[email protected] Fri, 20 Jun 2025 18:58:48 +0000
| Newsgroups | dev.linux.lists.cryptsetup |
|---|---|
| Message-ID | <s2jv1MM1-zykYSRK4j97B_Oz8nW5eHLcm4JTd55UqrAJOVkrvsFhD274SNM_XsvedduP9LKWtjJdGNl5ZGd9b2eh9ihW4j4-2xMGlbJpBs8=@proton.me> |
Here is a quote from the dev in the gitlab issue : > If you are using AES-XTS and a cryptographic hash for the checksum (such as SHA2 or Blake2b), this should (barring filesystem bugs) provide integrity protection. In fact, it will provide vastly stronger protection than dm-integrity can, because it does protect against replay attacks due to the CoW nature of the filesystem: my understanding (which could be mistaken!) is that the whole filesystem is a Merkle tree rooted at the superblock. At least theoretically, dm-crypt + ZFS or BTRFS + SHA-2 or Blake2b hashes should be safe against an outright malicious block device. By “should”, I mean that I would consider it to be a security vulnerability if the attacker could do anything other than roll the entire device back to an earlier version. Of course, the ZFS, BTRFS, and dm-crypt developers may disagree