From 39e3be1e79084a0d5725f0542089a1eee5e1b806 Mon Sep 17 00:00:00 2001 From: Morten Linderud Date: Fri, 23 Jan 2026 23:13:53 +0100 Subject: [PATCH] structures: make TPM2BCreationData public Signed-off-by: Morten Linderud --- tpm2/structures.go | 4 +++- tpm2/tpm2.go | 4 ++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/tpm2/structures.go b/tpm2/structures.go index b173ed29..8991159f 100644 --- a/tpm2/structures.go +++ b/tpm2/structures.go @@ -3328,4 +3328,6 @@ type TPMSContext struct { ContextBlob TPM2BContextData } -type tpm2bCreationData = TPM2B[TPMSCreationData, *TPMSCreationData] +// TPM2BCreationData represents a TPM2B_CREATION_DATA +// See definition in Part 2: Structures, section 15.2. +type TPM2BCreationData = TPM2B[TPMSCreationData, *TPMSCreationData] diff --git a/tpm2/tpm2.go b/tpm2/tpm2.go index 0dbebafd..8762b4b4 100644 --- a/tpm2/tpm2.go +++ b/tpm2/tpm2.go @@ -229,7 +229,7 @@ type CreateResponse struct { // the public portion of the created object OutPublic TPM2BPublic // contains a TPMS_CREATION_DATA - CreationData tpm2bCreationData + CreationData TPM2BCreationData // digest of creationData using nameAlg of outPublic CreationHash TPM2BDigest // ticket used by TPM2_CertifyCreation() to validate that the @@ -1632,7 +1632,7 @@ type CreatePrimaryResponse struct { // the public portion of the created object OutPublic TPM2BPublic // contains a TPMS_CREATION_DATA - CreationData tpm2bCreationData + CreationData TPM2BCreationData // digest of creationData using nameAlg of outPublic CreationHash TPM2BDigest // ticket used by TPM2_CertifyCreation() to validate that the