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

Image signature/verification fails if PK or KEK are missing #356

Open
imaspeer opened this issue Aug 10, 2024 · 0 comments
Open

Image signature/verification fails if PK or KEK are missing #356

imaspeer opened this issue Aug 10, 2024 · 0 comments
Labels
enhancement New feature or request

Comments

@imaspeer
Copy link

After updating to the latest version (0.15.4) and running sbctl setup --migrate as instructed, if the PK and/or KEK is not present, the list-files, sign, sign-all and verify operations fail with /var/lib/sbctl/keys/KEK/KEK.key: no such file or directory (and, in order, KEK/KEK.pem, PK/PK.key and PK/PK.pem if they are also missing).

There is no reason for the KEK, let alone the PK, to be present on the system during regular operation, or to even be in possession of a local administrator. Signing an image only requires the db key, and verifying the signatures only the public part of it.

In fact, the files only need to exist and be valid keys (empty files lead to a SEGV in backend.GetBackendType), not necessarily be the actual enrolled PK and KEK (e.g. copying the db key over in all three locations works), for sign / sign-all to succeed and produce good signatures ; demonstrating it does not actually need these keys.

These operations should therefore not require the PK and KEK to be present in the filesystem.

@Foxboron Foxboron added the enhancement New feature or request label Aug 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants