Problem loading X.509 certificate -22

Hallo zusammen,

zuerst einmal ein anderer Beitrag mit exakt dem selben Problem:

Allerdings finde ich, dass das ignorieren von Zertifikatsfehlern oder das Löschen der Zertifikate, gerade bei Secure Boot eher nicht so gut ist und würde gerne die eigentliche Ursache angehen (sofern es möglich ist).

Zur Fehlermeldung:

kernel: integrity: Loading X.509 certificate: UEFI:db
kernel: integrity: Problem loading X.509 certificate -22
kernel: integrity: Error adding keys to platform keyring UEFI:db

Die Fehler konnte ich auch (wie in dem oben verlinkten Beitrag) auf zwei Zertifikate von Gigabyte eingrenzen. Allerdings sind es andere Zertifikate als in dem verlinkten Beitrag.

Die Zertifikate (Key 4 und Key 5):

[key 4]
Owner: e58e05e2-5c43-4ef7-880b-3f06734eb36f
SHA1 Fingerprint: 4a:9c:f1:d4:94:7b:8c:df:24:06:91:cf:fc:c9:a6:63:7e:ca:4c:d0
Certificate:
    Data:
        Version: 3 (0x2)
        Serial Number:
            34:cc:1b:4e:f3:3d:fd:96:48:bb:8c:a6:8e:67:1d:78
        Signature Algorithm: sha256WithRSAEncryption
        Issuer: CN=GIGABYTE
        Validity
            Not Before: Sep 30 01:55:16 2022 GMT
            Not After : Sep 30 01:55:15 2027 GMT
        Subject: CN=GIGABYTE
        Subject Public Key Info:
            Public Key Algorithm: rsaEncryption
                Public-Key: (2048 bit)
                Modulus:
                    00:c1:21:24:5c:03:a6:80:db:08:fb:35:2a:47:d7:
                    f7:9a:7b:c8:6d:dd:61:e3:c9:e5:29:dc:03:b3:5e:
                    1f:b6:c5:1c:93:c8:d2:8c:db:c5:9c:b0:90:00:9c:
                    73:31:b7:8c:a8:62:6e:76:48:d4:32:4d:02:b3:b7:
                    04:35:e2:f8:d5:26:4a:13:7d:6c:71:79:a1:00:9b:
                    16:cd:33:0e:37:3a:e2:6b:69:5c:88:2a:20:aa:10:
                    36:d2:e0:e5:57:15:67:bf:9a:32:88:4d:db:9f:6b:
                    5b:57:f3:20:c9:93:0d:54:20:38:8f:f6:23:4a:af:
                    07:1f:4b:ed:7c:6f:dc:d4:01:7e:39:e5:7a:74:f4:
                    53:3d:3d:b8:c5:7a:5b:91:e7:65:23:cd:77:fd:1c:
                    32:93:53:ca:6c:2f:1e:47:5c:c1:42:87:58:29:ae:
                    77:d2:95:5e:fd:87:9f:be:9a:ac:fc:b5:dc:e3:d8:
                    6f:39:f0:b5:4c:5b:cd:94:6e:11:61:86:77:96:8a:
                    d6:f7:ca:08:18:0b:14:4d:4c:6d:e3:68:6a:c4:d4:
                    48:9a:10:6d:c8:9b:a6:80:59:fc:c8:61:6f:d4:18:
                    25:2b:8c:94:e2:f9:98:39:cc:67:ba:9e:a1:84:45:
                    3b:76:62:de:68:22:17:33:af:f9:d4:fb:44:9e:1b:
                    9f:6d
                Exponent: 65537 (0x10001)
        X509v3 extensions:
            X509v3 Basic Constraints: critical
                CA:TRUE
            2.5.29.1: 
                0;..kJ..@;}1."B..p....0.1.0...U....GIGABYTE..b..!&...LK?....a
    Signature Algorithm: sha256WithRSAEncryption
    Signature Value:
        0f:28:db:0b:bd:7d:1f:87:95:67:1d:b3:10:1f:93:01:cc:d2:
        a5:0e:03:66:32:1e:3b:1a:d4:5f:be:c5:33:16:d1:cb:68:1e:
        b4:df:35:a5:04:53:5a:3f:79:3b:b5:4d:88:c4:60:57:5e:a6:
        c1:88:41:76:c8:20:69:22:9d:c7:09:73:e2:bf:43:6e:04:f7:
        3a:2e:fe:78:66:7f:5b:30:99:c1:fc:15:ee:ce:cb:7c:49:94:
        b8:9c:54:cb:17:51:e4:92:4c:56:6b:6c:fc:16:21:87:0a:4b:
        7c:3b:dd:f6:d9:03:37:ff:12:e3:f5:8f:36:02:c5:e1:fb:42:
        56:62:36:3b:ff:fe:ec:c8:09:79:0a:4c:b7:49:2c:40:5c:db:
        1a:cc:65:81:6b:4a:e7:d9:6f:c5:c5:1f:6e:f2:db:1e:a1:f9:
        16:13:37:33:f0:58:11:8a:40:cb:88:43:f7:fd:fe:7a:74:40:
        fb:07:b3:21:70:09:17:0b:99:35:18:2d:07:41:88:f1:ec:a1:
        49:b7:82:78:b6:52:e1:8d:29:e5:7f:c6:a9:27:7f:b4:f2:bf:
        bc:ff:1a:0c:e4:72:15:58:e9:7a:9b:49:4a:bb:f0:a8:9d:69:
        d1:5f:2a:45:24:d2:c8:90:ba:c9:70:cb:92:87:96:53:eb:19:
        67:60:f9:b7:0a:d3:45:a5:59:5f:5f:8e:ec:ac:37:4e:d9:5e:
        fa:4b:0c:38:1d:89:58:d6:a8:d5:04:21:85:a9:be:92:73:b9:
        c8:ad:4d:6d:a6:de:62:7b:f0:c8:e9:74:d2:34:ab:5a:e0:16:
        88:c5:6f:20:7e:fa:62:d5:59:e1:05:aa:91:3f:15:89:dc:82:
        87:74:48:11:bc:b8:b3:68:5d:ec:a3:db:eb:60:f6:da:64:6b:
        fa:99:1c:59:37:8b:51:49:ea:07:46:d5:0a:c5:c6:75:e3:6d:
        a2:7e:9e:12:95:e0:23:8f:03:5f:21:a2:3d:79:ec:15:98:c0:
        ba:b0:8a:36:8d:ef:48:eb:e9:ca:e8:51:0d:99:d0:b3:b5:b1:
        d2:24:47:40:22:f9:d6:cf:fd:19:ae:2d:e5:c3:07:de:b3:28:
        31:b0:a4:97:23:2c:95:b4:c1:1b:0a:6c:d6:b1:bf:63:f7:b4:
        37:b5:19:1d:d3:63:d4:af:54:e7:3f:20:7c:ad:00:be:41:c0:
        bd:66:e9:de:e4:79:c2:b7:f0:6c:33:f9:de:29:6a:8c:f7:03:
        71:a9:62:cd:20:8b:3b:b5:42:73:41:ba:05:9f:c4:16:4b:53:
        ce:00:c4:a0:55:20:47:f2:80:c3:a8:42:00:b9:22:d1:78:82:
        72:90:1c:8e:53:62:30:f8

[key 5]
Owner: e58e05e2-5c43-4ef7-880b-3f06734eb36f
SHA1 Fingerprint: 09:3f:ce:c2:c9:aa:a7:82:37:62:10:dc:e3:fc:dc:da:ec:fb:a2:5e
Certificate:
    Data:
        Version: 3 (0x2)
        Serial Number:
             (Negative)77:75:9b:f8:5a:e4:c5:67:b6:2d:71:d6:f3:d2:4d:a4
        Signature Algorithm: sha256WithRSAEncryption
        Issuer: CN=GIGABYTE
        Validity
            Not Before: Sep  5 06:42:23 2023 GMT
            Not After : Sep  5 06:42:22 2053 GMT
        Subject: CN=GIGABYTE
        Subject Public Key Info:
            Public Key Algorithm: rsaEncryption
                Public-Key: (4096 bit)
                Modulus:
                    00:d3:85:69:b1:88:ba:89:21:f9:9b:05:82:ae:b4:
                    ff:48:f5:28:a7:55:49:18:4a:ee:63:e6:43:e8:69:
                    8d:6e:5e:1a:7f:df:cc:7b:1b:54:67:f2:2c:3d:ef:
                    10:54:8b:92:7a:ed:df:e4:7e:66:6e:67:88:66:94:
                    30:6e:60:75:61:52:86:58:e9:6e:fe:b3:37:f9:ef:
                    f5:eb:3c:c6:05:a1:dc:60:bc:05:50:e5:86:ca:56:
                    be:66:b7:83:bb:e5:0f:4c:c4:57:5c:9c:78:07:00:
                    79:49:ac:6e:56:6e:df:9c:d0:8a:0e:e2:23:2f:b8:
                    db:0e:77:cb:73:50:8f:98:bd:2d:2c:7d:ea:7e:9b:
                    7d:71:ec:03:90:83:97:d1:91:97:91:99:5b:31:5d:
                    83:86:87:43:57:1c:21:a6:2c:1f:82:27:82:ab:cd:
                    25:5a:b3:15:f3:c0:f9:cd:78:64:5c:24:71:20:bb:
                    1d:48:02:22:35:43:91:38:24:d6:11:5c:92:1e:76:
                    17:ca:07:8c:2e:50:db:6a:e0:b4:4c:ee:ed:56:76:
                    10:47:a4:e2:8c:0f:dd:f8:72:11:bf:f5:21:c0:0e:
                    28:ee:b9:d3:88:32:20:cc:ff:df:41:dd:f4:b5:04:
                    6e:a5:e6:c2:02:42:39:9c:27:fe:b7:f7:8c:a8:ed:
                    3b:a3:3d:b3:25:e3:8f:68:01:a1:80:ef:af:5a:5d:
                    ca:7f:8b:c8:55:82:e9:fa:fa:03:95:9b:2c:f2:c1:
                    99:11:65:99:20:98:6a:dd:53:70:c2:a6:f6:82:e5:
                    ec:59:34:a4:c2:1d:d9:a5:31:e5:3d:13:09:9f:7b:
                    21:28:e2:c6:75:bd:71:ef:dc:78:19:3c:00:82:2d:
                    04:47:c5:7d:bd:7f:bb:1d:b5:f2:6b:19:14:de:c3:
                    e2:07:c8:fb:4b:8f:15:86:cd:37:bd:6a:0b:03:e4:
                    9d:37:5e:8c:c1:30:41:ea:37:a8:57:ce:5e:4b:01:
                    45:03:9d:b0:21:9f:e8:5f:be:a4:1b:df:0e:6e:64:
                    e6:89:cf:af:42:1c:de:0a:da:0a:a4:84:44:7e:47:
                    c3:86:71:a5:50:33:79:57:53:58:51:62:66:3b:98:
                    5a:72:50:45:5b:8a:fc:dc:99:f8:82:a0:fd:9d:a9:
                    3e:bd:b3:99:36:3c:2a:a9:c2:f9:94:9d:6c:11:69:
                    d2:ae:5b:f3:60:bf:1c:07:d7:6c:22:60:a0:4d:23:
                    ea:ac:a6:4d:fd:10:6c:fd:0d:db:b5:20:e5:f7:10:
                    2c:5c:31:d2:24:03:e6:0d:f4:93:ca:cc:f9:99:1f:
                    85:e3:41:c2:50:44:aa:80:51:2f:a6:36:34:c0:4c:
                    e0:5b:81
                Exponent: 65537 (0x10001)
        X509v3 extensions:
            2.5.29.1: 
                0;..eKf..Mv.))O....F..0.1.0...U....GIGABYTE....W.i...N.'V-..l
    Signature Algorithm: sha256WithRSAEncryption
    Signature Value:
        d3:fc:01:26:26:03:dd:a4:50:c8:03:b0:6f:26:a2:0f:d8:0d:
        f1:44:fb:60:c8:f6:60:81:71:68:7f:6c:61:ce:5c:6a:f3:cb:
        e7:30:86:07:2e:da:1d:4d:b8:36:87:0f:08:98:5c:0b:0d:67:
        cd:9e:62:26:23:35:51:78:32:d8:1a:a7:5e:24:11:c0:cf:03:
        30:af:54:c2:4d:27:ae:55:c3:da:cc:b4:4f:21:99:b5:8e:28:
        c8:7d:3a:5d:31:b2:2a:c3:63:47:46:88:27:d1:6f:6b:f2:18:
        b9:c9:b5:d2:72:96:f5:5c:df:d5:1b:01:d6:71:05:00:bb:ab:
        59:ac:b1:b4:13:d2:29:2d:f9:dd:20:dc:ff:4f:91:57:29:26:
        c9:56:d7:a0:50:22:3e:cb:59:34:c8:91:a3:ba:81:85:a5:00:
        c7:61:bf:45:38:b1:1c:83:24:af:9c:e7:25:9d:b3:89:5b:ab:
        a5:16:8f:26:96:fd:10:f7:a6:2d:a0:91:5d:40:8b:01:1d:54:
        45:05:2a:e6:02:af:d2:a6:62:4d:a4:34:e5:fc:a8:53:fa:4c:
        b8:80:85:63:b4:f2:27:2e:2e:cb:60:de:bf:94:d1:f6:b2:61:
        18:77:ba:ad:5a:89:5e:f1:76:ea:cd:49:d5:01:c2:6c:65:c1:
        d4:b6:51:bd

Auch Kleopatra gibt eine Meldung, dass die Zertifikate ungültig sind und nicht geladen werden können.

gpg: Keine gültigen OpenPGP-Daten gefunden.

Ich hatte mich auch schon an den Gigabyte Support gewendet, da ich der Meinung war und immer noch bin, dass das Zertifikat via BIOS-Update ausgetauscht werden muss und nicht über ein Update des OS (wenn ich ein Denkfehler habe, gerne korrigieren).
Die Aussagen vom Supoprt sind aber nur wenig Zielführend…

Hier Mal eine Zusammenfassung der Vorschläge:

  • Wir garantieren keine Kompatibilität mit Linux, und der Zertifikatsschlüssel wurde aktualisiert.
    → Meine Anmerkung: Secure Boot ist OS unabhängig und müsste in Windows auch zu Fehlern führen. Da bekommt man das halt nicht (so leicht) mit…

  • Bitte aktualisieren Sie das BIOS auf Version F40a mit Q-Flash Plus, entfernen Sie anschließend die Linux-OS-Festplatte, installieren Sie die Windows-11-OS-Festplatte und prüfen Sie danach, ob das Problem weiterhin besteht.
    → Meine Anmerkung: BIOS habe ich aktualisiert, allerdings waren die gleichen Zertifikate im Speicher… (gleicher Fingerprint) und als Lösung Windows zu nutzen ist auch wenig hilfreich…

  • Bitte prüfen Sie, ob das Problem weiterhin besteht, wenn Sie Secure Boot im BIOS aktivieren.
    → Meine Anmerkung: Genau dadurch ist es ja aufgefallen…

  • Alternativ können Sie sich für Unterstützung auch an Ubuntu wenden.
    → Nutze ich auch nicht… :smiley: den Link von oben hatte ich da auch bereits an den Support weitergeleitet.

Zuletzt kam folgende Aussage:

Wir haben den Secure-Boot-Schlüssel im Jahr 2024 aktualisiert.
Allerdings sind die Zertifikate in der db ja von 2022 (Not Before: Sep 30 01:55:16 2022 GMT) und 2023 (Not Before: Sep 5 06:42:23 2023 GMT).

Liege ich falsch, wenn hier der Hersteller gültige Zertifikate per BIOS Update liefern muss? habe ich einen Denkfehler?
Hat jemand eine Idee, was man noch tun könnte, außer Zertifikate zu löschen oder die Fehler zu ignorieren? :smiley:

Viele Grüße

Meiner Meinung nach ist Key 4 der UEFI Platform Key für SecureBoot (und Key 5 vermutlich der KEK). Das ist sozusagen der offizielle Start in der SecureBoot Vertrauenskette für Gigabyte Boards der muss oder besser darf nur vom Hersteller Gigabyte kommen. Details zu den ganzen Secure Boot Keys Krempel finden sich ganz gut beschrieben z.B. hier https://docs.oracle.com/en/operating-systems/oracle-linux/9/secure-boot/sboot-OverviewofSecureBoot.html#sb-implementation.
Ich habe kein leider kein Gigabyte Board um die Keys zu vergleichen. Die entsprechenden PK und KEK für mein ASUS Board werden bei mir beim Boot in den Kernel (Leap 16.0) geladen:

cat /proc/keys |grep  ASUS
04881a7f I------     1 perm 1f010000     0     0 asymmetri ASUSTeK Notebook SW Key Certificate: b8e581e4df77a5bb4282d5ccfc00c071: X509.rsa []
299d7bf3 I------     1 perm 1f010000     0     0 asymmetri ASUSTeK MotherBoard SW Key Certificate: da83b990422ebc8c441f8d8b039a65a2: X509.rsa []

Ich denke nicht das die für den Linux Kernel wirklich relevant sind. Aber für das Gesamte SecureBoot System natürlich schon siehe Infos im Link. Also ich würde die nicht löschen.
Wie hast du denn versucht diese Keys mit gpg zu checken ?

hi, danke dir für die Rückmeldung.
Nein, das sind beides Keys aus der “db”. Die Schlüssel sind dort nummeriert (Key 1 - Key X).

hier Mal ein Auszug auf pk und kek.

mokutil --kek --list-enrolled 
[key 3]
Owner: e58e05e2-5c43-4ef7-880b-3f06734eb36f
SHA1 Fingerprint: e2:62:7d:09:ed:6a:56:c4:3c:81:ef:f7:0b:ca:8c:bb:00:f6:6b:8a
Certificate:
    Data:
        Version: 3 (0x2)
        Serial Number:
            77:09:7d:5f:28:05:a3:84:4b:6f:ca:bb:23:08:fd:69
        Signature Algorithm: sha256WithRSAEncryption
        Issuer: CN=GIGABYTE CA
        Validity
            Not Before: Sep  5 06:39:55 2023 GMT
            Not After : Sep  5 06:39:54 2053 GMT
        Subject: CN=GIGABYTE
        Subject Public Key Info:
            Public Key Algorithm: rsaEncryption
                Public-Key: (2048 bit)
                Modulus:
                    00:ab:20:e6:f5:70:26:18:41:4a:13:88:7c:d8:b6:
                    63:12:78:96:6d:8c:f2:3b:5f:6b:25:30:88:41:6f:
                    21:4a:7c:99:e2:9d:01:91:f7:bc:ba:c9:2f:0f:11:
                    37:9b:de:8f:54:de:3f:c4:a7:d0:40:46:34:f7:df:
                    dd:6a:f3:f3:33:25:d4:8d:d3:35:a0:5f:e7:44:be:
                    7a:1c:e6:03:74:c1:34:0e:4e:36:25:5a:a8:e9:f7:
                    e3:79:51:8a:de:a5:2e:4c:34:10:b9:b5:8d:b0:d3:
                    36:f9:51:0a:05:1b:7e:0e:7c:b0:4e:59:84:f9:3e:
                    b6:91:df:4c:f6:65:80:99:98:fb:9a:c4:f8:74:42:
                    6c:2f:e5:90:73:3d:c8:d4:da:88:14:e8:72:bf:d2:
                    b5:8f:14:5c:07:57:f2:4c:db:aa:57:da:1d:1f:d7:
                    a1:09:f7:15:82:55:c2:3d:30:93:b6:99:76:87:7c:
                    2a:6d:c5:84:30:66:0e:87:da:c9:3a:cf:20:98:8f:
                    52:97:5b:89:10:dd:5f:51:2d:3c:53:d8:63:55:53:
                    65:a5:86:35:47:1e:ad:f9:1c:09:01:85:a9:f5:17:
                    37:2e:3c:41:93:86:57:00:91:b7:8e:5b:58:5f:12:
                    aa:55:ab:5a:b0:61:ff:5a:c9:ce:d3:eb:f7:83:a3:
                    ad:61
                Exponent: 65537 (0x10001)
        X509v3 extensions:
            2.5.29.1: 
GIGABYTE Root....*.9.l.G..yr....^..3..0.1.0...U...
    Signature Algorithm: sha256WithRSAEncryption
    Signature Value:
        16:ab:8c:5a:2a:1d:fe:13:2b:50:a1:d2:43:fc:55:97:ee:76:
        a5:2e:a2:ca:61:a2:1a:f2:0f:92:08:3b:60:bd:bc:c1:33:83:
        dd:35:74:db:b4:72:56:51:4b:92:de:d7:b4:3f:5b:81:04:51:
        ca:ad:a3:9b:1c:d2:1f:fd:e2:81:4d:2d:c1:0b:d7:c6:c1:f0:
        3d:d3:25:eb:83:92:41:bb:10:09:49:8f:42:f5:c3:25:54:97:
        c3:85:e0:f7:01:c8:d0:39:28:b3:37:f4:92:1c:44:17:56:58:
        79:57:56:d0:be:a9:b1:18:6e:8b:b8:13:be:fb:1c:59:24:7b:
        0d:79:07:f9:54:f4:9c:ce:2c:f9:08:fd:4b:fd:96:56:11:0c:
        8c:5a:74:d3:53:24:c8:4a:b8:62:86:54:fc:75:b3:34:eb:26:
        9d:cc:d3:75:90:99:59:63:7c:f9:96:94:ca:b2:9a:8a:5d:da:
        54:02:19:73:0f:ff:c3:c5:ca:50:96:f1:61:b5:d9:7b:6b:5c:
        06:67:2d:0c:a8:9f:92:d6:ae:54:c6:a8:e2:b0:71:7f:7f:47:
        f6:50:78:c6:ac:87:05:e0:d2:3e:63:c7:ea:da:34:2d:92:ed:
        4c:74:c6:74:c4:77:05:68:b6:1b:0d:f2:90:d0:0b:8d:8d:12:
        aa:84:a9:d1
mokutil --pk --list-enrolled
[key 1]
Owner: e58e05e2-5c43-4ef7-880b-3f06734eb36f
SHA1 Fingerprint: fc:fc:53:70:49:ff:52:60:ef:60:b6:40:c1:8d:99:42:36:d6:02:80
Certificate:
    Data:
        Version: 3 (0x2)
        Serial Number:
             (Negative)42:39:8f:a9:21:78:81:7d:b8:53:96:63:fa:b0:11:bc
        Signature Algorithm: sha256WithRSAEncryption
        Issuer: CN=GIGABYTE
        Validity
            Not Before: Sep  5 06:37:57 2023 GMT
            Not After : Sep  5 06:37:56 2053 GMT
        Subject: CN=GIGABYTE
        Subject Public Key Info:
            Public Key Algorithm: rsaEncryption
                Public-Key: (2048 bit)
                Modulus:
                    00:da:d1:46:d6:48:2e:c8:09:1e:fe:e1:90:5c:d6:
                    3d:7e:4f:aa:74:cf:12:75:18:2a:85:6b:e0:f8:e0:
                    d8:b1:da:09:d5:15:28:c7:39:67:0c:7f:72:ae:8c:
                    69:5e:b6:6b:1a:5e:27:7a:9c:b4:93:a2:47:7a:52:
                    ff:dc:99:a0:b3:08:bd:bc:67:d9:2d:81:0e:64:84:
                    07:dd:ca:88:23:4f:3c:a7:86:e6:b1:ed:c9:cc:59:
                    e9:3c:9d:23:29:a6:69:1a:be:cd:e7:a1:ca:aa:88:
                    8d:40:08:b6:89:76:8f:8e:ce:86:72:ee:e8:8e:18:
                    32:24:e6:ec:e5:3f:22:76:cc:80:58:f0:a4:11:b7:
                    24:47:7b:af:dd:9f:5e:9c:50:42:3e:b3:00:a6:b0:
                    ab:56:1b:2c:38:be:91:25:1b:f6:06:09:7e:aa:87:
                    cf:51:0b:51:fd:20:16:82:16:91:8b:70:e5:7c:f2:
                    07:62:39:3e:e6:61:b9:84:73:97:58:33:b7:f0:d5:
                    7c:37:4d:53:af:9b:da:2d:4e:0e:82:6e:94:3c:4d:
                    5e:ac:3a:2d:ff:6c:b3:88:6b:16:a7:07:b1:97:3a:
                    3c:42:7e:b0:60:80:e5:40:d0:66:d5:8d:c8:e5:9f:
                    1a:46:5e:2f:9d:59:4b:de:f4:b1:46:32:29:52:81:
                    d8:d9
                Exponent: 65537 (0x10001)
        X509v3 extensions:
            2.5.29.1: 
                0;...W..........71....0.1.0...U....GIGABYTE....pV..~.G.i..O.D
    Signature Algorithm: sha256WithRSAEncryption
    Signature Value:
        8d:2a:30:87:c5:7c:e7:93:65:90:96:30:d5:a9:b2:29:00:56:
        58:7d:54:1e:86:73:d5:78:d4:f5:fe:4a:f1:f6:59:ab:1c:dc:
        c1:58:c9:2e:50:36:70:f2:60:95:04:5d:77:49:5b:17:e7:36:
        45:dd:80:b6:32:a2:5b:11:55:14:3c:62:7d:b2:3b:ab:4b:28:
        6f:b8:e8:69:fe:97:91:01:ea:61:a1:f8:5d:69:7f:ac:18:a0:
        8d:5f:a5:c6:55:24:4e:97:12:27:f8:d1:b6:e6:0e:44:f8:6f:
        fd:ff:b2:33:f8:cc:57:c8:39:01:b5:8f:1d:10:a1:7c:65:18:
        1f:b0:90:c4:ab:50:0f:59:b0:76:18:a0:44:a8:f6:b8:a1:2c:
        f3:65:0f:3b:1a:fa:23:39:4e:56:55:60:5b:cd:75:57:f8:90:
        19:de:fa:16:1c:a0:c7:fe:59:c8:dc:e0:07:70:d8:6a:29:32:
        28:db:12:ca:7c:c3:cc:40:d6:8a:79:f0:5f:b5:25:d1:dc:60:
        d9:45:82:a2:b4:e3:16:ee:fe:81:18:e8:49:90:96:a5:07:8a:
        0b:21:fe:fd:ae:d5:89:d0:4c:5f:e8:e5:ed:e7:63:f6:94:6e:
        69:43:fd:42:af:52:a5:c5:6a:37:cf:9f:52:db:49:dd:78:6c:
        c3:63:13:78

Die Schlüssel haben einen anderen Fingerprint.
Die PK und KEK Schlüssel lassen sich mit Kleopatra importieren, bekommen aber trotzdem den Status Vertrauenswürdigkeit: ungültig.

Zu meinem Punkt bzgl. Kleopatra

gpg: Keine gültigen OpenPGP-Daten gefunden.

Der Protokolleintrag tritt bei den Microsoft Zertifikaten auch auf, jedoch werden die Zertifikate erfolgreich importiert.

Du kannst die Zertifikate exportieren und diese dann z.B. mit Kleopatra öffnen bzw. importieren.

mokutil --db --export

Das anzeigen der Zertifikate habe ich mit folgendem Kommando gemacht (da müssten dann auch deine ASUS Zertifikate auftauchen):

mokutil --db --list-enrolled

Mir ist aufgefallen, dass alle Zertifikate bis auf das KEK folgenden Aussteller haben:

Issuer: CN=GIGABYTE

und das KEK folgenden:

Issuer: CN=GIGABYTE CA

gibts hier vlt Probleme mit der CA?

Ah den mokutil --export kannte ich noch nicht ich habe so was immer mit efi-readvar exportiert. Ja da hast du natürlich Recht die 2 ASUS Keys sind bei mir auch in der “db”.
Die -22 Meldung ist vielleicht nur ein Problem des Kernel ASN.1 Parser wenn in den Zertifikaten irgendwas nicht ganz Standard konform ist. Der Kernel Parser ist eher minimalistisch und x509 ASN.1 schon sehr komplex.
Man könnte den mokutil export mit openssl mal rein Syntaktisch checken

openssl  x509 -text -inform DER -in DB-0001.der -noout

bzw. checken ob

openssl asn1parse -in DB-0001.der -inform DER

Error oder Unknown in der Ausgabe enthält.

openssl  x509 -text -inform DER -in KEK-0003.der -noout

liefert die gleiche Ausgabe wie mokutil, nur das der Owner und der SHA1 Fingerprint fehlen.

Ausgabe zum KEK-Schlüssel

> openssl  x509 -text -inform DER -in KEK-0003.der -noout
Certificate:
    Data:
        Version: 3 (0x2)
        Serial Number:
            77:09:7d:5f:28:05:a3:84:4b:6f:ca:bb:23:08:fd:69
        Signature Algorithm: sha256WithRSAEncryption
        Issuer: CN=GIGABYTE CA
        Validity
            Not Before: Sep  5 06:39:55 2023 GMT
            Not After : Sep  5 06:39:54 2053 GMT
        Subject: CN=GIGABYTE
        Subject Public Key Info:
            Public Key Algorithm: rsaEncryption
                Public-Key: (2048 bit)
                Modulus:
                    00:ab:20:e6:f5:70:26:18:41:4a:13:88:7c:d8:b6:
                    63:12:78:96:6d:8c:f2:3b:5f:6b:25:30:88:41:6f:
                    21:4a:7c:99:e2:9d:01:91:f7:bc:ba:c9:2f:0f:11:
                    37:9b:de:8f:54:de:3f:c4:a7:d0:40:46:34:f7:df:
                    dd:6a:f3:f3:33:25:d4:8d:d3:35:a0:5f:e7:44:be:
                    7a:1c:e6:03:74:c1:34:0e:4e:36:25:5a:a8:e9:f7:
                    e3:79:51:8a:de:a5:2e:4c:34:10:b9:b5:8d:b0:d3:
                    36:f9:51:0a:05:1b:7e:0e:7c:b0:4e:59:84:f9:3e:
                    b6:91:df:4c:f6:65:80:99:98:fb:9a:c4:f8:74:42:
                    6c:2f:e5:90:73:3d:c8:d4:da:88:14:e8:72:bf:d2:
                    b5:8f:14:5c:07:57:f2:4c:db:aa:57:da:1d:1f:d7:
                    a1:09:f7:15:82:55:c2:3d:30:93:b6:99:76:87:7c:
                    2a:6d:c5:84:30:66:0e:87:da:c9:3a:cf:20:98:8f:
                    52:97:5b:89:10:dd:5f:51:2d:3c:53:d8:63:55:53:
                    65:a5:86:35:47:1e:ad:f9:1c:09:01:85:a9:f5:17:
                    37:2e:3c:41:93:86:57:00:91:b7:8e:5b:58:5f:12:
                    aa:55:ab:5a:b0:61:ff:5a:c9:ce:d3:eb:f7:83:a3:
                    ad:61
                Exponent: 65537 (0x10001)
        X509v3 extensions:
            2.5.29.1: 
GIGABYTE Root....*.9.l.G..yr....^..3..0.1.0...U...
    Signature Algorithm: sha256WithRSAEncryption
    Signature Value:
        16:ab:8c:5a:2a:1d:fe:13:2b:50:a1:d2:43:fc:55:97:ee:76:
        a5:2e:a2:ca:61:a2:1a:f2:0f:92:08:3b:60:bd:bc:c1:33:83:
        dd:35:74:db:b4:72:56:51:4b:92:de:d7:b4:3f:5b:81:04:51:
        ca:ad:a3:9b:1c:d2:1f:fd:e2:81:4d:2d:c1:0b:d7:c6:c1:f0:
        3d:d3:25:eb:83:92:41:bb:10:09:49:8f:42:f5:c3:25:54:97:
        c3:85:e0:f7:01:c8:d0:39:28:b3:37:f4:92:1c:44:17:56:58:
        79:57:56:d0:be:a9:b1:18:6e:8b:b8:13:be:fb:1c:59:24:7b:
        0d:79:07:f9:54:f4:9c:ce:2c:f9:08:fd:4b:fd:96:56:11:0c:
        8c:5a:74:d3:53:24:c8:4a:b8:62:86:54:fc:75:b3:34:eb:26:
        9d:cc:d3:75:90:99:59:63:7c:f9:96:94:ca:b2:9a:8a:5d:da:
        54:02:19:73:0f:ff:c3:c5:ca:50:96:f1:61:b5:d9:7b:6b:5c:
        06:67:2d:0c:a8:9f:92:d6:ae:54:c6:a8:e2:b0:71:7f:7f:47:
        f6:50:78:c6:ac:87:05:e0:d2:3e:63:c7:ea:da:34:2d:92:ed:
        4c:74:c6:74:c4:77:05:68:b6:1b:0d:f2:90:d0:0b:8d:8d:12:
        aa:84:a9:d1

Hier Mal die Ausgabe zu den jeweiligen Zertifikaten:
PK

> openssl asn1parse -in PK-0001.der -inform DER
    0:d=0  hl=4 l= 762 cons: SEQUENCE          
    4:d=1  hl=4 l= 482 cons: SEQUENCE          
    8:d=2  hl=2 l=   3 cons: cont [ 0 ]        
   10:d=3  hl=2 l=   1 prim: INTEGER           :02
   13:d=2  hl=2 l=  16 prim: INTEGER           :-42398FA92178817DB8539663FAB011BC
   31:d=2  hl=2 l=  13 cons: SEQUENCE          
   33:d=3  hl=2 l=   9 prim: OBJECT            :sha256WithRSAEncryption
   44:d=3  hl=2 l=   0 prim: NULL              
   46:d=2  hl=2 l=  19 cons: SEQUENCE          
   48:d=3  hl=2 l=  17 cons: SET               
   50:d=4  hl=2 l=  15 cons: SEQUENCE          
   52:d=5  hl=2 l=   3 prim: OBJECT            :commonName
   57:d=5  hl=2 l=   8 prim: PRINTABLESTRING   :GIGABYTE
   67:d=2  hl=2 l=  32 cons: SEQUENCE          
   69:d=3  hl=2 l=  13 prim: UTCTIME           :230905063757Z
   84:d=3  hl=2 l=  15 prim: GENERALIZEDTIME   :20530905063756Z
  101:d=2  hl=2 l=  19 cons: SEQUENCE          
  103:d=3  hl=2 l=  17 cons: SET               
  105:d=4  hl=2 l=  15 cons: SEQUENCE          
  107:d=5  hl=2 l=   3 prim: OBJECT            :commonName
  112:d=5  hl=2 l=   8 prim: PRINTABLESTRING   :GIGABYTE
  122:d=2  hl=4 l= 290 cons: SEQUENCE          
  126:d=3  hl=2 l=  13 cons: SEQUENCE          
  128:d=4  hl=2 l=   9 prim: OBJECT            :rsaEncryption
  139:d=4  hl=2 l=   0 prim: NULL              
  141:d=3  hl=4 l= 271 prim: BIT STRING        
  416:d=2  hl=2 l=  72 cons: cont [ 3 ]        
  418:d=3  hl=2 l=  70 cons: SEQUENCE          
  420:d=4  hl=2 l=  68 cons: SEQUENCE          
  422:d=5  hl=2 l=   3 prim: OBJECT            :2.5.29.1
  427:d=5  hl=2 l=  61 prim: OCTET STRING      [HEX DUMP]:303B801005571702E0B0AFD9138699933731F709A11530133111300F0603550403130847494741425954458210BDC67056DE877E8247AC699C054FEE44
  490:d=1  hl=2 l=  13 cons: SEQUENCE          
  492:d=2  hl=2 l=   9 prim: OBJECT            :sha256WithRSAEncryption
  503:d=2  hl=2 l=   0 prim: NULL              
  505:d=1  hl=4 l= 257 prim: BIT STRING 

KEK

> openssl asn1parse -in KEK-0003.der -inform DER
    0:d=0  hl=4 l= 770 cons: SEQUENCE          
    4:d=1  hl=4 l= 490 cons: SEQUENCE          
    8:d=2  hl=2 l=   3 cons: cont [ 0 ]        
   10:d=3  hl=2 l=   1 prim: INTEGER           :02
   13:d=2  hl=2 l=  16 prim: INTEGER           :77097D5F2805A3844B6FCABB2308FD69
   31:d=2  hl=2 l=  13 cons: SEQUENCE          
   33:d=3  hl=2 l=   9 prim: OBJECT            :sha256WithRSAEncryption
   44:d=3  hl=2 l=   0 prim: NULL              
   46:d=2  hl=2 l=  22 cons: SEQUENCE          
   48:d=3  hl=2 l=  20 cons: SET               
   50:d=4  hl=2 l=  18 cons: SEQUENCE          
   52:d=5  hl=2 l=   3 prim: OBJECT            :commonName
   57:d=5  hl=2 l=  11 prim: PRINTABLESTRING   :GIGABYTE CA
   70:d=2  hl=2 l=  32 cons: SEQUENCE          
   72:d=3  hl=2 l=  13 prim: UTCTIME           :230905063955Z
   87:d=3  hl=2 l=  15 prim: GENERALIZEDTIME   :20530905063954Z
  104:d=2  hl=2 l=  19 cons: SEQUENCE          
  106:d=3  hl=2 l=  17 cons: SET               
  108:d=4  hl=2 l=  15 cons: SEQUENCE          
  110:d=5  hl=2 l=   3 prim: OBJECT            :commonName
  115:d=5  hl=2 l=   8 prim: PRINTABLESTRING   :GIGABYTE
  125:d=2  hl=4 l= 290 cons: SEQUENCE          
  129:d=3  hl=2 l=  13 cons: SEQUENCE          
  131:d=4  hl=2 l=   9 prim: OBJECT            :rsaEncryption
  142:d=4  hl=2 l=   0 prim: NULL              
  144:d=3  hl=4 l= 271 prim: BIT STRING        
  419:d=2  hl=2 l=  77 cons: cont [ 3 ]        
  421:d=3  hl=2 l=  75 cons: SEQUENCE          
  423:d=4  hl=2 l=  73 cons: SEQUENCE          
  425:d=5  hl=2 l=   3 prim: OBJECT            :2.5.29.1
  430:d=5  hl=2 l=  66 prim: OCTET STRING      [HEX DUMP]:3040801045B1D1CF0C71C6848B1F3A965EC8B233A11A3018311630140603550403130D474947414259544520526F6F748210C3882AD639836C9647BB157972B8DB11
  498:d=1  hl=2 l=  13 cons: SEQUENCE          
  500:d=2  hl=2 l=   9 prim: OBJECT            :sha256WithRSAEncryption
  511:d=2  hl=2 l=   0 prim: NULL              
  513:d=1  hl=4 l= 257 prim: BIT STRING

DB Keys

> openssl asn1parse -in DB-0004.der -inform DER
    0:d=0  hl=4 l=1033 cons: SEQUENCE          
    4:d=1  hl=4 l= 497 cons: SEQUENCE          
    8:d=2  hl=2 l=   3 cons: cont [ 0 ]        
   10:d=3  hl=2 l=   1 prim: INTEGER           :02
   13:d=2  hl=2 l=  16 prim: INTEGER           :34CC1B4EF33DFD9648BB8CA68E671D78
   31:d=2  hl=2 l=  13 cons: SEQUENCE          
   33:d=3  hl=2 l=   9 prim: OBJECT            :sha256WithRSAEncryption
   44:d=3  hl=2 l=   0 prim: NULL              
   46:d=2  hl=2 l=  19 cons: SEQUENCE          
   48:d=3  hl=2 l=  17 cons: SET               
   50:d=4  hl=2 l=  15 cons: SEQUENCE          
   52:d=5  hl=2 l=   3 prim: OBJECT            :commonName
   57:d=5  hl=2 l=   8 prim: PRINTABLESTRING   :GIGABYTE
   67:d=2  hl=2 l=  30 cons: SEQUENCE          
   69:d=3  hl=2 l=  13 prim: UTCTIME           :220930015516Z
   84:d=3  hl=2 l=  13 prim: UTCTIME           :270930015515Z
   99:d=2  hl=2 l=  19 cons: SEQUENCE          
  101:d=3  hl=2 l=  17 cons: SET               
  103:d=4  hl=2 l=  15 cons: SEQUENCE          
  105:d=5  hl=2 l=   3 prim: OBJECT            :commonName
  110:d=5  hl=2 l=   8 prim: PRINTABLESTRING   :GIGABYTE
  120:d=2  hl=4 l= 290 cons: SEQUENCE          
  124:d=3  hl=2 l=  13 cons: SEQUENCE          
  126:d=4  hl=2 l=   9 prim: OBJECT            :rsaEncryption
  137:d=4  hl=2 l=   0 prim: NULL              
  139:d=3  hl=4 l= 271 prim: BIT STRING        
  414:d=2  hl=2 l=  89 cons: cont [ 3 ]        
  416:d=3  hl=2 l=  87 cons: SEQUENCE          
  418:d=4  hl=2 l=  15 cons: SEQUENCE          
  420:d=5  hl=2 l=   3 prim: OBJECT            :X509v3 Basic Constraints
  425:d=5  hl=2 l=   1 prim: BOOLEAN           :255
  428:d=5  hl=2 l=   5 prim: OCTET STRING      [HEX DUMP]:30030101FF
  435:d=4  hl=2 l=  68 cons: SEQUENCE          
  437:d=5  hl=2 l=   3 prim: OBJECT            :2.5.29.1
  442:d=5  hl=2 l=  61 prim: OCTET STRING      [HEX DUMP]:303B80106B4A8AEC403B7D31852242CBBF70BA0EA11530133111300F060355040313084749474142595445821062841E2126E1F8BB4C4B3FC9F2A50261
  505:d=1  hl=2 l=  13 cons: SEQUENCE          
  507:d=2  hl=2 l=   9 prim: OBJECT            :sha256WithRSAEncryption
  518:d=2  hl=2 l=   0 prim: NULL              
  520:d=1  hl=4 l= 513 prim: BIT STRING
> openssl asn1parse -in DB-0005.der -inform DER
    0:d=0  hl=4 l=1018 cons: SEQUENCE          
    4:d=1  hl=4 l= 738 cons: SEQUENCE          
    8:d=2  hl=2 l=   3 cons: cont [ 0 ]        
   10:d=3  hl=2 l=   1 prim: INTEGER           :02
   13:d=2  hl=2 l=  16 prim: INTEGER           :-77759BF85AE4C567B62D71D6F3D24DA4
   31:d=2  hl=2 l=  13 cons: SEQUENCE          
   33:d=3  hl=2 l=   9 prim: OBJECT            :sha256WithRSAEncryption
   44:d=3  hl=2 l=   0 prim: NULL              
   46:d=2  hl=2 l=  19 cons: SEQUENCE          
   48:d=3  hl=2 l=  17 cons: SET               
   50:d=4  hl=2 l=  15 cons: SEQUENCE          
   52:d=5  hl=2 l=   3 prim: OBJECT            :commonName
   57:d=5  hl=2 l=   8 prim: PRINTABLESTRING   :GIGABYTE
   67:d=2  hl=2 l=  32 cons: SEQUENCE          
   69:d=3  hl=2 l=  13 prim: UTCTIME           :230905064223Z
   84:d=3  hl=2 l=  15 prim: GENERALIZEDTIME   :20530905064222Z
  101:d=2  hl=2 l=  19 cons: SEQUENCE          
  103:d=3  hl=2 l=  17 cons: SET               
  105:d=4  hl=2 l=  15 cons: SEQUENCE          
  107:d=5  hl=2 l=   3 prim: OBJECT            :commonName
  112:d=5  hl=2 l=   8 prim: PRINTABLESTRING   :GIGABYTE
  122:d=2  hl=4 l= 546 cons: SEQUENCE          
  126:d=3  hl=2 l=  13 cons: SEQUENCE          
  128:d=4  hl=2 l=   9 prim: OBJECT            :rsaEncryption
  139:d=4  hl=2 l=   0 prim: NULL              
  141:d=3  hl=4 l= 527 prim: BIT STRING        
  672:d=2  hl=2 l=  72 cons: cont [ 3 ]        
  674:d=3  hl=2 l=  70 cons: SEQUENCE          
  676:d=4  hl=2 l=  68 cons: SEQUENCE          
  678:d=5  hl=2 l=   3 prim: OBJECT            :2.5.29.1
  683:d=5  hl=2 l=  61 prim: OCTET STRING      [HEX DUMP]:303B8010654B668A864D76E829294FFF86019E46A11530133111300F06035504031308474947414259544582107FD057DF69B6C68A4E1E27562DCCEB6C
  746:d=1  hl=2 l=  13 cons: SEQUENCE          
  748:d=2  hl=2 l=   9 prim: OBJECT            :sha256WithRSAEncryption
  759:d=2  hl=2 l=   0 prim: NULL              
  761:d=1  hl=4 l= 257 prim: BIT STRING 

Hier Mal ein KEK-Schlüssel von MS zum vergleich

