CWE-1342 Base Incomplete

Information Exposure through Microarchitectural State after Transient Execution

This vulnerability occurs when a CPU fails to completely erase temporary data traces left behind by speculative execution or error recovery processes. These lingering microarchitectural hints can be…

Definition

What is CWE-1342?

This vulnerability occurs when a CPU fails to completely erase temporary data traces left behind by speculative execution or error recovery processes. These lingering microarchitectural hints can be analyzed through side-channels to leak sensitive information.
Modern CPUs use techniques like speculative execution and microcode assists to boost performance. When these operations are canceled or encounter errors, the processor should fully clean up. However, if remnants of these transient computations persist in internal buffers (like load/store queues), they create a measurable change in the chip's hidden state. An attacker can then use timing or other side-channel attacks to infer protected data, such as secrets from other processes or virtual machines. Successful exploitation typically requires three conditions: first, vulnerable code must speculatively access sensitive information, leaving microarchitectural traces. Second, the attacker must be able to trigger the specific CPU exceptions or mis-speculations that create these traces. Finally, the attacker needs a method to observe the state change, often by analyzing cache timing or other hardware resource contention, to slowly reconstruct the leaked data.
Auswirkungen in der Praxis

Real-world CVEs caused by CWE-1342

  • Load value injection in some processors utilizing speculative execution may allow an authenticated user to enable information disclosure via a side-channel with local access.

Wie Angreifer es ausnutzen

Angreiferpfad Schritt für Schritt

  1. 1

    Faulting loads in a victim domain may trigger incorrect transient forwarding, which leaves secret-dependent traces in the microarchitectural state. Consider this example from [REF-1203].

  2. 2

    Consider the code gadget:

  3. 3

    A processor with this weakness will store the value of untrusted_arg (which may be provided by an attacker) to the stack, which is trusted memory. Additionally, this store operation will save this value in some microarchitectural buffer, e.g. the store queue. In this code gadget, trusted_ptr is dereferenced while the attacker forces a page fault. The faulting load causes the processor to mis-speculate by forwarding untrusted_arg as the (speculative) load result. The processor then uses untrusted_arg for the pointer dereference. After the fault has been handled and the load has been re-issued with the correct argument, secret-dependent information stored at the address of trusted_ptr remains in microarchitectural state and can be extracted by an attacker using a code gadget.

Verwundbares Codebeispiel

Vulnerable C

Consider the code gadget:

Verwundbar C
void call_victim(size_t untrusted_arg) {
  	 *arg_copy = untrusted_arg;
  	 array[**trusted_ptr * 4096];
   }
Sicheres Codebeispiel

Secure pseudo

Sicher pseudo
// Validate, sanitize, or use a safe API before reaching the sink.
function handleRequest(input) {
  const safe = validateAndEscape(input);
  return executeWithGuards(safe);
}
What changed: the unsafe sink is replaced (or the input is validated/escaped) so the same payload no longer triggers the weakness.
Präventions-Checkliste

How to prevent CWE-1342

  • Architecture and Design / Requirements Hardware ensures that no illegal data flows from faulting micro-ops exists at the microarchitectural level.
  • Build and Compilation Include instructions that explicitly remove traces of unneeded computations from software interactions with microarchitectural elements e.g. lfence, sfence, mfence, clflush.
Erkennungssignale

How to detect CWE-1342

SAST High

Führe statische Analyse (SAST) auf der Codebasis aus und suche im Datenfluss nach dem unsicheren Muster.

DAST Moderate

Führe dynamische Application-Security-Tests gegen den Live-Endpoint aus.

Runtime Moderate

Beobachte Runtime-Logs auf ungewöhnliche Exception-Traces, fehlerhafte Eingaben oder Versuche, Autorisierung zu umgehen.

Code review Moderate

Code Review: Markiere jeden neuen Code, der Eingaben von dieser Oberfläche ohne validierte Framework-Helper verarbeitet.

Plexicus Auto-Fix

Plexicus erkennt CWE-1342 automatisch und öffnet in unter 60 Sekunden einen Fix-PR.

Codex Remedium scannt jeden Commit, identifiziert genau diese Schwachstelle und liefert einen reviewer-ready Pull Request mit dem Patch. Keine Tickets. Keine Hand-offs.

Häufig gestellte Fragen

Frequently asked questions

Was ist CWE-1342?

This vulnerability occurs when a CPU fails to completely erase temporary data traces left behind by speculative execution or error recovery processes. These lingering microarchitectural hints can be analyzed through side-channels to leak sensitive information.

Wie gravierend ist CWE-1342?

MITRE hat für diese Schwachstelle keine Exploit-Wahrscheinlichkeit veröffentlicht. Behandle sie als mittlere Auswirkung, bis dein Threat Model anderes belegt.

Welche Sprachen oder Plattformen sind von CWE-1342 betroffen?

MITRE lists the following affected platforms: Not OS-Specific, Workstation, x86, ARM, Other, Not Technology-Specific, System on Chip.

Wie kann ich CWE-1342 verhindern?

Hardware ensures that no illegal data flows from faulting micro-ops exists at the microarchitectural level. Include instructions that explicitly remove traces of unneeded computations from software interactions with microarchitectural elements e.g. lfence, sfence, mfence, clflush.

Wie erkennt und behebt Plexicus CWE-1342?

Die SAST-Engine von Plexicus erkennt die Datenfluss-Signatur von CWE-1342 bei jedem Commit. Bei einem Treffer öffnet unser Codex-Remedium-Agent einen Fix-PR mit korrigiertem Code, Tests und einer einzeiligen Zusammenfassung für den Reviewer.

Wo erfahre ich mehr über CWE-1342?

MITRE veröffentlicht die kanonische Definition unter https://cwe.mitre.org/data/definitions/1342.html. Für ergänzende Hinweise kannst du auch die OWASP- und NIST-Dokumentation heranziehen.

Bereit, wenn du es bist

Schluss mit dem Bezahlen pro Entwickler.
Schließ den Kreislauf.

Plexicus ist die KI-native ASPM, die scannt, filtert, fixt, pentestet und erklärt — autonom. Unbegrenzte Entwickler, unbegrenzte Repos, Fair-Use-KI-Aktionen. Echter kostenloser Tarif, €269/mo jährlich, wenn du bereit bist.