Lune

CCS2021顶会

SmashEx: Smashing SGX Enclaves Using Exceptions

Jinhua Cui, Jason Zhijingcheng Yu, Shweta Shinde, Prateek Saxena, Zhiping Cai

摘要

Exceptions are a commodity hardware functionality which is central to multi-tasking OSes as well as event-driven user applications. Normally, the OS assists the user application by lifting the semantics of exceptions received from hardware to program-friendly user signals and exception handling interfaces. However, can exception handlers work securely in user enclaves, such as those enabled by Intel SGX, where the OS is not trusted by the enclave code? In this paper, we introduce a new attack called SmashEx which exploits the OS-enclave interface for asynchronous exceptions in SGX. It demonstrates the importance of a fundamental property of safe atomic execution that is required on this interface. In the absence of atomicity, we show that asynchronous exception handling in SGX enclaves is complicated and prone to re-entrancy vulnerabilities. Our attacks do not assume any memory errors in the enclave code, side channels, or application-specific logic flaws. We concretely demonstrate exploits that cause arbitrary disclosure of enclave private memory and code-reuse (ROP) attacks in the enclave. We show reliable exploits on two widely-used SGX runtimes, Intel SGX SDK and Microsoft Open Enclave, running OpenSSL and cURL libraries respectively. We tested a total of 14 frameworks, including Intel SGX SDK and Microsoft Open Enclave, 10 of which are vulnerable. We discuss how the vulnerability manifests on both SGX1-based and SGX2-based platforms. We present potential mitigation and long-term defenses for SmashEx.

问 Lune

几分钟读透这篇 Paper,不用再花一下午。

Lune 能读完全文,也能读引用它的顶会 Paper,讲清它的结论、证据和局限,每一点都注明出自哪篇 Paper。不用硬啃,也不靠猜。

已有 18 篇顶会 Paper 引用了它。别等审稿人问起,先弄清它们发现了什么。

可以从这些问题问起

Lune 可以查阅

全文 · 引用它的顶会 Paper · 相关的 Paper

获取答案

免费开始,无需绑卡

脉络

  • Pandora: Principled Symbolic Validation of Intel SGX Enclave Runtimes 引用了 T-SGX: Eradicating Controlled-Channel Attacks Against Enclave Programs
  • SoK: SGX.Fail: How Stuff Gets eXposed 引用了 Telling Your Secrets without Page Faults: Stealthy Page Table-Based Attacks on Enclaved Execution
  • SoK: SGX.Fail: How Stuff Gets eXposed 引用了 Leaky Cauldron on the Dark Land: Understanding Memory Side-Channel Hazards in SGX
  • Smile: Secure Memory Introspection for Live Enclave 引用了 T-SGX: Eradicating Controlled-Channel Attacks Against Enclave Programs
  • Telling Your Secrets without Page Faults: Stealthy Page Table-Based Attacks on Enclaved Execution 引用了 Panoply: Low-TCB Linux Applications With SGX Enclaves
  • Telling Your Secrets without Page Faults: Stealthy Page Table-Based Attacks on Enclaved Execution 引用了 Leaky Cauldron on the Dark Land: Understanding Memory Side-Channel Hazards in SGX
  • Panoply: Low-TCB Linux Applications With SGX Enclaves 引用了 T-SGX: Eradicating Controlled-Channel Attacks Against Enclave Programs
  • Leaky Cauldron on the Dark Land: Understanding Memory Side-Channel Hazards in SGX 引用了 T-SGX: Eradicating Controlled-Channel Attacks Against Enclave Programs
它引用的引用它的从左到右按年份排列,引用越多,位置越高。

引用它的顶会 Paper18

  1. SoK: SGX.Fail: How Stuff Gets eXposedStephan van Schaik, Alexander Seto, Thomas Yurek, Adam Batori 等S&P 2024 · 52 次引用
  2. uBFT: Microsecond-Scale BFT using Disaggregated MemoryMarcos K. Aguilera, Naama Ben-David, Rachid Guerraoui, Antoine Murat 等ASPLOS 2023 · 20 次引用
  3. MOAT: Towards Safe BPF Kernel ExtensionHongyi Lu, Shuai Wang, Yechang Wu, Wanning He 等USENIX Security 2024 · 18 次引用
  4. Smile: Secure Memory Introspection for Live EnclaveLei Zhou, Xuhua Ding, Fengwei ZhangS&P 2022 · 13 次引用
  5. Pandora: Principled Symbolic Validation of Intel SGX Enclave RuntimesFritz Alder, Lesly-Ann Daniel, David F. Oswald, Frank Piessens 等S&P 2024 · 12 次引用

它引用的 Paper16

  1. T-SGX: Eradicating Controlled-Channel Attacks Against Enclave ProgramsMing-Wei Shih, Sangho Lee, Taesoo Kim, Marcus PeinadoNDSS 2017 · 431 次引用
  2. Data-Oriented Programming: On the Expressiveness of Non-control Data AttacksHong Hu, Shweta Shinde, Sendroiu Adrian, Zheng Leong Chua 等S&P 2016 · 420 次引用
  3. Leaky Cauldron on the Dark Land: Understanding Memory Side-Channel Hazards in SGXWenhao Wang, Guoxing Chen, Xiaorui Pan, Yinqian Zhang 等CCS 2017 · 403 次引用
  4. Telling Your Secrets without Page Faults: Stealthy Page Table-Based Attacks on Enclaved ExecutionJo Van Bulck, Nico Weichbrodt, Rüdiger Kapitza, Frank Piessens 等USENIX Security 2017 · 316 次引用
  5. Panoply: Low-TCB Linux Applications With SGX EnclavesShweta Shinde, Dat Le Tien, Shruti Tople, Prateek SaxenaNDSS 2017 · 274 次引用

相关 Paper

  1. Hacking in Darkness: Return-oriented Programming against Secure EnclavesJae-Hyuk Lee, Jin Soo Jang, Yeongjin Jang, Nohyun Kwak 等USENIX Security 2017 · 191 次引用
  2. TeeRex: Discovery and Exploitation of Memory Corruption Vulnerabilities in SGX EnclavesTobias Cloosters, Michael Rodler, Lucas DaviUSENIX Security 2020
  3. The Guard's Dilemma: Efficient Code-Reuse Attacks Against Intel SGXAndrea Biondo, Mauro Conti, Lucas Davi, Tommaso Frassetto 等USENIX Security 2018 · 126 次引用
  4. Foreshadow: Extracting the Keys to the Intel SGX Kingdom with Transient Out-of-Order ExecutionJo Van Bulck, Marina Minkin, Ofir Weisse, Daniel Genkin 等USENIX Security 2018 · 1,175 次引用
  5. A Tale of Two Worlds: Assessing the Vulnerability of Enclave Shielding RuntimesJo Van Bulck, David F. Oswald, Eduard Marin, Abdulla Aldoseri 等CCS 2019 · 159 次引用
黄昏的海面,两侧是细线勾勒的悬崖