> openssl asn1parse -in KEK-0001.der -inform DER
    0:d=0  hl=4 l=1458 cons: SEQUENCE          
    4:d=1  hl=4 l= 922 cons: SEQUENCE          
    8:d=2  hl=2 l=   3 cons: cont [ 0 ]        
   10:d=3  hl=2 l=   1 prim: INTEGER           :02
   13:d=2  hl=2 l=  19 prim: INTEGER           :33000000131416B8616D82824B000000000013
   34:d=2  hl=2 l=  13 cons: SEQUENCE          
   36:d=3  hl=2 l=   9 prim: OBJECT            :sha256WithRSAEncryption
   47:d=3  hl=2 l=   0 prim: NULL              
   49:d=2  hl=2 l=  90 cons: SEQUENCE          
   51:d=3  hl=2 l=  11 cons: SET               
   53:d=4  hl=2 l=   9 cons: SEQUENCE          
   55:d=5  hl=2 l=   3 prim: OBJECT            :countryName
   60:d=5  hl=2 l=   2 prim: PRINTABLESTRING   :US
   64:d=3  hl=2 l=  30 cons: SET               
   66:d=4  hl=2 l=  28 cons: SEQUENCE          
   68:d=5  hl=2 l=   3 prim: OBJECT            :organizationName
   73:d=5  hl=2 l=  21 prim: PRINTABLESTRING   :Microsoft Corporation
   96:d=3  hl=2 l=  43 cons: SET               
   98:d=4  hl=2 l=  41 cons: SEQUENCE          
  100:d=5  hl=2 l=   3 prim: OBJECT            :commonName
  105:d=5  hl=2 l=  34 prim: PRINTABLESTRING   :Microsoft RSA Devices Root CA 2021
  141:d=2  hl=2 l=  30 cons: SEQUENCE          
  143:d=3  hl=2 l=  13 prim: UTCTIME           :230302202135Z
  158:d=3  hl=2 l=  13 prim: UTCTIME           :380302203135Z
  173:d=2  hl=2 l=  92 cons: SEQUENCE          
  175:d=3  hl=2 l=  11 cons: SET               
  177:d=4  hl=2 l=   9 cons: SEQUENCE          
  179:d=5  hl=2 l=   3 prim: OBJECT            :countryName
  184:d=5  hl=2 l=   2 prim: PRINTABLESTRING   :US
  188:d=3  hl=2 l=  30 cons: SET               
  190:d=4  hl=2 l=  28 cons: SEQUENCE          
  192:d=5  hl=2 l=   3 prim: OBJECT            :organizationName
  197:d=5  hl=2 l=  21 prim: PRINTABLESTRING   :Microsoft Corporation
  220:d=3  hl=2 l=  45 cons: SET               
  222:d=4  hl=2 l=  43 cons: SEQUENCE          
  224:d=5  hl=2 l=   3 prim: OBJECT            :commonName
  229:d=5  hl=2 l=  36 prim: PRINTABLESTRING   :Microsoft Corporation KEK 2K CA 2023
  267:d=2  hl=4 l= 290 cons: SEQUENCE          
  271:d=3  hl=2 l=  13 cons: SEQUENCE          
  273:d=4  hl=2 l=   9 prim: OBJECT            :rsaEncryption
  284:d=4  hl=2 l=   0 prim: NULL              
  286:d=3  hl=4 l= 271 prim: BIT STRING        
  561:d=2  hl=4 l= 365 cons: cont [ 3 ]        
  565:d=3  hl=4 l= 361 cons: SEQUENCE          
  569:d=4  hl=2 l=  14 cons: SEQUENCE          
  571:d=5  hl=2 l=   3 prim: OBJECT            :X509v3 Key Usage
  576:d=5  hl=2 l=   1 prim: BOOLEAN           :255
  579:d=5  hl=2 l=   4 prim: OCTET STRING      [HEX DUMP]:03020186
  585:d=4  hl=2 l=  16 cons: SEQUENCE          
  587:d=5  hl=2 l=   9 prim: OBJECT            :1.3.6.1.4.1.311.21.1
  598:d=5  hl=2 l=   3 prim: OCTET STRING      [HEX DUMP]:020100
  603:d=4  hl=2 l=  29 cons: SEQUENCE          
  605:d=5  hl=2 l=   3 prim: OBJECT            :X509v3 Subject Key Identifier
  610:d=5  hl=2 l=  22 prim: OCTET STRING      [HEX DUMP]:0414E0AB72BC963EFFB8669B7D105A433E5C4254875F
  634:d=4  hl=2 l=  25 cons: SEQUENCE          
  636:d=5  hl=2 l=   9 prim: OBJECT            :1.3.6.1.4.1.311.20.2
  647:d=5  hl=2 l=  12 prim: OCTET STRING      [HEX DUMP]:1E0A00530075006200430041
  661:d=4  hl=2 l=  15 cons: SEQUENCE          
  663:d=5  hl=2 l=   3 prim: OBJECT            :X509v3 Basic Constraints
  668:d=5  hl=2 l=   1 prim: BOOLEAN           :255
  671:d=5  hl=2 l=   5 prim: OCTET STRING      [HEX DUMP]:30030101FF
  678:d=4  hl=2 l=  31 cons: SEQUENCE          
  680:d=5  hl=2 l=   3 prim: OBJECT            :X509v3 Authority Key Identifier
  685:d=5  hl=2 l=  24 prim: OCTET STRING      [HEX DUMP]:301680148444860600983F2CAAB3C589F3AC2EC9E69D0903
  711:d=4  hl=2 l= 101 cons: SEQUENCE          
  713:d=5  hl=2 l=   3 prim: OBJECT            :X509v3 CRL Distribution Points
  718:d=5  hl=2 l=  94 prim: OCTET STRING      [HEX DUMP]:305C305AA058A0568654687474703A2F2F7777772E6D6963726F736F66742E636F6D2F706B696F70732F63726C2F4D6963726F736F667425323052534125323044657669636573253230526F6F742532304341253230323032312E63726C
  814:d=4  hl=2 l= 114 cons: SEQUENCE          
  816:d=5  hl=2 l=   8 prim: OBJECT            :Authority Information Access
  826:d=5  hl=2 l= 102 prim: OCTET STRING      [HEX DUMP]:3064306206082B060105050730028656687474703A2F2F7777772E6D6963726F736F66742E636F6D2F706B696F70732F63657274732F4D6963726F736F667425323052534125323044657669636573253230526F6F742532304341253230323032312E637274
  930:d=1  hl=2 l=  13 cons: SEQUENCE          
  932:d=2  hl=2 l=   9 prim: OBJECT            :sha256WithRSAEncryption
  943:d=2  hl=2 l=   0 prim: NULL              
  945:d=1  hl=4 l= 513 prim: BIT STRING     

Ich kann aktuell (noch) nichts mit den Werten anfangen, Error oder Unknown habe ich nun aber nicht gesehen.

Wundern rur mich aber noch der abweichende issuer beim KEK (GIGABYTE CA anstatt GIGABYTE).

Ich benutze Kleopatra nicht und daher keine Erfahrung damit. Aber openssl scheint zumindest mit dem ASN.1 Format der Keys zufrieden zu sein.
Issuer und Subject sind ja bei deinen DB Keys und dem PK identisch sind die eventuell self signed ? Auf meiner ASUS Kiste sind alle Zertifikate von ASUS self signed:

for i in PK-0001.der KEK-0001.der DB-0001.der DB-0002.der; do  openssl x509  -inform DER -in $i  -text |grep Subject:; openssl verify  -CAfile $i $i; done
        Subject: CN=ASUSTeK MotherBoard PK Certificate
PK-0001.der: OK
        Subject: CN=ASUSTeK MotherBoard KEK Certificate
KEK-0001.der: OK
        Subject: CN=ASUSTeK MotherBoard SW Key Certificate
DB-0001.der: OK
        Subject: CN=ASUSTeK Notebook SW Key Certificate
DB-0002.der: OK

Bei mir liefert die Schleife einen Error beim KEK Schlüssel. Ich habe Mal grep auf den Issuer angepasst, da Subject immer gleich ist.

> for i in PK-0001.der KEK-0003.der DB-0004.der DB-0005.der; do  openssl x509  -inform DER -in $i  -text |grep Issuer:; openssl verify  -CAfile $i $i; done
        Issuer: CN=GIGABYTE
PK-0001.der: OK
        Issuer: CN=GIGABYTE CA
CN=GIGABYTE
error 20 at 0 depth lookup: unable to get local issuer certificate
error KEK-0003.der: verification failed
        Issuer: CN=GIGABYTE
DB-0004.der: OK
        Issuer: CN=GIGABYTE
DB-0005.der: OK

Es sieht so aus, als ob der Issuer das Problem ist.

Der KEK Key ist von einer CA ausgestellt daher schlägt der Verify fehl. Man müsste das Zertifikat der GIGABYTE CA haben damit ein Verify Test funktioniert. Aber die db Keys 4 und 5 sind zumindest für openssl OK. Der Kernel meckert ja bei den db Keys. Der KEK scheint ihn nicht zu stören oder sehe ich das falsch? In jedem Fall betreibt Gigabyte beim Subject der Zertifikate nur minimalen Aufwand.

