summaryrefslogtreecommitdiffstats
path: root/meta-integrity
diff options
context:
space:
mode:
authorLans Zhang <jia.zhang@windriver.com>2017-07-03 15:50:59 +0800
committerLans Zhang <jia.zhang@windriver.com>2017-07-03 15:50:59 +0800
commit353a003f1bd422ea71ed7009e2d7ed04476bc6e2 (patch)
treebadd337c0b4bc19b81f33fc3b8f6d72c0e7a4422 /meta-integrity
parent3816bb03fd895b37d9eca3b2e4f68283a999c3e6 (diff)
downloadmeta-secure-core-353a003f1bd422ea71ed7009e2d7ed04476bc6e2.tar.gz
Use the DER-formatted system trusted key
Signed-off-by: Lans Zhang <jia.zhang@windriver.com>
Diffstat (limited to 'meta-integrity')
-rw-r--r--meta-integrity/recipes-kernel/linux/linux-yocto-integrity.inc7
1 files changed, 4 insertions, 3 deletions
diff --git a/meta-integrity/recipes-kernel/linux/linux-yocto-integrity.inc b/meta-integrity/recipes-kernel/linux/linux-yocto-integrity.inc
index 247ae55..2e636cf 100644
--- a/meta-integrity/recipes-kernel/linux/linux-yocto-integrity.inc
+++ b/meta-integrity/recipes-kernel/linux/linux-yocto-integrity.inc
@@ -11,9 +11,10 @@ SRC_URI += "\
11" 11"
12 12
13do_configure_append() { 13do_configure_append() {
14 if [ -f "${STAGING_DIR_TARGET}${sysconfdir}/keys/system_trusted_key.pem" ]; then 14 cert="${STAGING_DIR_TARGET}${sysconfdir}/keys/system_trusted_key.der"
15 openssl x509 -in "${STAGING_DIR_TARGET}${sysconfdir}/keys/system_trusted_key.pem" \ 15
16 -outform DER -out "${B}/system_trusted_cert.x509" 16 if [ -f "$cert" ]; then
17 install -m 0644 "$cert" "${B}/system_trusted_cert.x509"
17 else 18 else
18 true 19 true
19 fi 20 fi