Red Hat Bugzilla – Bug 1297273
MokManager.efi fails to enroll MOK public keys at boot.
Last modified: 2017-03-13 11:25:48 EDT
Description of problem:
MokManager.efi fails to enroll public keys added with "mokutil --import key.der".
Mokmanager.efi ask to import the key after reboot, but key is not imported anyway.
Version-Release number of selected component (if applicable):
$ rpm -q shim mokutil openssl
Always, several tries with different keys has been performed.
Steps to Reproduce:
1. Generate a key pair with openssl
2. Import key with "mokutil --import"
3. Verify key is pending to import looking at /sys/firmware/efi/efivars/MokNew-XXX...
5. Use MokManager.efi interface to import pending key.
7. Use "keyctl list %:.system_keyring" to view current public keys in keyring.
Four public keys listed
# keyctl list %:.system_keyring
4 keys in keyring:
893647049: ---lswrv 0 0 asymmetric: Fedora kernel signing key: 89ceaf5380b1d1504056cb00aa3c46346beb2e05
49271380: ---lswrv 0 0 asymmetric: Fedora Secure Boot CA: fde32599c2d61db1bf5807335d7b20e4cd963b42
164585263: ---lswrv 0 0 asymmetric: Microsoft Corporation UEFI CA 2011: 13adbf4309bd82709c8cd54f316ed522988a1bd4
757346961: ---lswrv 0 0 asymmetric: Microsoft Windows Production PCA 2011: a92902398e16c49778cd90f99e4f9ae17c55af53
Five public keys listed, the previous ones plus the one we wish to import.
Hardware HP Zbook 15 G2, latest firmware:
# dmidecode |grep 'BIOS Rev'
BIOS Revision: 1.12
As no MOK key could be imported, no custom module can be loaded into kernel with secureboot enabled until this is solved.
# tree /boot/efi/
│ ├── BOOT
│ │ ├── BOOTX64.EFI
│ │ └── fallback.efi
│ └── fedora
│ ├── BOOT.CSV
│ ├── fonts
│ │ └── unicode.pf2
│ ├── fw
│ ├── fwupx64.efi
│ ├── gcdx64.efi
│ ├── grub.cfg
│ ├── grubenv
│ ├── grubx64.efi
│ ├── MokManager.efi
│ ├── shim.efi
│ └── shim-fedora.efi
I'm having the same issue. Cant import keys using mokutil --import.
Seems pretty much all functions of mokutil are not working.
kernel = 4.5.6-200.fc23.x86_64
This message is a reminder that Fedora 23 is nearing its end of life.
Approximately 4 (four) weeks from now Fedora will stop maintaining
and issuing updates for Fedora 23. It is Fedora's policy to close all
bug reports from releases that are no longer maintained. At that time
this bug will be closed as EOL if it remains open with a Fedora 'version'
Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version'
to a later Fedora version.
Thank you for reporting this issue and we are sorry that we were not
able to fix it before Fedora 23 is end of life. If you would still like
to see this bug fixed and are able to reproduce it against a later version
of Fedora, you are encouraged change the 'version' to a later Fedora
version prior this bug is closed as described in the policy above.
Although we aim to fix as many bugs as possible during every release's
lifetime, sometimes those efforts are overtaken by events. Often a
more recent Fedora release includes newer upstream software that fixes
bugs or makes them obsolete.
Fedora 23 changed to end-of-life (EOL) status on 2016-12-20. Fedora 23 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.
If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
Thank you for reporting this bug and we are sorry it could not be fixed.
mokutil --import public_key.der
input password again:
Failed to enroll new keys
This is with fedora 25.
Still present in fedora 25.
duplicate of 1406868
(In reply to Knut J BJuland from comment #7)
> duplicate of 1406868
1406868 could be a duplicate of this, but not the way around as this predates the other in about a year.