From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by mx.groups.io with SMTP id smtpd.web10.23013.1641761915823138821 for ; Sun, 09 Jan 2022 12:58:36 -0800 Authentication-Results: mx.groups.io; dkim=missing; spf=pass (domain: arm.com, ip: 217.140.110.172, mailfrom: joseph.hemann@arm.com) Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 7966BED1; Sun, 9 Jan 2022 12:58:30 -0800 (PST) Received: from u203013-lin.austin.arm.com (u203013-lin.austin.arm.com [10.118.28.29]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 6B8193F766; Sun, 9 Jan 2022 12:58:30 -0800 (PST) From: "Joseph Hemann" To: devel@edk2.groups.io Cc: nd@arm.com, Joseph Hemann , G Edhaya Chandran , Barton Gao , Carolyn Gjertsen , Samer El-Haj-Mahmoud , Eric Jin , Arvin Chen , Supreeth Venkatesh Subject: [PATCH V2 0/6] Implementation of TCG2 Protocol test Date: Sun, 9 Jan 2022 14:58:21 -0600 Message-Id: <20220109205827.3608758-1-Joseph.hemann@arm.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable This patch series implements a set of SCT tests, for the TCG2 UEFI protocol as defined in the TCG EFI Protocol Specification. The series implements the code for the test, and the infrastructure needed to run the test from the SCT UI. Patch 1 adds header file with TCG2 protocol definitions. Patch 2 implements initial infrastructure for the TCG2 protocol test including updates to .dsc file, inf file, GUID source files, update to Category.ini. It also adds initial TCG2 protocol test for GetCapability(). Patch 3 implements TCG2 protocol test for GetActivePcrBanks(). Patch 4 implements a test for HashLogExtendEvent() by hashing, and extending data in a test buffer to PCR[16]. Patch 5 implements a test for GetEventLog(), by checking for the event extended in the test in Patch 4. Patch 6 tests SubmitCommand(), by submitting a simple command (GetRandom) to the TPM. Compared to v1, v2 adds: -new checks on GetCapability, GetActivePcrBanks test -Fixes reused Guids in HashLogExtend test -changes command used in SubmitCommand test from GetRandom To TPM2_Hash Cc: G Edhaya Chandran Cc: Barton Gao Cc: Carolyn Gjertsen Cc: Samer El-Haj-Mahmoud Cc: Eric Jin Cc: Arvin Chen Cc: Supreeth Venkatesh Joseph Hemann (6): uefi-sct/SctPkg: TCG2 Protocol: add header with TCG2 protocol definitions uefi-sct/SctPkg: TCG2 Protocol: add GetCapability Test uefi-sct/SctPkg: TCG2 Protocol: add GetActivePcrBanks test uefi-sct/SctPkg: TCG2 Protocol: add HashLogExtendEvent test uefi-sct/SctPkg: TCG2 Protocol: add GetEventLog test uefi-sct/SctPkg: TCG2 Protocol: add SubmitCommand test uefi-sct/SctPkg/CommonGenFramework.sh | 1 + uefi-sct/SctPkg/Config/Data/Category.ini | 7 + .../EFI/Protocol/TCG2/BlackBoxTest/Guid.c | 61 + .../EFI/Protocol/TCG2/BlackBoxTest/Guid.h | 107 ++ .../TCG2/BlackBoxTest/TCG2ProtocolBBTest.h | 208 +++ .../TCG2/BlackBoxTest/TCG2ProtocolBBTest.inf | 51 + .../TCG2ProtocolBBTestConformance.c | 1135 +++++++++++++++++ .../BlackBoxTest/TCG2ProtocolBBTestMain.c | 129 ++ uefi-sct/SctPkg/UEFI/Protocol/TCG2.h | 220 ++++ uefi-sct/SctPkg/UEFI/UEFI_SCT.dsc | 1 + 10 files changed, 1920 insertions(+) create mode 100644 uefi-sct/SctPkg/TestCase/UEFI/EFI/Protocol/TCG2/Black= BoxTest/Guid.c create mode 100644 uefi-sct/SctPkg/TestCase/UEFI/EFI/Protocol/TCG2/Black= BoxTest/Guid.h create mode 100644 uefi-sct/SctPkg/TestCase/UEFI/EFI/Protocol/TCG2/Black= BoxTest/TCG2ProtocolBBTest.h create mode 100644 uefi-sct/SctPkg/TestCase/UEFI/EFI/Protocol/TCG2/Black= BoxTest/TCG2ProtocolBBTest.inf create mode 100644 uefi-sct/SctPkg/TestCase/UEFI/EFI/Protocol/TCG2/Black= BoxTest/TCG2ProtocolBBTestConformance.c create mode 100644 uefi-sct/SctPkg/TestCase/UEFI/EFI/Protocol/TCG2/Black= BoxTest/TCG2ProtocolBBTestMain.c create mode 100644 uefi-sct/SctPkg/UEFI/Protocol/TCG2.h --=20 2.25.1