Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TPM event log #7752

Open
Tracked by #9249
frezbo opened this issue Sep 13, 2023 · 7 comments
Open
Tracked by #9249

TPM event log #7752

frezbo opened this issue Sep 13, 2023 · 7 comments

Comments

@frezbo
Copy link
Member

frezbo commented Sep 13, 2023

From the AsGO 2023 conference and systemd systemd/systemd#29004 we need to log the TPM events to prove we did extend PCR and also for future work for remote attestation and systemd-pcrlock functionality for Talos to support kexec

Ref: systemd/systemd#28891

@dsseng
Copy link
Member

dsseng commented Feb 22, 2024

Currently working on this: added logging of PCR extensions into the main system log, currently working on parsing /sys/kernel/security/tpm0/binary_bios_measurements to get prior measurements from firmware and bootloader. What should be done to this data then?

@frezbo
Copy link
Member Author

frezbo commented Feb 23, 2024

Currently working on this: added logging of PCR extensions into the main system log, currently working on parsing /sys/kernel/security/tpm0/binary_bios_measurements to get prior measurements from firmware and bootloader. What should be done to this data then?

We were holding onto this until we have selinux support, the long term plan is to do something similar to systemd-pcrlock to support disk unlock when firmware updates might change PCR 7 data, also maybe tie to more PCR values for disk encryption

@frezbo
Copy link
Member Author

frezbo commented Feb 23, 2024

Currently working on this: added logging of PCR extensions into the main system log

This needs to be a separate log file (hence waiting on landing selinux so only machined can touch the file), but i guess we can accept the PR

@dsseng
Copy link
Member

dsseng commented Feb 23, 2024

to support disk unlock when firmware updates might change PCR 7 data, also maybe tie to more PCR values for disk encryption

Is the goal like https://github.com/okirch/pcr-oracle? Unsure how would that work with firmware update. My openSUSE systems required LUKS key to boot after a firmware update. Maybe we could predict the FW PCR value if the image to be loaded is in a raw format or has PCR values listed.

@frezbo
Copy link
Member Author

frezbo commented Feb 23, 2024

to support disk unlock when firmware updates might change PCR 7 data, also maybe tie to more PCR values for disk encryption

Is the goal like https://github.com/okirch/pcr-oracle? Unsure how would that work with firmware update. My openSUSE systems required LUKS key to boot after a firmware update. Maybe we could predict the FW PCR value if the image to be loaded is in a raw format or has PCR values listed.

yeh, kind of similar, also this would really help once it lands fwupd/fwupd#6318

@dsseng
Copy link
Member

dsseng commented Feb 23, 2024

Well, should be workable. Not sure how would that work if new firmware, for example, changes the way it hashes NVRAM records or something else like Secure Boot data, but that shouldn't change at least on minor bugfix updates

Copy link

This issue is stale because it has been open 180 days with no activity. Remove stale label or comment or this will be closed in 7 days.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants