DO NOT MERGE! attestation: use ark from THIM

remove this commit eventually.
This commit is contained in:
Otto Bittner 2024-04-09 17:34:40 +02:00 committed by Malte Poll
parent 6fa51f73d8
commit 1e7d21e071

View File

@ -122,6 +122,11 @@ func (v *Validator) getTrustedKey(ctx context.Context, attDoc vtpm.AttestationDo
return nil, fmt.Errorf("parsing ASK certificate: %w", err)
}
ark, err := x509.ParseCertificate(att.CertificateChain.ArkCert)
if err != nil {
return nil, fmt.Errorf("parsing ARK certificate: %w", err)
}
verifyOpts := &verify.Options{
TrustedRoots: map[string][]*trust.AMDRootCerts{
"Genoa": {
@ -129,7 +134,7 @@ func (v *Validator) getTrustedKey(ctx context.Context, attDoc vtpm.AttestationDo
Product: "Genoa",
ProductCerts: &trust.ProductCerts{
Ask: ask,
Ark: trustedArk,
Ark: ark,
},
},
},