Skip to content

Support for dm-verity volumes that have their root hash measured via the TPM2 #7

@RaitoBezarius

Description

@RaitoBezarius

Certain setups relies heavily on remote attestation and ensure that everything relevant gets measured, in these scenarios, a goal is to minimize the number of signing keys (and get them to zero successfully, we build the kernel with a key that we throw after the build to lock the kernel).

In these setups, a welcome addition would be to enable IPE but IPE requires to write a (signed) policy that knows the dm-verity hash in advance. It would be great if instead we could rely on the implicit trust that stems from having a dm-verity volume that had its root hash measured (via the kernel command line measurement for example), something like:

DEFAULT action=ALLOW
DEFAULT op=EXECUTE action=DENY
op=EXECUTE boot_verified=TRUE action=ALLOW
op=KMODULE boot_verified=TRUE action=ALLOW
op=EXECUTE dmverity_cmdline_measured=TRUE action=ALLOW
op=KMODULE dmverity_cmdline_measured=TRUE action=ALLOW

This way, we wouldn't need to specify any hash and such a policy can be inherently trusted if measurements of initramfs and dm-verity volumes takes place, we could bake it into the kernel directly without having to ship it separately (and therefore sign it).

I think I can send a patch to do this but the problem is how to detect that a root hash has been measured. I feel like pulling out the kernel command line to see if there's roothash=$root_hash is a bit weird.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions