fs-verity: Native File-based Authenticity
summary
File-level authenticated hashing that behaves like DM-Verity but for individual read-only files: it appends a per-file Merkle tree plus a small descriptor to the file, written by userspace with fsverity_setup, then flips the fsverity bit in the inode to make the file read-only. Kernel code (ext4 and f2fs supported) verifies blocks on demand via hooked readpages, exposes the measurement via fsverity measure ioctl, disallows direct-IO, supports optional PKCS7 signatures and fscrypt, costs ~1/120 extra metadata for large files with CPU hashing overhead on low-end devices, and has upstream patches pending.
AI-written summary · about
chapters (26)
- 0:00Introduction
- 1:02Background
- 1:25Outline
- 1:44Hash
- 3:18Firmware
- 3:46Dictionary structures
- 4:21IO errors
- 5:55Android verified boot
- 6:50DM Verity
- 8:24Partial disk authentication
- 9:25fsverity
- 10:36contents of a file
- 12:14DMVerde
- 12:50Data Fields
- 13:18File Measurement
- 14:07fsparity
- 15:12Verification
- 16:47File measurements
- 22:21Performance impacts
- 22:58Smaller files
- 23:53Performance
- 24:54Power consumption
- 25:48Delayed verification
- 27:38Forward error correction
- 28:18Protecting against a man on the disc
- 30:15attestation
related talks
22mBPF_LSM + fsverity for Binary Authorization
35mIMA Policy Support for fs-verity: A Win-win for IMA & fs-verity
34mAuthenticated and Encrypted Storage on Embedded Linux
33mEncryption for filesystems with advanced features new fscrypt functionality
26mIntegrity
01h 05mImmutable and Stateless Systems with systemd
36mOverview and Recent Developments: Linux Integrity
32mSecurity Features for UBIFS
