Hacker News new | past | comments | ask | show | jobs | submit | staff3203's comments login

On my system, I used `tpm2-measure-pcr=yes` in `/etc/crypttab.initramfs`, then used `--tpm2-pcrs=0+2+7+15:sha256=0000000000000000000000000000000000000000000000000000000000000000` with `systemd-cryptenroll`.

As soon as a volume is decrypted, initrd will write `volume-key` to PCR 15, so any further executables can no longer access the data stored in the TPM.


Yes, that seems a good extra level of defense. Allow unsealing only once. We extend a PCR with random data.

This is what Bitlocker does. There was a recent article about it.

This is great if you only have a single disk, but if you have multiple encrypted disks that are unlocked in the initrd this way, then if you can gain control flow by faking data on the last decrypted disk you can still gain access to all the previously unlocked partitions.

Of course you cannot unseal the secret from the TPM anymore.


If you have tpm encryption on your boot disk, then you can simply store decryption keys for your otyer disks on it.

What to do for a single root fs spanned over 2 encrypted partitions on 2 separate disks?

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: