@@ -1002,9 +1002,6 @@ Source8010: x509.genkey.rocky
10021002%endif
10031003%endif
10041004
1005- # CIQ Kernel
1006- %if 0%{?pe_signing_certkeyslot:1 }
1007-
10081005# CIQ Kernel will override above with CIQ certs
10091006%define secureboot_ca_0 %{SOURCE8001 }
10101007%ifarch x86_64
@@ -1024,9 +1021,6 @@ Source8010: x509.genkey.rocky
10241021%define uki_secureboot_key_0 %{SOURCE8009 }
10251022%endif
10261023
1027- # 0%%{?pe_signing_certkeyslot:1}
1028- %endif
1029-
10301024# rhel && !eln
10311025%endif
10321026
@@ -2182,32 +2176,18 @@ done
21822176%if %{signkernel }%{signmodules }
21832177
21842178%ifnarch noarch
2185- # Add DUP and kpatch certificates to system trusted keys for RHEL
2179+ # Add DUP and kpatch certificates to system trusted keys
21862180truncate -s0 ../certs/rhel.pem
21872181%if 0%{?rhel }
21882182
2189- %if 0%{?pe_signing_certkeyslot:1 }
2190-
21912183# Add DUP and kpatch certificates to system trusted keys for Rocky Linux from CIQ
21922184%{log_msg "Add DUP and kpatch certificates to system trusted keys for Rocky Linux from CIQ"}
21932185openssl x509 -inform der -in %{driver_cert } -out ciqkerneldup1.pem
21942186openssl x509 -inform der -in %{kpatch_cert } -out ciqkernelkpatch1.pem
21952187openssl x509 -inform der -in %{SOURCE102 } -out nvidiagpuoot001.pem
21962188cat ciqkerneldup1.pem ciqkernelkpatch1.pem nvidiagpuoot001.pem > ../certs/ciqkernel.pem
21972189
2198- %else
21992190
2200- %if %{rhelkeys }
2201- %{log_msg "Add DUP and kpatch certificates to system trusted keys for RHEL"}
2202- openssl x509 -inform der -in %{SOURCE100 } -out rheldup3.pem
2203- openssl x509 -inform der -in %{SOURCE101 } -out rhelkpatch1.pem
2204- openssl x509 -inform der -in %{SOURCE102 } -out nvidiagpuoot001.pem
2205- cat rheldup3.pem rhelkpatch1.pem nvidiagpuoot001.pem >> ../certs/rhel.pem
2206- # rhelkeys
2207- %endif
2208-
2209- # 0%{?pe_signing_certkeyslot:1}
2210- %endif
22112191%if %{signkernel }
22122192%ifarch s390x ppc64le
22132193openssl x509 -inform der -in %{secureboot_ca_0 } -out secureboot.pem
@@ -2222,11 +2202,7 @@ openssl x509 -inform der -in %{ima_ca_cert} -out imaca.pem
22222202cat imaca.pem >> ../certs/rhel.pem
22232203
22242204for i in *.config; do
2225- %if 0%{?pe_signing_certkeyslot:1 }
22262205 sed -i 's@CONFIG_SYSTEM_TRUSTED_KEYS= ""@CONFIG_SYSTEM_TRUSTED_KEYS= "certs/ciqkernel.pem"@' $i
2227- %else
2228- sed -i 's@CONFIG_SYSTEM_TRUSTED_KEYS= ""@CONFIG_SYSTEM_TRUSTED_KEYS= "certs/rhel.pem"@' $i
2229- %endif
22302206 sed -i 's@CONFIG_EFI_SBAT_FILE= ""@CONFIG_EFI_SBAT_FILE= "kernel.sbat"@' $i
22312207done
22322208# ifnarch noarch
0 commit comments