From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-lf1-f48.google.com (mail-lf1-f48.google.com [209.85.167.48]) by mx.groups.io with SMTP id smtpd.web11.4631.1625131273079898138 for ; Thu, 01 Jul 2021 02:21:13 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@semihalf-com.20150623.gappssmtp.com header.s=20150623 header.b=ixCDqiLw; spf=none, err=SPF record not found (domain: semihalf.com, ip: 209.85.167.48, mailfrom: gjb@semihalf.com) Received: by mail-lf1-f48.google.com with SMTP id u13so10672258lfk.2 for ; Thu, 01 Jul 2021 02:21:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=semihalf-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=s1xn85z65yS1r5V1lyXO887g0RS7ewMqwV53chWdJKs=; b=ixCDqiLw/uGXrxvzdHjrQBDmQpLktageh9P6EwmKG1dl3K6jKhzv8p66cbRJ3alIGr dvuLjcImaArPzlTytZyz+SLH4PHDmZZJDKlfkbil/EsF9VBmxOrRvVb2/PXgkf+pKe0E 8X760S5cCgwO1x/n7EwyDBFD8arber0y9UgNW0AJ8Qb41tA7BL5nB38/4uKGYuCB8ELs 3OCF88LcD4EPlpYwoWg8e/BZveHEpnTOM/uaoNDrZLwhUHjLUjU9vvqB04ySfzzyQVaj cOXbkdoTe40D+u+l28sFm+gTAvmRf/ZAVkBONVsKVfsOtQI+vn7KgtjERx7k2+UMcv4d awEg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=s1xn85z65yS1r5V1lyXO887g0RS7ewMqwV53chWdJKs=; b=RYjQYsP+3kz5gZSFxOhVCZNigchTgqRqG2QMXcfuXqfzNOukwyf9yn32Ylp34J+1Yi nIgcyP4Cu32wW3pLzU58foFzHWD0uAbqA5ROlybPSMCEFpcZQGnZ8tybUNlH2gWcKgiS EGmZC4iWEJ0DqyW8Z41Pg8rhOK05eHULYY3QWvgmq5O+ZtHbiRDfRXkWmRXWZyCXW+0G E14go60fjPVb2QE786d6+uXBQw0PecFH804qUMurbFcB0jsZVZluu/MjF9Li2ftzr6gK vzmFwOuT+1EXgy7c/kIpE9eimKMHLagN1xlvZwksOEhU3mEDTDgME7v4/eWqp0eNKNFm VpNw== X-Gm-Message-State: AOAM532Vyf+yl5nujtiRJvvQJt5tcEXms8N1xIuuSeqVGnA3Y2WxB501 +A7dXRCgTSY4AyATDxExwV01KcB6x3Ib2Z11 X-Google-Smtp-Source: ABdhPJx0nPIpVnk5DAPgDq+bDkf0ezLZ9icHz9h0Ah0lVC+wXGX5DXz5TE2RROBjXm6ccQD2rQu2Dg== X-Received: by 2002:ac2:53ae:: with SMTP id j14mr31237138lfh.147.1625131271106; Thu, 01 Jul 2021 02:21:11 -0700 (PDT) Return-Path: Received: from gilgamesh.lab.semihalf.net ([83.142.187.85]) by smtp.gmail.com with ESMTPSA id g15sm2343205lfr.110.2021.07.01.02.21.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 01 Jul 2021 02:21:10 -0700 (PDT) From: "Grzegorz Bernacki" To: devel@edk2.groups.io Cc: leif@nuviainc.com, ardb+tianocore@kernel.org, Samer.El-Haj-Mahmoud@arm.com, sunny.Wang@arm.com, mw@semihalf.com, upstream@semihalf.com, jiewen.yao@intel.com, jian.j.wang@intel.com, min.m.xu@intel.com, lersek@redhat.com, sami.mujawar@arm.com, afish@apple.com, ray.ni@intel.com, jordan.l.justen@intel.com, rebecca@bsdio.com, grehan@freebsd.org, thomas.abraham@arm.com, chasel.chiu@intel.com, nathaniel.l.desimone@intel.com, gaoliming@byosoft.com.cn, eric.dong@intel.com, michael.d.kinney@intel.com, zailiang.sun@intel.com, yi.qian@intel.com, graeme@nuviainc.com, rad@semihalf.com, pete@akeo.ie, Grzegorz Bernacki , Sunny Wang Subject: [edk2-platforms PATCH v5 4/4] Platform/RaspberryPi: Enable default Secure Boot variables initialization Date: Thu, 1 Jul 2021 11:20:51 +0200 Message-Id: <20210701092051.1057606-5-gjb@semihalf.com> X-Mailer: git-send-email 2.29.0 In-Reply-To: <20210701092051.1057606-1-gjb@semihalf.com> References: <20210701092051.1057606-1-gjb@semihalf.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit This commit allows to initialize Secure Boot default key and databases from data embedded in firmware binary. Signed-off-by: Grzegorz Bernacki Reviewed-by: Sunny Wang Reviewed-by: Pete Batard Tested-by: Pete Batard on Raspberry Pi 4 --- Platform/RaspberryPi/RPi4/RPi4.dsc | 3 +++ Platform/RaspberryPi/RPi4/RPi4.fdf | 2 ++ 2 files changed, 5 insertions(+) diff --git a/Platform/RaspberryPi/RPi4/RPi4.dsc b/Platform/RaspberryPi/RPi4/RPi4.dsc index d38fee8fb8..54bb282ff2 100644 --- a/Platform/RaspberryPi/RPi4/RPi4.dsc +++ b/Platform/RaspberryPi/RPi4/RPi4.dsc @@ -218,6 +218,7 @@ MemoryAllocationLib|MdePkg/Library/UefiMemoryAllocationLib/UefiMemoryAllocationLib.inf HiiLib|MdeModulePkg/Library/UefiHiiLib/UefiHiiLib.inf ShellLib|ShellPkg/Library/UefiShellLib/UefiShellLib.inf + ShellCEntryLib|ShellPkg/Library/UefiShellCEntryLib/UefiShellCEntryLib.inf FileHandleLib|MdePkg/Library/UefiFileHandleLib/UefiFileHandleLib.inf [LibraryClasses.common.UEFI_DRIVER] @@ -621,6 +622,8 @@ NULL|SecurityPkg/Library/DxeImageVerificationLib/DxeImageVerificationLib.inf } SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootConfigDxe.inf + SecurityPkg/EnrollFromDefaultKeysApp/EnrollFromDefaultKeysApp.inf + SecurityPkg/VariableAuthenticated/SecureBootDefaultKeysDxe/SecureBootDefaultKeysDxe.inf !else MdeModulePkg/Universal/SecurityStubDxe/SecurityStubDxe.inf !endif diff --git a/Platform/RaspberryPi/RPi4/RPi4.fdf b/Platform/RaspberryPi/RPi4/RPi4.fdf index 1e13909a57..8508065a77 100644 --- a/Platform/RaspberryPi/RPi4/RPi4.fdf +++ b/Platform/RaspberryPi/RPi4/RPi4.fdf @@ -189,7 +189,9 @@ READ_LOCK_STATUS = TRUE INF MdeModulePkg/Universal/FaultTolerantWriteDxe/FaultTolerantWriteDxe.inf INF MdeModulePkg/Universal/Variable/RuntimeDxe/VariableRuntimeDxe.inf !if $(SECURE_BOOT_ENABLE) == TRUE +!include ArmPlatformPkg/SecureBootDefaultKeys.fdf.inc INF SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootConfigDxe.inf + INF SecurityPkg/VariableAuthenticated/SecureBootDefaultKeysDxe/SecureBootDefaultKeysDxe.inf !endif INF MdeModulePkg/Universal/MonotonicCounterRuntimeDxe/MonotonicCounterRuntimeDxe.inf INF EmbeddedPkg/ResetRuntimeDxe/ResetRuntimeDxe.inf -- 2.25.1