From fadcd1f31ec2a705ea06e4ad290194e81731ee29 Mon Sep 17 00:00:00 2001 From: Nate Sales Date: Mon, 27 Jan 2025 17:34:29 -0500 Subject: [PATCH] refactor: rename sigstore verify function --- pkg/client/client.go | 2 +- pkg/sigstore/sigstore.go | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/pkg/client/client.go b/pkg/client/client.go index dec0098..4093884 100644 --- a/pkg/client/client.go +++ b/pkg/client/client.go @@ -40,7 +40,7 @@ func (s *SecureClient) Verify() (*EnclaveState, error) { return nil, fmt.Errorf("failed to fetch attestation bundle: %v", err) } - codeMeasurements, err := sigstore.VerifyMeasurementAttestation(sigstoreBundle, eifHash, s.repo) + codeMeasurements, err := sigstore.VerifyAttestation(sigstoreBundle, eifHash, s.repo) if err != nil { return nil, fmt.Errorf("failed to verify attested measurements: %v", err) } diff --git a/pkg/sigstore/sigstore.go b/pkg/sigstore/sigstore.go index ff3f726..0c87dfa 100644 --- a/pkg/sigstore/sigstore.go +++ b/pkg/sigstore/sigstore.go @@ -38,9 +38,9 @@ func fetchTrustRoot() (*root.TrustedRoot, error) { return root.NewTrustedRootFromJSON(trustRootJSON) } -// VerifyMeasurementAttestation verifies the attested measurements of an EIF measurement +// VerifyAttestation verifies the attested measurements of an enclave image // against a trusted root (Sigstore) and returns the measurement payload contained in the DSSE. -func VerifyMeasurementAttestation( +func VerifyAttestation( bundleJSON []byte, hexDigest, repo string, ) (*attestation.Measurement, error) {