diff --git a/fixtures_test.go b/fixtures_test.go index 9da72f5..1173278 100644 --- a/fixtures_test.go +++ b/fixtures_test.go @@ -8,8 +8,7 @@ import ( ) // Note: Attestation fixtures are embedded and managed in the root package test_helpers.go -// using //go:embed. This allows the root package tests and the internal package tests -// to share the same test data files. +// using //go:embed. // Commands to obtain attestation documents: // @@ -77,9 +76,6 @@ import ( // Note: These attestation documents contain expired certificates and should only be used for testing // with SkipTimestampCheck: true -// TestAWSRootCertificateVerification - this test has been moved to internal package -// since it tests internal implementation details - // TestAWSNitroFixtures tests AWS Nitro attestation documents from Veracruz project // These documents are sourced from: https://github.com/veracruz-project/go-nitro-enclave-attestation-document/blob/main/test/aws_nitro_document.cbor func TestAWSNitroFixtures(t *testing.T) { diff --git a/internal/constants.go b/internal/constants.go deleted file mode 100644 index 1638ac9..0000000 --- a/internal/constants.go +++ /dev/null @@ -1,24 +0,0 @@ -package internal - -// Use this command to get this value -// curl -L https://aws-nitro-enclaves.amazonaws.com/AWS_NitroEnclaves_Root-G1.zip -o temp.zip && unzip -p temp.zip root.pem > root.pem && rm temp.zip -// AWS Nitro Enclaves Root Certificate -const AWSNitroRootPEM = `-----BEGIN CERTIFICATE----- -MIICETCCAZagAwIBAgIRAPkxdWgbkK/hHUbMtOTn+FYwCgYIKoZIzj0EAwMwSTEL -MAkGA1UEBhMCVVMxDzANBgNVBAoMBkFtYXpvbjEMMAoGA1UECwwDQVdTMRswGQYD -VQQDDBJhd3Mubml0cm8tZW5jbGF2ZXMwHhcNMTkxMDI4MTMyODA1WhcNNDkxMDI4 -MTQyODA1WjBJMQswCQYDVQQGEwJVUzEPMA0GA1UECgwGQW1hem9uMQwwCgYDVQQL -DANBV1MxGzAZBgNVBAMMEmF3cy5uaXRyby1lbmNsYXZlczB2MBAGByqGSM49AgEG -BSuBBAAiA2IABPwCVOumCMHzaHDimtqQvkY4MpJzbolL//Zy2YlES1BR5TSksfbb -48C8WBoyt7F2Bw7eEtaaP+ohG2bnUs990d0JX28TcPQXCEPZ3BABIeTPYwEoCWZE -h8l5YoQwTcU/9KNCMEAwDwYDVR0TAQH/BAUwAwEB/zAdBgNVHQ4EFgQUkCW1DdkF -R+eWw5b6cp3PmanfS5YwDgYDVR0PAQH/BAQDAgGGMAoGCCqGSM49BAMDA2kAMGYC -MQCjfy+Rocm9Xue4YnwWmNJVA44fA0P5W2OpYow9OYCVRaEevL8uO1XYru5xtMPW -rfMCMQCi85sWBbJwKKXdS6BptQFuZbT73o/gBh1qUxl/nNr12UO8Yfwr6wPLb+6N -IwLz3/Y= ------END CERTIFICATE-----` - -// AWSNitroRootFingerprint is the expected SHA-256 fingerprint of the AWS Nitro root certificate -// From https://docs.aws.amazon.com/enclaves/latest/user/verify-root.html -// Expected AWS Nitro root certificate fingerprint (SHA-256) -const AWSNitroRootFingerprint = "641a0321a3e244efe456463195d606317ed7cdcc3c1756e09893f3c68f79bb5b"