Shining Light On Shadow Stacks
arXiv:1811.03165 · doi:10.1109/SP.2019.00076
Abstract
Control-Flow Hijacking attacks are the dominant attack vector against C/C++ programs. Control-Flow Integrity (CFI) solutions mitigate these attacks on the forward edge,i.e., indirect calls through function pointers and virtual calls. Protecting the backward edge is left to stack canaries, which are easily bypassed through information leaks. Shadow Stacks are a fully precise mechanism for protecting backwards edges, and should be deployed with CFI mitigations. We present a comprehensive analysis of all possible shadow stack mechanisms along three axes: performance, compatibility, and security. For performance comparisons we use SPEC CPU2006, while security and compatibility are qualitatively analyzed. Based on our study, we renew calls for a shadow stack design that leverages a dedicated register, resulting in low performance overhead, and minimal memory overhead, but sacrifices compatibility. We present case studies of our implementation of such a design, Shadesmar, on Phoronix and Apache to demonstrate the feasibility of dedicating a general purpose register to a security monitor on modern architectures, and the deployability of Shadesmar. Our comprehensive analysis, including detailed case studies for our novel design, allows compiler designers and practitioners to select the correct shadow stack design for different usage scenarios.
arXiv commentTo Appear in IEEE Security and Privacy 2019
References in corpus (2)
Cited by in corpus (20)
- The Android Platform Security Model (2023)
- Survey of Control-Flow Integrity Techniques for Embedded and Real-Time Embedded Systems
- Swivel: Hardening WebAssembly against Spectre
- A TOCTOU Attack on DICE Attestation
- CryptSan: Leveraging ARM Pointer Authentication for Memory Safety in C/C++
- libmpk: Software Abstraction for Intel Memory Protection Keys
- Efficient Sealable Protection Keys for RISC-V
- Using Name Confusion to Enhance Security
- Tiles: Efficient Intra-Process Privilege Enforcement of Memory Regions
- Confidential Attestation: Efficient in-Enclave Verification of Privacy Policy Compliance
- Profile-Guided, Multi-Version Binary Rewriting
- Silhouette: Efficient Protected Shadow Stacks for Embedded Systems
- MESH: A Memory-Efficient Safe Heap for C/C++
- PACStack: an Authenticated Call Stack
- ERIM: Secure, Efficient In-process Isolation with Memory Protection Keys (MPK)
- Fast Execute-Only Memory for Embedded Systems
- Garmr: Defending the gates of PKU-based sandboxing
- HeapSafe: Securing Unprotected Heaps in RISC-V
- A Comprehensive and Cross-Platform Test Suite for Memory Safety -- Towards an Open Framework for Testing Processor Hardware Supported Security Extensions
- Making Code Re-randomization Practical with MARDU