Ja, du hast recht.
Du hast die Antwort eigentlich schon in #4 gegeben.
Das Problem wird sein, dass die Gigabyte DB-Schlüssel bestimmte Extensions haben, die zwar openssl validieren kann, der Kernel-Parser aber nicht und deshalb diese Schlüssel ignoriert (weil nicht Standardkonform). Wahrscheinlich sind die Schlüssel nur für BIOS/UEFI selbst relevant. Es würde also nichts anderes übrig bleiben, als die Meldung zu ignorieren, da diese nicht für die Funktionsfähigkeit des Betriebssystem relevant ist. Entfernen sollte man die Schlüssel aber nicht.

Für UEFI Secure Boot müssen folgende X.509-Zertifikate im KEK installiert sein:

  • Microsoft Corporation KEK CA 2011 → Ablaufdatum 24.06.2026 um 20:51 Uhr (GMT)
  • Microsoft Corporation KEK 2K CA 2023 → Ablaufdatum 02.03.2039

https://www.heise.de/news/Vorbereiten-auf-Einschlag-Microsoft-warnt-vor-Secure-Boot-Zertifikat-Update-10461866.html

https://docs.oracle.com/en/operating-systems/oracle-linux/9/secure-boot/sboot-OverviewofSecureBoot.html#sb-implementation

Kontrolle mit: # mokutil --kek

Die für Secure Boot verwendeten Zertifikate kontrollieren:

# dmesg |grep -i integrity

[    0.079594] LSM: initializing lsm=lockdown,capability,apparmor,bpf,integrity
[    0.358149] integrity: Platform Keyring initialized
[    0.358155] integrity: Machine keyring initialized
[    0.646316] integrity: Loading X.509 certificate: UEFI:db
[    0.646352] integrity: Loaded X.509 cert 'Microsoft Corporation UEFI CA 2011: 13adbf4309bd82709c8cd54f316ed522988a1bd4'
[    0.646353] integrity: Loading X.509 certificate: UEFI:db
[    0.646379] integrity: Loaded X.509 cert 'Microsoft Windows Production PCA 2011: a92902398e16c49778cd90f99e4f9ae17c55af53'
[    0.646381] integrity: Loading X.509 certificate: UEFI:db
[    0.668027] integrity: Loaded X.509 cert 'CISD FW Update - Certificate: 068268b4a41c93854262d49b4f788f13'
[    0.670461] integrity: Loading X.509 certificate: UEFI:MokListRT (MOKvar table)
[    0.670697] integrity: Loaded X.509 cert 'SUSE Linux Enterprise Secure Boot CA: ecab0d42c456cf770436b973993862965e87262f'
[    4.035886] systemd[1]: Reached target Local Integrity Protected Volumes.

Im abgebildete Beispiel werden bald ablaufende 2011er-Microsoft-Zertifikate für Secure Boot verwendet!

Für den Linux-Start via SHIM werden diese X.509-Zertifikate in DB benötigt:

  • Microsoft UEFI CA 2011 → Ablaufdatum 27.06.2026 um 21:32 Uhr (GMT)
  • Microsoft UEFI CA 2023 → Ablaufdatum in ferner Zukunft

Kontrolle mit: # mokutil --db

Kiwi_murray hat unter:
https://www.reddit.com/r/intelnuc/comments/1r1jo1w/comment/o4q5p3c/
in einem Beitrag beschrieben, wie sich angeblich das X.509-Zertifikat Microsoft UEFI CA 2023 in den DB-Zertifikatsspeicher installieren lässt (ungetestet).

Kontrolle, ob UEFI Secure Boot aktiv ist:

# mokutil --sb-state
=> SecureBoot enabled

# dmesg |grep -i Secure
=> secureboot: Secure boot is enabled
=> Kernel is locked down from EFI Secure Boot mode; see man kernel_lockdown.7
1 Like

OffTopic:
Aufgrund dieses Beitrages ist mir aufgefallen, das ich auch noch das Microsoft UEFI CA 2011 installiert hatte, dies hab ich mit einem Update des UEFI dann erweitert auf das Microsoft 2023 CA:

dmesg |grep -i integrity
[    0.301805] [      T1] integrity: Platform Keyring initialized
[    0.301813] [      T1] integrity: Machine keyring initialized
[    0.615055] [      T1] integrity: Loading X.509 certificate: UEFI:db
[    0.615260] [      T1] integrity: Loaded X.509 cert 'Microsoft Corporation: Windows UEFI CA 2023: aefc5fbbbe055d8f8daa585473499417ab5a5272'
[    0.615625] [      T1] integrity: Loading X.509 certificate: UEFI:db
[    0.615814] [      T1] integrity: Loaded X.509 cert 'Microsoft Corporation UEFI CA 2011: 13adbf4309bd82709c8cd54f316ed522988a1bd4'
[    0.616105] [      T1] integrity: Loading X.509 certificate: UEFI:db
[    0.616269] [      T1] integrity: Loaded X.509 cert 'Microsoft Windows Production PCA 2011: a92902398e16c49778cd90f99e4f9ae17c55af53'
[    0.617097] [      T1] integrity: Loading X.509 certificate: UEFI:MokListRT (MOKvar table)
[    0.617695] [      T1] integrity: Loading X.509 certificate: UEFI:MokListRT (MOKvar table)
[    0.618277] [      T1] integrity: Loaded X.509 cert 'SUSE Linux Enterprise Secure Boot CA: ecab0d42c456cf770436b973993862965e87262f'
[    0.618889] [      T1] integrity: Loading X.509 certificate: UEFI:MokListRT (MOKvar table)
[    0.619128] [      T1] integrity: Loading X.509 certificate: UEFI:MokListRT (MOKvar table)
[    0.619366] [      T1] integrity: Loaded X.509 cert 'Local build for nvidia-driver-G06 580.142 on 2026-03-13: 0da8b5e3c08bf41796476d4cfec9e1924a96466d'
[    0.619637] [      T1] integrity: Loading X.509 certificate: UEFI:MokListRT (MOKvar table)
[    0.619875] [      T1] integrity: Loading X.509 certificate: UEFI:MokListRT (MOKvar table)
[    0.620102] [      T1] integrity: Loaded X.509 cert 'Virtualization OBS Project: 2146a141430a619da6b0e83b25e2209dd2618265'
[    0.620375] [      T1] integrity: Loading X.509 certificate: UEFI:MokListRT (MOKvar table)
[    0.620690] [      T1] integrity: Loading X.509 certificate: UEFI:MokListRT (MOKvar table)
[    0.620969] [      T1] integrity: Loaded X.509 cert 'home:Sauerland OBS Project: 0c08f13d6eb4382a725ac689be5a4d4103de73da'
[    0.621296] [      T1] integrity: Loading X.509 certificate: UEFI:MokListRT (MOKvar table)
[    0.621477] [      T1] integrity: Loading X.509 certificate: UEFI:MokListRT (MOKvar table)
[    0.621656] [      T1] integrity: Loaded X.509 cert 'openSUSE Secure Boot Signkey: fd9f2c12e599d67cc7f9067541adf426b712469e'
[    0.621977] [      T1] integrity: Loading X.509 certificate: UEFI:MokListRT (MOKvar table)
[    0.622159] [      T1] integrity: Loading X.509 certificate: UEFI:MokListRT (MOKvar table)
[    0.622340] [      T1] integrity: Loaded X.509 cert 'SUSE Linux Products GmbH: ALP Secure Boot Signkey: 939dd72e1ee1ba7b2e5c14b8180da819d7822c79'
[    4.150190] [      T1] systemd[1]: Reached target Local Integrity Protected Volumes.

Jetzt meine Frage:
Was ist mit diesem Zertifikat:

[    0.616269] [      T1] integrity: Loaded X.509 cert 'Microsoft Windows Production PCA 2011: a92902398e16c49778cd90f99e4f9ae17c55af53'

Das zweite in dieser Liste:

stephan@linux64:~> mokutil --kek --list-enrolled | grep -iA 14 "owner"
Owner: 77fa9abd-0359-4d32-bd60-28f4e78f784b
SHA1 Fingerprint: 45:9a:b6:fb:5e:28:4d:27:2d:5e:3e:6a:bc:8e:d6:63:82:9d:63:2b
Certificate:
    Data:
        Version: 3 (0x2)
        Serial Number:
            33:00:00:00:13:14:16:b8:61:6d:82:82:4b:00:00:00:00:00:13
        Signature Algorithm: sha256WithRSAEncryption
        Issuer: C=US, O=Microsoft Corporation, CN=Microsoft RSA Devices Root CA 2021
        Validity
            Not Before: Mar  2 20:21:35 2023 GMT
            Not After : Mar  2 20:31:35 2038 GMT
        Subject: C=US, O=Microsoft Corporation, CN=Microsoft Corporation KEK 2K CA 2023
        Subject Public Key Info:
            Public Key Algorithm: rsaEncryption
