Lest We Remember: Cold Boot Attacks on Encryption Keys

Ludovic Perret, J. Alex Halderman, Seth D. Schoen, Nadia Heninger, William Clarkson, William Paul, Joseph A. Calandrino, Ariel J. Feldman, Jacob Appelbaum, Edward W. FeltenUSENIX Security 2008

Abstract

Standard security models for modern computing rely on the assumption that Dynamic Random Access Memory (DRAM) is volatile, losing its state almost immediately upon power loss. This paper demonstrates that this assumption is physically incorrect. DRAM modules retain their contents for seconds to minutes at room temperature, and for hours if cooled. We exploit this phenomenon to perform "cold boot attacks," recovering cryptographic keys from popular full-disk encryption systems including BitLocker, FileVault, and TrueCrypt. By treating decayed memory as a noisy channel and utilizing the redundancy in cryptographic key schedules, we show that encryption keys can be reconstructed even from significantly corrupted data.

Introduction

For decades, the security of sensitive data in transit or at rest has relied on the perceived volatility of RAM. Disk encryption software stores master keys in memory while a volume is mounted, assuming that a loss of power—such as pulling a laptop's battery—will cause the keys to vanish instantly. This research proves that the physical properties of DRAM allow for significant data remanence, creating a vulnerability window that attackers can exploit to bypass sophisticated software-based security measures.

Characterizing DRAM Decay

The researchers measured bit-decay rates across various memory technologies (SDRAM, DDR, DDR2). Contrary to the expectation of immediate erasure, bits decay toward a hardware-specific "ground state" (typically all 0s or all 1s) over a period of seconds.

Percentage of bit decay over time for memory modules A and C at room temperature.

As shown in the figure above, different modules exhibit varying decay profiles, but many retain a majority of their state for over 30 seconds. This window can be dramatically extended by cooling the chips. Using "canned air" to reach -50°C, the researchers found that decay was negligible even after 10 minutes without power.

Visualizing Memory Remanence

To illustrate the nature of this decay, the authors used a bitmap image stored in memory. As power is removed, the image does not disappear or turn into random noise; instead, it gradually fades toward the ground state.

Visualizing bit decay in DRAM using a bitmap image. From left to right: original image, and images reconstructed from memory after varying intervals of power loss.

Methodology

The attack involves three main steps:

  1. Physical Access and Cooling: The target machine's memory is cooled to prolong data retention.
  2. Imaging: A specialized, low-footprint kernel is booted (via USB or PXE) to dump the residual RAM contents to external storage before the new operating system can overwrite them.
  3. Key Reconstruction: Because the recovered data is "noisy," the authors developed algorithms to reconstruct AES and RSA keys. These algorithms exploit the redundancy in "key schedules"—expanded versions of keys stored in RAM for performance—treating them as error-correcting codes to fix decayed bits.

Results and Impact

The researchers successfully demonstrated fully automated attacks against BitLocker (Windows), FileVault (Mac OS X), dm-crypt (Linux), and TrueCrypt. In many cases, keys could be recovered in seconds even with a 10% bit error rate. Notably, Trusted Platform Modules (TPMs) do not prevent this attack, as keys must eventually be loaded into RAM for active use.

Conclusion

The "cold boot attack" highlights a fundamental gap between software security assumptions and hardware reality. While newer RAM densities may decrease the decay window, the effectiveness of simple cooling techniques ensures that physical access remains a critical threat to data at rest. Mitigation requires architectural shifts, such as hardware-level memory wiping or storing sensitive keys exclusively within CPU registers.

Summary updated

BibTeX
@inproceedings{perret2008lest,
  author = {Ludovic Perret and J. Alex Halderman and Seth D. Schoen and Nadia Heninger and William Clarkson and William Paul and Joseph A. Calandrino and Ariel J. Feldman and Jacob Appelbaum and Edward W. Felten},
  title = {{Lest We Remember: Cold Boot Attacks on Encryption Keys}},
  booktitle = {USENIX Security},
  year = {2008},
}
Figure