aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBastian Blank <waldi@debian.org>2021-07-28 12:41:37 +0200
committerBastian Blank <waldi@debian.org>2021-07-28 12:41:37 +0200
commitdc601b255f6dd8fa819d718960c00c23174f3c24 (patch)
treef06021223a747d978996c9833be66ac30cf123cd
parent7fc66186b65e2de2e402259fbc7ce26ee8ddf98f (diff)
downloadkernel_replicant_linux-dc601b255f6dd8fa819d718960c00c23174f3c24.tar.gz
kernel_replicant_linux-dc601b255f6dd8fa819d718960c00c23174f3c24.tar.bz2
kernel_replicant_linux-dc601b255f6dd8fa819d718960c00c23174f3c24.zip
Read certs from config for signed template
-rwxr-xr-xdebian/bin/gencontrol_signed.py18
1 files changed, 3 insertions, 15 deletions
diff --git a/debian/bin/gencontrol_signed.py b/debian/bin/gencontrol_signed.py
index 4d92a3457441..63eee05ae6e5 100755
--- a/debian/bin/gencontrol_signed.py
+++ b/debian/bin/gencontrol_signed.py
@@ -176,8 +176,8 @@ class Gencontrol(Base):
def do_flavour_packages(self, packages, makefile, arch, featureset,
flavour, vars, makeflags, extra):
- if not (self.config.merge('build', arch, featureset, flavour)
- .get('signed-code', False)):
+ config_build = self.config.merge('build', arch, featureset, flavour)
+ if not config_build.get('signed-code', False):
return
image_suffix = '%(abiname)s%(localversion)s' % vars
@@ -190,19 +190,7 @@ class Gencontrol(Base):
kconfig = f.readlines()
assert 'CONFIG_EFI_STUB=y\n' in kconfig
assert 'CONFIG_LOCK_DOWN_IN_EFI_SECURE_BOOT=y\n' in kconfig
- cert_re = re.compile(r'CONFIG_SYSTEM_TRUSTED_KEYS="(.*)"$')
- cert_file_name = None
- for line in kconfig:
- match = cert_re.match(line)
- if match:
- cert_file_name = match.group(1)
- break
- assert cert_file_name
- if featureset != "none":
- cert_file_name = os.path.join('debian/build/source_%s' %
- featureset,
- cert_file_name)
-
+ cert_file_name = config_build['trusted-certs']
self.image_packages.append((image_suffix, image_package_name,
cert_file_name))