--
Owner: 77fa9abd-0359-4d32-bd60-28f4e78f784b
SHA1 Fingerprint: 31:59:0b:fd:89:c9:d7:4e:d0:87:df:ac:66:33:4b:39:31:25:4b:30
Certificate:
    Data:
        Version: 3 (0x2)
        Serial Number:
            61:0a:d1:88:00:00:00:00:00:03
        Signature Algorithm: sha256WithRSAEncryption
        Issuer: C=US, ST=Washington, L=Redmond, O=Microsoft Corporation, CN=Microsoft Corporation Third Party Marketplace Root
        Validity
            Not Before: Jun 24 20:41:29 2011 GMT
            Not After : Jun 24 20:51:29 2026 GMT
        Subject: C=US, ST=Washington, L=Redmond, O=Microsoft Corporation, CN=Microsoft Corporation KEK CA 2011
        Subject Public Key Info:
            Public Key Algorithm: rsaEncryption

Also der ‘Microsoft Windows Production PCA 2011’ Key ist bei mir in db

# mokutil --db --list-enrolled |grep Micro
        Issuer: C=US, ST=Washington, L=Redmond, O=Microsoft Corporation, CN=Microsoft Corporation Third Party Marketplace Root
        Subject: C=US, ST=Washington, L=Redmond, O=Microsoft Corporation, CN=Microsoft Corporation UEFI CA 2011
        Issuer: C=US, ST=Washington, L=Redmond, O=Microsoft Corporation, CN=Microsoft Root Certificate Authority 2010
        Subject: C=US, ST=Washington, L=Redmond, O=Microsoft Corporation, CN=Microsoft Windows Production PCA 2011

das ist er auch laut dem dmesg Kommando oben.
Wie die ganze Trust Kette von Microsoft funktioniert bzw. in Zukunft funktionieren soll ist mir aktuell leider nicht so ganz klar insbesondere in Kombination mit dem SBAT Thema das ja für Linux zusätzlich relevant ist.
Mein UEFI/BIOS ist eigentlich aktuell aber die neuen Microsoft Keys von 2023 habe ich auf diesem Linux only Rechner nicht . Auf einen etwas älteren Lenovo PC mit Uralt UEFI/BIOS (da gibt es kein Update mehr) und Windows Dual Boot sind die allerdings schon drauf wohl direkt von Microsoft.
Na ja UEFI checkt das Ablaufdatum der Keys wohl eh nicht da warte ich mal ab wie sich das weiter entwickelt.

Nur zur Info zur Funktion der Windows Key findet sich das hier bei MicrosoftUpdating Secure Boot

Microsoft Windows Production PCA 2011 wird für den Start von Microsoft Windows benötigt.

Microsoft Windows Production PCA 2011 und Microsoft Corporation KEK 2011 muss bis spätestens 20.10.2026 durch das neue X.509-Zertifikatsduo Windows UEFI CA 2023 (im DB) + Microsoft Corporation KEK 2K CA 2023 (im KEK) ersetzt werden. Ansonsten riskiert der Administrator:in nicht mehr funktionierende Rechnerstarts vom Betriebssystem Microsoft Windows! Wenn der Rechnerstart mit UEFI Secure Boot abgesichert ist.

Microsoft UEFI CA 2011 und Microsoft Corporation KEK 2011 muss bis spätestens 24.06.2026 durch das neue X.509-Zertifikatsduo Microsoft UEFI CA 2023 (im DB) + Microsoft Corporation KEK 2K CA 2023 (im KEK) ersetzt werden. Ansonsten riskiert der Administrator:in nicht mehr funktionierende Rechnerstarts vom Betriebssystem Linux! Wenn der Rechnerstart mit UEFI Secure Boot abgesichert ist.

Die X.509-Zertifikate von Gigabyte werden vermutlich für (UEFI-)Firmware-Updates per “UEFI Update Capsule” benötigt. Unter Linux ermöglicht fwupdmgr das Installieren von (UEFI-)Firmware-Updates per “UEFI Update Capsule”:

https://wiki.archlinux.org/title/Fwupd

Die für Secure Boot benötigten 2023-Microsoft-Zertifkate können bei neueren Rechnern auch über UEFI Update Capsule im DB installiert werden:

Das ganze SBAT-Thema wird von Oracle in einem lesenswerten Artikel sehr gut beschrieben:
https://docs.oracle.com/en/operating-systems/oracle-linux/10/secure-boot/sboot-ToolsandApplicationsforAdministeringSecureBoot.html#sb-dbxtool-1

Kurzfassung:

  • Aktuelle SBAT-Sperrliste ausgeben:
# mokutil --list-sbat-revocations

Aktuell ist:

sbat,1,2025051000
shim,4
grub,5
grub.proxmox,2
  • SBAT-Sperrliste löschen
# mokutil --set-sbat-policy delete
# reboot
  • Neuste SBAT-Sperrliste installieren
# mokutil --set-sbat-policy latest
# reboot
  • SBAT-Einträge in der shim.EFI-Datei kontrollieren.
# efibootmgr -v
BootCurrent: 0000
Timeout: 1 seconds
BootOrder: 0000
Boot0000* sled-secureboot	HD(2,GPT,806c816b-7671-4bd7-8d29-a3013214a523,0x3200800,0x96000)/File(\EFI\sled\shim.efi)

# objdump -s -j .sbat /boot/efi/EFI/sled/shim.efi 

/boot/efi/EFI/sled/shim.efi:     file format pei-x86-64

Contents of section .sbat:
 dd000 73626174 2c312c53 42415420 56657273  sbat,1,SBAT Vers
 dd010 696f6e2c 73626174 2c312c68 74747073  ion,sbat,1,https
 dd020 3a2f2f67 69746875 622e636f 6d2f7268  ://github.com/rh
 dd030 626f6f74 2f736869 6d2f626c 6f622f6d  boot/shim/blob/m
 dd040 61696e2f 53424154 2e6d640a 7368696d  ain/SBAT.md.shim
 dd050 2c342c55 45464920 7368696d 2c736869  ,4,UEFI shim,shi
 dd060 6d2c312c 68747470 733a2f2f 67697468  m,1,https://gith
 dd070 75622e63 6f6d2f72 68626f6f 742f7368  ub.com/rhboot/sh
 dd080 696d0a73 68696d2e 736c652c 312c5355  im.shim.sle,1,SU
 dd090 5345204c 696e7578 20456e74 65727072  SE Linux Enterpr
 dd0a0 6973652c 7368696d 2c31362e 312c6d61  ise,shim,16.1,ma
 dd0b0 696c3a73 65637572 69747940 73757365  il:security@suse
 dd0c0 2e64650a                             .de. 

Aktuell sollte SHIM-SBAT-Version 4 installiert sein.

# rpm -q --changelog shim |grep -i sbat
  • SBAT-Einträge in der grub.EFI-Datei kontrollieren.
# objdump -s -j .sbat /boot/efi/EFI/sled/grub.efi |more

/boot/efi/EFI/sled/grub.efi:     file format pei-x86-64

Contents of section .sbat:
 1ff000 73626174 2c312c53 42415420 56657273  sbat,1,SBAT Vers
 1ff010 696f6e2c 73626174 2c312c68 74747073  ion,sbat,1,https
 1ff020 3a2f2f67 69746875 622e636f 6d2f7268  ://github.com/rh
 1ff030 626f6f74 2f736869 6d2f626c 6f622f6d  boot/shim/blob/m
 1ff040 61696e2f 53424154 2e6d640a 67727562  ain/SBAT.md.grub
 1ff050 2c362c46 72656520 536f6674 77617265  ,6,Free Software
 1ff060 20466f75 6e646174 696f6e2c 67727562   Foundation,grub
 1ff070 2c322e31 322c6874 7470733a 2f2f7777  ,2.12,https://ww
 1ff080 772e676e 752e6f72 672f736f 66747761  w.gnu.org/softwa
 1ff090 72652f67 7275622f 0a677275 622e736c  re/grub/.grub.sl
 1ff0a0 652c312c 53555345 204c696e 75782045  e,1,SUSE Linux E
 1ff0b0 6e746572 70726973 652c6772 7562322c  nterprise,grub2,
 1ff0c0 322e3132 2c6d6169 6c746f3a 73656375  2.12,mailto:secu
 1ff0d0 72697479 40737573 652e6465 0a000000  rity@suse.de....
 1ff0e0 00000000 00000000 00000000 00000000  ................
 1ff0f0 00000000 00000000 00000000 00000000  ................
...

Aktuell sollte GRUB-SBAT-Version 6 installiert sein.

# rpm -q --changelog grub2 |grep -i "SBAT generation"
- Bump upstream SBAT generation to 6
- Bump upstream SBAT generation to 5
- Bump upstream SBAT generation to 4
- Bump upstream SBAT generation to 3
- Bump grub's SBAT generation to 2

Wichtig: Nach jedem SHIM-Update kontrollieren, ob alle Notfall-Bootmedien noch funktionieren.

2 Likes

Ich bin ja (aktuell) der Meinung, dass wir die Zertifikate gar nicht manuell updaten müssen. Ich gehe eher davon aus, dass die Zertifikate via OS-Update aktualisiert werden.
Die Zertifikate werden von Microsoft auch anderen OS-Entwicklern bereitgestellt. Es kam auch vor ein paar Wochen schon CA Zertifikatsupudates . Bis Juni ist es ja noch eine Weile hin.

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.