Speculative Buffer Overflows: Attacks and Defenses
arXiv:1807.03757
Abstract
Practical attacks that exploit speculative execution can leak confidential information via microarchitectural side channels. The recently-demonstrated Spectre attacks leverage speculative loads which circumvent access checks to read memory-resident secrets, transmitting them to an attacker using cache timing or other covert communication channels. We introduce Spectre1.1, a new Spectre-v1 variant that leverages speculative stores to create speculative buffer overflows. Much like classic buffer overflows, speculative out-of-bounds stores can modify data and code pointers. Data-value attacks can bypass some Spectre-v1 mitigations, either directly or by redirecting control flow. Control-flow attacks enable arbitrary speculative code execution, which can bypass fence instructions and all other software mitigations for previous speculative-execution attacks. It is easy to construct return-oriented-programming (ROP) gadgets that can be used to build alternative attack payloads. We also present Spectre1.2: on CPUs that do not enforce read/write protections, speculative stores can overwrite read-only data and code pointers to breach sandboxes. We highlight new risks posed by these vulnerabilities, discuss possible software mitigations, and sketch microarchitectural mechanisms that could serve as hardware defenses. We have not yet evaluated the performance impact of our proposed software and hardware mitigations. We describe the salient vulnerability features and additional hypothetical attack scenarios only to the detail necessary to guide hardware and software vendors in threat analysis and mitigations. We advise users to refer to more user-friendly vendor recommendations for mitigations against speculative buffer overflows or available patches.
arXiv commentCVE-2018-3693, 12 pages
Cited by in corpus (22)
- A Systematic Evaluation of Transient Execution Attacks and Defenses
- ZombieLoad: Cross-Privilege-Boundary Data Sampling
- Fallout: Reading Kernel Writes From User Space
- oo7: Low-overhead Defense against Spectre Attacks via Program Analysis
- An Exhaustive Approach to Detecting Transient Execution Side Channels in RTL Designs of Processors
- HybCache: Hybrid Side-Channel-Resilient Caches for Trusted Execution Environments
- CURE: A Security Architecture with CUstomizable and Resilient Enclaves
- ConTExT: Leakage-Free Transient Execution
- Survey of Transient Execution Attacks
- SoK: Hardware Defenses Against Speculative Execution Attacks
- Hacky Racers: Exploiting Instruction-Level Parallelism to Generate Stealthy Fine-Grained Timers
- SpectreRewind: Leaking Secrets to Past Instructions
- Store-to-Leak Forwarding: Leaking Data on Meltdown-resistant CPUs (Updated and Extended Version)
- PThammer: Cross-User-Kernel-Boundary Rowhammer through Implicit Accesses
- Real time Detection of Spectre and Meltdown Attacks Using Machine Learning
- Restricting Control Flow During Speculative Execution with Venkman
- New Models for Understanding and Reasoning about Speculative Execution Attacks
- SPEECHMINER: A Framework for Investigating and Measuring Speculative Execution Vulnerabilities
- BasicBlocker: ISA Redesign to Make Spectre-Immune CPUs Faster
- Speculative Dereferencing of Registers:Reviving Foreshadow
- Domain Page-Table Isolation
- Establishing Cyber Resilience in Embedded Systems for Securing Next-Generation Critical Infrastructure