diff --git a/internal/attestation/snp/validator.go b/internal/attestation/snp/validator.go index 86aa59fc0..59579b192 100644 --- a/internal/attestation/snp/validator.go +++ b/internal/attestation/snp/validator.go @@ -58,10 +58,13 @@ func (v *Validator) OID() asn1.ObjectIdentifier { func (v *Validator) Validate(attDocRaw []byte, nonce []byte, peerPublicKey []byte) (err error) { v.logger.Info("Validate called", "nonce", hex.EncodeToString(nonce)) defer func() { + // Note: We tolerate Validate() to fail for validators without matching configuration. Only 1 of n validators has to succeed. + // Thus the error handling of the validators takes place in the calling function verifyEmbeddedReport(). + // Do not log any errors in the subroutines and use info to still provide insights of the validation processes. if err != nil { - v.logger.Error("Validation failed", "error", err) + v.logger.Info("Validation failed", "nonce", hex.EncodeToString(nonce), "error", err) } else { - v.logger.Info("Validation successful") + v.logger.Info("Validation successful", "nonce", hex.EncodeToString(nonce)) } }()