Exploiting Inaccurate Branch History in Side-Channel Attacks
Yuhui Zhu, Alessandro Biondi
摘要
Modern out-of-order CPUs heavily rely on speculative execution for performance optimization, with branch prediction serving as a cornerstone to minimize stalls and maximize efficiency. Whenever shared branch prediction resources lack proper isolation and sanitization methods, they may originate security vulnerabilities that expose sensitive data across different software contexts. This paper examines the fundamental components of modern Branch Prediction Units (BPUs) and investigates how resource sharing and contention affect two widely implemented but underdocumented features: Bias-Free Branch Prediction and Branch History Speculation. Our analysis demonstrates that these BPU features, while designed to enhance speculative execution efficiency through more accurate branch histories, can also introduce significant security risks. We show that these features can inadvertently modify the Branch History Buffer (BHB) update behavior and create new primitives that trigger malicious mis-speculations. This discovery exposes previously unknown cross-privilege attack surfaces for Branch History Injection (BHI). Based on these findings, we present three novel attack primitives: two Spectre attacks, namely Spectre-BSE and Spectre-BHS, and a cross-privilege control flow side-channel attack called BiasScope. Our research identifies corresponding patterns of vulnerable control flows and demonstrates exploitation on multiple processors. Finally, Chimera is presented: an attack demonstrator based on eBPF for a variant of Spectre-BHS that is capable of leaking kernel memory contents at 24,628 bit/s.
问 Lune
几分钟读透这篇 Paper,不用再花一下午。
Lune 能读完全文,也能读引用它的顶会 Paper,讲清它的结论、证据和局限,每一点都注明出自哪篇 Paper。不用硬啃,也不靠猜。
已有 2 篇顶会 Paper 引用了它。别等审稿人问起,先弄清它们发现了什么。
脉络
- PACMAN: attacking ARM pointer authentication with speculative execution 引用了 Spectre Attacks: Exploiting Speculative Execution
- PACMAN: attacking ARM pointer authentication with speculative execution 引用了 ret2spec: Speculative Execution Using Return Stack Buffers
- PACMAN: attacking ARM pointer authentication with speculative execution 引用了 A Systematic Evaluation of Transient Execution Attacks and Defenses
- Transient Architectural Execution: From Weird Gates to Weird Programs 引用了 PACMAN: attacking ARM pointer authentication with speculative execution
- Transient Architectural Execution: From Weird Gates to Weird Programs 引用了 Spectre Attacks: Exploiting Speculative Execution
- Transient Architectural Execution: From Weird Gates to Weird Programs 引用了 ret2spec: Speculative Execution Using Return Stack Buffers
- Transient Architectural Execution: From Weird Gates to Weird Programs 引用了 A Systematic Evaluation of Transient Execution Attacks and Defenses
- Transient Architectural Execution: From Weird Gates to Weird Programs 引用了 Augury: Using Data Memory-Dependent Prefetchers to Leak Data at Rest
- ret2spec: Speculative Execution Using Return Stack Buffers 引用了 Spectre Attacks: Exploiting Speculative Execution
- iEnFlow: Endogenous Control-Flow Attacks via Conditional Branch Prediction on Apple Silicon 引用了 PACMAN: attacking ARM pointer authentication with speculative execution
- iEnFlow: Endogenous Control-Flow Attacks via Conditional Branch Prediction on Apple Silicon 引用了 Spectre Attacks: Exploiting Speculative Execution
- iEnFlow: Endogenous Control-Flow Attacks via Conditional Branch Prediction on Apple Silicon 引用了 Augury: Using Data Memory-Dependent Prefetchers to Leak Data at Rest
- A Systematic Evaluation of Transient Execution Attacks and Defenses 引用了 Spectre Attacks: Exploiting Speculative Execution
- A Systematic Evaluation of Transient Execution Attacks and Defenses 引用了 ret2spec: Speculative Execution Using Return Stack Buffers
- Augury: Using Data Memory-Dependent Prefetchers to Leak Data at Rest 引用了 Spectre Attacks: Exploiting Speculative Execution
引用它的顶会 Paper2
它引用的 Paper28
- Spectre Attacks: Exploiting Speculative ExecutionPaul Kocher, Jann Horn, Anders Fogh, Daniel Genkin 等S&P 2019 · 2,435 次引用
- A Systematic Evaluation of Transient Execution Attacks and DefensesClaudio Canella, Jo Van Bulck, Michael Schwarz, Moritz Lipp 等USENIX Security 2019 · 442 次引用
- ret2spec: Speculative Execution Using Return Stack BuffersGiorgi Maisuradze, Christian RossowCCS 2018 · 282 次引用
- PACMAN: attacking ARM pointer authentication with speculative executionJoseph Ravichandran, Weon Taek Na, Jay Lang, Mengjia YanISCA 2022 · 68 次引用
- Augury: Using Data Memory-Dependent Prefetchers to Leak Data at RestJose Rodrigo Sanchez Vicarte, Michael Flanders, Riccardo Paccagnella, Grant Garrett-Grossman 等S&P 2022 · 66 次引用
相关 Paper
- Branch Privilege Injection: Compromising Spectre v2 Hardware Mitigations by Exploiting Branch Predictor Race ConditionsSandro Rüegge, Johannes Wikner, Kaveh RazaviUSENIX Security 2025
- Branch History Injection: On the Effectiveness of Hardware Mitigations Against Cross-Privilege Spectre-v2 AttacksEnrico Barberis, Pietro Frigo, Marius Muench, Herbert Bos 等USENIX Security 2022
- Training Solo: On the Limitations of Domain Isolation Against Spectre-v2 AttacksSander Wiebing, Cristiano GiuffridaS&P 2025
- VMSCAPE: Exposing and Exploiting Incomplete Branch Predictor Isolation in Cloud EnvironmentsJean-Claude Graf, Sandro Rüegge, Ali Hajiabadi, Kaveh RazaviS&P 2026 · 4 次引用
- SpecCFI: Mitigating Spectre Attacks using CFI Informed SpeculationEsmaeil Mohammadian Koruyeh, Shirin Haji Amin Shirazi, Khaled N. Khasawneh, Chengyu Song 等S&P 2020 · 74 次引用
