Skip to content

parseEfiSignatureList() does not skip SignatureHeaderSize vendor bytes — hash injection into trusted measurement list

Moderate
liamjm published GHSA-9r4w-jg96-92mv May 21, 2026

Package

gomod github.com/google/go-attestation (Go)

Affected versions

<= 0.5.0

Patched versions

None

Description

Summary

parseEfiSignatureList() in attest/internal/events.go does not skip
SignatureHeaderSize vendor bytes before reading EFI_SIGNATURE_LIST
signature entries, violating UEFI specification section 31.4.1.

Impact

For hashSHA256SigGUID lists, attacker-controlled vendor header bytes are appended directly to the trusted SHA256 hash list. A crafted TPM event log can inject arbitrary SHA256 hashes into the verifier's trusted measurement database, allowing a remote attestation verifier to accept a compromised boot state as legitimate — breaking the core integrity guarantee of remote attestation.

Root Cause

After binary.Read(&signatures.Header) reads 28 bytes, buf points to the start of the SignatureHeaderSize vendor bytes. Both entry loops start at sigOffset := 0 instead of sigOffset := SignatureHeaderSize, causing vendor bytes to be read as signature entries.

Affected versions

All versions through commit f877374 (2026-05-15).

Fix

Pull request: #502

  • Add bound check: SignatureHeaderSize must not exceed remaining list space
  • Skip SignatureHeaderSize bytes before both entry loops
  • Regression test: TestParseEfiSignatureListNonZeroSignatureHeaderSize

Severity

Moderate

CVSS overall score

This score calculates overall vulnerability severity from 0 to 10 and is based on the Common Vulnerability Scoring System (CVSS).
/ 10

CVSS v3 base metrics

Attack vector
Network
Attack complexity
High
Privileges required
None
User interaction
None
Scope
Changed
Confidentiality
None
Integrity
High
Availability
None

CVSS v3 base metrics

Attack vector: More severe the more the remote (logically and physically) an attacker can be in order to exploit the vulnerability.
Attack complexity: More severe for the least complex attacks.
Privileges required: More severe if no privileges are required.
User interaction: More severe when no user interaction is required.
Scope: More severe when a scope change occurs, e.g. one vulnerable component impacts resources in components beyond its security scope.
Confidentiality: More severe when loss of data confidentiality is highest, measuring the level of data access available to an unauthorized user.
Integrity: More severe when loss of data integrity is the highest, measuring the consequence of data modification possible by an unauthorized user.
Availability: More severe when the loss of impacted component availability is highest.
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:N/I:H/A:N

CVE ID

No known CVE

Weaknesses

Improper Input Validation

The product receives input or data, but it does not validate or incorrectly validates that the input has the properties that are required to process the data safely and correctly. Learn more on MITRE.

Credits