TDXdown: Single-Stepping and Instruction Counting Attacks against Intel TDX

Luca Christopher Wilke (Shared First Author), Florian Sieck (Shared First Author), Thomas Eisenbarth

Abstract

Trusted Execution Environments are a promising solution for solving the data privacy and trust issues introduced by cloud computing. As a result, all major CPU vendors integrated Trusted Execution Environments (TEEs) into their CPUs. The biggest threat to TEE security are side-channel attacks, of which single-stepping attacks turned out to be the most powerful ones. Enabled by the TEE attacker model, single-stepping attacks allow the attacker to execute the TEE one instruction at a time, enabling numerous controlled- and side-channel based security issues. Intel recently launched Intel TDX, its second generation TEE, which protects whole virtual machines (VMs). To minimize the attack surface to side-channels, TDX comes with a dedicated single-stepping attack countermeasure. In this paper, we systematically analyze the single-stepping countermeasure of Intel TDX and show, for the first time, that both, the built-in detection heuristic as well as the prevention mechanism, can be circumvented. We reliably single-step TDX-protected VMs by deluding the TDX security monitor about the elapsed processing time used as part of the detection heuristic. Moreover, our study reveals a design flaw in the single-stepping countermeasure that turns the prevention mechanism against itself: An inherent side-channel within the prevention mechanism leaks the number of instructions executed by the TDX-protected VM, enabling a novel attack we refer to as StumbleStepping. Both attacks, single-stepping and StumbleStepping, work on the most recent Intel TDX enabled Xeon Scalable CPUs. Using StumbleStepping, we demonstrate a novel end-to-end attack against wolfSSL’s ECDSA implementation, exploiting a control flow side-channel in its truncation-based nonce generation algorithm. We provide a systematic study of nonce-truncation implementations, revealing similar leakages in OpenSSL, which we exploit with our single-stepping primitive. Finally, we propose design changes to TDX to mitigate our attacks.
Original languageEnglish
Pages79-93
Number of pages15
DOIs
Publication statusPublished - 10.2024
EventACM CCS 2024 - Salt Lake Marriott Downtown at City Creek, Salt Lake City, United States
Duration: 14.10.202418.10.2024
https://www.sigsac.org/ccs/CCS2024/

Conference

ConferenceACM CCS 2024
Abbreviated titleCCS
Country/TerritoryUnited States
CitySalt Lake City
Period14.10.2418.10.24
Internet address

Fingerprint

Dive into the research topics of 'TDXdown: Single-Stepping and Instruction Counting Attacks against Intel TDX'. Together they form a unique fingerprint.

Cite this