From patchwork Thu Jan 6 07:54:23 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: ivanhu X-Patchwork-Id: 1575964 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: bilbo.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=canonical.com header.i=@canonical.com header.a=rsa-sha256 header.s=20210705 header.b=Z7l2uUBE; dkim-atps=neutral Authentication-Results: ozlabs.org; spf=none (no SPF record) smtp.mailfrom=lists.ubuntu.com (client-ip=91.189.94.19; helo=huckleberry.canonical.com; envelope-from=fwts-devel-bounces@lists.ubuntu.com; receiver=) Received: from huckleberry.canonical.com (huckleberry.canonical.com [91.189.94.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by bilbo.ozlabs.org (Postfix) with ESMTPS id 4JTzCM4TXdz9sPC for ; Thu, 6 Jan 2022 18:54:38 +1100 (AEDT) Received: from localhost ([127.0.0.1] helo=huckleberry.canonical.com) by huckleberry.canonical.com with esmtp (Exim 4.86_2) (envelope-from ) id 1n5NbV-0007mm-JC; Thu, 06 Jan 2022 07:54:33 +0000 Received: from smtp-relay-canonical-0.internal ([10.131.114.83] helo=smtp-relay-canonical-0.canonical.com) by huckleberry.canonical.com with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.86_2) (envelope-from ) id 1n5NbU-0007mN-JB for fwts-devel@lists.ubuntu.com; Thu, 06 Jan 2022 07:54:32 +0000 Received: from canonical.com (unknown [175.182.110.232]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by smtp-relay-canonical-0.canonical.com (Postfix) with ESMTPSA id D8B0740037 for ; Thu, 6 Jan 2022 07:54:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=canonical.com; s=20210705; t=1641455672; bh=QullM/sIcRAxj5L2TBd8iJNbZ83T4ui6e19dFWMOmOs=; h=From:To:Subject:Date:Message-Id:MIME-Version; b=Z7l2uUBEP56q0PwH4ZXaUdeMEL2lfS2enaVICaS5Cxqd1KOZz0UGy1xcOmHXnc9fk Rp8/Vbo4ycW3FyGgbcYBw3OjjtqSEYNlGMm6Wh2xqmcG4qm2QLCtkYkUA8A6uynx+L /mHrZuG8xbUbCwnWUVO7xb0n8lRkDvzBM2PUu5gQe2DwtmbefNqBW93mJJPTSbMLQM rWzcAex2GaikvczoXqDHdh3SoaJnV1ekAA0S4pg5EiRt3y1vfKZeFfK36QNskCxYxk UUXjgt+NrZ/ueMXIuSaYhOaHRdWMbWLe7N3wAuxTrVby7ajZcWRrHhvjy4bzoTzK+Z JMP/G9f48yvzQ== From: Ivan Hu To: fwts-devel@lists.ubuntu.com Subject: [PATCH] tpmevlogdump: add supporting several new types for event log dumping Date: Thu, 6 Jan 2022 15:54:23 +0800 Message-Id: <20220106075423.83995-1-ivan.hu@canonical.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 X-BeenThere: fwts-devel@lists.ubuntu.com X-Mailman-Version: 2.1.20 Precedence: list List-Id: Firmware Test Suite Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: fwts-devel-bounces@lists.ubuntu.com Sender: "fwts-devel" Add supporting the new tpm event log types which defined in the TCG PTP 1.05 Signed-off-by: Ivan Hu Acked-by: Alex Hung --- src/tpm/tpmevlogdump/tpmevlogdump.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/src/tpm/tpmevlogdump/tpmevlogdump.c b/src/tpm/tpmevlogdump/tpmevlogdump.c index a569d29b..ece42c84 100644 --- a/src/tpm/tpmevlogdump/tpmevlogdump.c +++ b/src/tpm/tpmevlogdump/tpmevlogdump.c @@ -117,12 +117,27 @@ static char *tpmevlogdump_evtype_to_string(const fwts_tpmlog_event_type event_ty case EV_EFI_HANDOFF_TABLES: str = "EV_EFI_HANDOFF_TABLES"; break; + case EV_EFI_PLATFORM_FIRMWARE_BLOB2: + str = "EV_EFI_PLATFORM_FIRMWARE_BLOB2"; + break; + case EV_EFI_HANDOFF_TABLES2: + str = "EV_EFI_HANDOFF_TABLES2"; + break; + case EV_EFI_VARIABLE_BOOT2: + str = "EV_EFI_VARIABLE_BOOT2"; + break; case EV_EFI_HCRTM_EVENT: str = "EV_EFI_HCRTM_EVENT"; break; case EV_EFI_VARIABLE_AUTHORITY: str = "EV_EFI_VARIABLE_AUTHORITY"; break; + case EV_EFI_SPDM_FIRMWARE_BLOB: + str = "EV_EFI_SPDM_FIRMWARE_BLOB"; + break; + case EV_EFI_SPDM_FIRMWARE_CONFIG: + str = "EV_EFI_SPDM_FIRMWARE_CONFIG"; + break; default: str = "Unknown"; break;