CVE-2026-6420: Keylime: keylime: security bypass due to hardcoded tpm quote nonce

Published Apr 16, 2026
·
Updated

CVE-2026-6420: Hardcoded attestation challenge nonce allows replay attacks

Impact

The CertificationParameters.generatechallenge() method in the push attestation protocol uses a hardcoded challenge nonce instead of generating a cryptographically random value. This removes the nonce-based replay protection from TPM quote attestation.

An attacker with root access on a monitored agent node can exploit this by stockpiling valid TPM quotes (using tpm2quote with the known nonce) before compromising the system, then replaying them to evade detection by the verifier. The push attestation timeout (~10s) constrains the generation window, but TPM throughput allows stockpiling ~50-200 quotes, enabling approximately 8-33 minutes of undetected compromise with default settings.

The attack is limited to a single agent node (AK signature binding prevents cross-agent replay). The pull-mode (legacy) attestation path is not affected.

Affected versions: >= 7.14.0, <= 7.14.1

CVSS: 6.3 Medium (CVSS:3.1/AV:L/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:L)

| Metric | Value | Rationale | |---|---|---| | AV | Local | Exploitation requires local access to the agent machine (stop agent, access TPM, run replacement). The network transmission of quotes to the verifier is normal protocol operation. | | AC | Low | Deterministic attack: publicly visible nonce, standard tpm2-tools, no race conditions. | | PR | High | Root on a legitimate enrolled node is required. The vulnerability does not help gain access -- it only helps evade detection after root is obtained. No value against a machine the attacker already controls. | | UI | None | Fully automated after initial setup. | | S | Unchanged | AK signature binding confines impact to the single compromised agent. | | C | High | Compromised node continues receiving bootstrap keys, payloads, and secrets intended for trusted nodes. | | I | High | Verifier cannot distinguish a healthy system from a fully compromised one during the evasion window. | | A | Low | Only the compromised agent's revocation and incident response are suppressed; the system as a whole remains operational. |

The base score does not fully capture the operational severity: Keylime exists to detect machine compromise, so 8-33 minutes of undetected compromise is operationally critical. The fix is a one-line change and should be applied immediately regardless of the base score.

Patches

The fix restores the original random nonce generation (one-line change in keylime/models/verifier/evidence.py):

python Before (vulnerable): def generatechallenge(self, bitlength): # self.challenge = Nonce.generate(bitlength) self.challenge = bytes.fromhex("49beed365aac777dae23564f5ad0ec")

After (fixed): def generatechallenge(self, bitlength): self.challenge = Nonce.generate(bitlength)

Users should upgrade to the version containing this fix (7.14.2).

Workarounds

There is no complete workaround. The following existing mechanisms provide partial mitigation and are already active by default (no configuration needed):

1. TPM clock monotonicity check limits each distinct stockpiled quote to a single use, bounding the total evasion time. 2. Push attestation timeout (default 10s) prevents the attacker from going silent and constrains the quote generation window.

Reducing quoteinterval increases the attestation frequency but does not prevent the stockpiling attack.

References

- CWE-329: Generation of Predictable IV/Nonce (primary -- hardcoded nonce in cryptographic attestation protocol) - CWE-547: Use of Hard-Coded, Security-relevant Constants (hardcoded constant left in production code) - CWE-294: Authentication Bypass by Capture-replay (consequence -- enables replay attacks) - CWE-1241: Use of Predictable Algorithm in Random Number Generator - Introducing commit: 2bf91197 via PR #1814 - TCG TPM 2.0 Library Specification, Part 1, Section 18.4 (TPM2Quote) - IETF RATS Architecture (RFC 9334), Section 8 (Freshness)

Other sources

A flaw was found in Keylime. An attacker with root access on an enrolled monitored machine, where the Keylime agent runs, can exploit a vulnerability in the Keylime verifier. The verifier uses a hardcoded challenge nonce for Trusted Platform Module (TPM) quote attestation instead of a cryptographically random value. This allows the attacker to stockpile valid TPM quotes and replay them to evade detection after compromising the system. This issue affects only the push model deployment.

MITRE

Keylime verifier uses a hardcoded challenge nonce for TPM quote attestation instead of generating a cryptographically random value. An attacker with root access on an enrolled monitored machine (where the Keylime agent runs) can stockpile valid TPM quotes using tpm2quote with the known nonce during the push attestation timeout window (defaulting to 10 seconds). The attacker can then compromise the system and replay these quotes to evade detection. Only the push model deployment is affected, the pull model does not use the affected code.

Requirements for exploitation: Root access on a legitimate, monitored machine (running a previously enrolled Keylime agent). The attacker stops the agent, generates quotes via tpm2quote with the known nonce (system still clean, so PCR values are trusted), starts a replacement agent before the ~10s timeout expires, then compromises the system. Each stockpiled quote is usable once (clock monotonicity check prevents reuse).

Red Hat

Affected Software

2 affected componentsFixes available
Keylime Keylime
pip/keylime>=7.14.0<=7.14.1
7.14.2

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade pip/keylime to a version that resolves this vulnerability.

    Fixed in 7.14.2
  2. Upgrade

    Upgrade pip/keylime to a version that resolves this vulnerability.

    Fixed in 7.14.2Patch 2bf91197

Event History

Apr 16, 2026
Data Sourced
via Red Hat·06:03 AM
DescriptionSeverityAffected Software
May 6, 2026
CVE Published
via MITRE·10:19 AM
Data Sourced
via MITRE·10:19 AM
DescriptionSeverityWeakness
Data Sourced
via NVD·11:16 AM
DescriptionSeverityWeakness
May 11, 2026
Advisory Published
via GitHub·02:42 PM
Data Sourced
via GitHub·02:42 PM
DescriptionSeverityWeaknessAffected Software
Free Weekly Intel

Don't miss critical vulnerabilities

Join thousands of security professionals who receive our weekly digest of trending CVEs, zero-days, and exploited vulnerabilities.

No spam. Unsubscribe anytime.

Frequently Asked Questions

1

What is the severity of CVE-2026-6420?

CVE-2026-6420 has been classified as a vulnerability that can lead to security bypass and potential replay attacks due to the use of a hardcoded nonce.

2

How do I fix CVE-2026-6420?

To remediate CVE-2026-6420, upgrade to Keylime version 7.14.2 or later which addresses the vulnerability.

3

What impact does CVE-2026-6420 have on security?

CVE-2026-6420 can allow attackers to perform replay attacks by exploiting the hardcoded attestation challenge nonce.

4

Is CVE-2026-6420 a critical vulnerability?

CVE-2026-6420 presents significant risk due to its potential for security bypass and should be addressed promptly.

5

Which versions of Keylime are affected by CVE-2026-6420?

CVE-2026-6420 affects Keylime versions between 7.14.0 and 7.14.1.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203