Annotating, Tracking, and Protecting Cryptographic Secrets with CryptoMPK
Xuancheng Jin, Xuangan Xiao, Songlin Jia, Wang Gao, Dawu Gu, Hang Zhang, Siqi Ma, Zhiyun Qian, Juanru Li
Abstract
Protecting confidential data against memory disclosure attacks is crucial to many critical applications, especially those involve cryptographic operations. However, it is neither easy to identify involved cryptographic confidential data in a program nor to implement a fine-grained and yet efficient protection. Existing defensive techniques face many shortcomings such as coarse-grained protection or exorbitant overhead. As a result, real world crypto applications seldom applied this kind of protection in practice.To make the protection of cryptographic confidential data practical, we design and implement CRYPTOMPK, a source code analysis and transformation system to implement a domain-based memory isolation. CRYPTOMPK first automatically tracks and labels all sensitive memory buffers and operations in source code with a context-sensitive, crypto-aware information flow analysis. Then it partitions the source code into crypto and non-crypto domains with a context-dependent privilege switch instrumentation. By further utilizing Intel Memory Protection Keys (MPK), CRYPTOMPK generates executables with efficient domain switching, protecting them against typical memory disclosure vulnerabilities such as arbitrary memory read. In particular, by using CRYPTOMPK, a large number of intermediate memory buffers that have been previously ignored before are well protected, and thus the security risks are reduced significantly. We leveraged CRYPTOMPK to protect prevalent applications such as Apache and Nginx with widely used crypto libraries (e.g., OpenSSL, LibSodium). CRYPTOMPK only needs several minutes to analyze each of these complex cryptographic programs and incurs at most 9.53% performance overhead for the protected programs.
Ask Lune
Know this paper in minutes, not an afternoon.
Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.
11 top-tier papers have cited it since. Know what they found before your reviewers do.
Lune can draw on
the full paper · the top-tier papers that cite it · related work
Free to start. No credit card required.
Lineage
- Kaleidoscope: Precise Invariant-Guided Pointer Analysis cites ERIM: Secure, Efficient In-process Isolation with Protection Keys (MPK)
- PANIC: PAN-assisted Intra-process Memory Isolation on ARM cites xMP: Selective Memory Protection for Kernel and User Space
- PANIC: PAN-assisted Intra-process Memory Isolation on ARM cites Shreds: Fine-Grained Execution Units with Private Memory
- PANIC: PAN-assisted Intra-process Memory Isolation on ARM cites ERIM: Secure, Efficient In-process Isolation with Protection Keys (MPK)
- You shall not (by)pass!: practical, secure, and fast PKU-based sandboxing cites Spectre Attacks: Exploiting Speculative Execution
- You shall not (by)pass!: practical, secure, and fast PKU-based sandboxing cites Shreds: Fine-Grained Execution Units with Private Memory
- You shall not (by)pass!: practical, secure, and fast PKU-based sandboxing cites Meltdown: Reading Kernel Memory from User Space
- xMP: Selective Memory Protection for Kernel and User Space cites Spectre Attacks: Exploiting Speculative Execution
- xMP: Selective Memory Protection for Kernel and User Space cites Meltdown: Reading Kernel Memory from User Space
- Meltdown: Reading Kernel Memory from User Space cites Spectre Attacks: Exploiting Speculative Execution
- Capacity: Cryptographically-Enforced In-Process Capabilities for Modern ARM Architectures cites You shall not (by)pass!: practical, secure, and fast PKU-based sandboxing
- Capacity: Cryptographically-Enforced In-Process Capabilities for Modern ARM Architectures cites Shreds: Fine-Grained Execution Units with Private Memory
- Capacity: Cryptographically-Enforced In-Process Capabilities for Modern ARM Architectures cites ERIM: Secure, Efficient In-process Isolation with Protection Keys (MPK)
- ERIM: Secure, Efficient In-process Isolation with Protection Keys (MPK) cites Shreds: Fine-Grained Execution Units with Private Memory
Cited by top-tier papers11
- PromptCARE: Prompt Copyright Protection by Watermark Injection and VerificationHongwei Yao, Jian Lou, Zhan Qin, Kui RenS&P 2024 · 43 citations
- You shall not (by)pass!: practical, secure, and fast PKU-based sandboxingAlexios Voulimeneas, Jonas Vinck, Ruben Mechelinck, Stijn VolckaertEuroSys 2022 · 33 citations
- PANIC: PAN-assisted Intra-process Memory Isolation on ARMJiali Xu, Mengyao Xie, Chenggang Wu, Yinqian Zhang et al.CCS 2023 · 11 citations
- Capacity: Cryptographically-Enforced In-Process Capabilities for Modern ARM ArchitecturesKha Dinh Duy, Kyuwon Cho, Taehyun Noh, Hojoon LeeCCS 2023 · 5 citations
- Kaleidoscope: Precise Invariant-Guided Pointer AnalysisTapti Palit, Pedro FonsecaASPLOS 2024 · 3 citations
Builds on9
- Spectre Attacks: Exploiting Speculative ExecutionPaul Kocher, Jann Horn, Anders Fogh, Daniel Genkin et al.S&P 2019 · 2,435 citations
- Meltdown: Reading Kernel Memory from User SpaceMoritz Lipp, Michael Schwarz, Daniel Gruss, Thomas Prescher et al.USENIX Security 2018 · 1,456 citations
- ERIM: Secure, Efficient In-process Isolation with Protection Keys (MPK)Anjo Vahldiek-Oberwagner, Eslam Elnikety, Nuno O. Duarte, Michael Sammler et al.USENIX Security 2019 · 247 citations
- Shreds: Fine-Grained Execution Units with Private MemoryYaohui Chen, Sebassujeen Reymondjohnson, Zhichuang Sun, Long LuS&P 2016 · 116 citations
- xMP: Selective Memory Protection for Kernel and User SpaceSergej Proskurin, Marius Momeu, Seyedhamed Ghavamnia, Vasileios P. Kemerlis et al.S&P 2020 · 89 citations
Related papers
- DynPTA: Combining Static and Dynamic Analysis for Practical Selective Data ProtectionTapti Palit, Jarin Firose Moon, Fabian Monrose, Michalis PolychronakisS&P 2021 · 48 citations
- SpecMPK: Efficient In-Process Isolation with Speculative and Secure Permission Update InstructionDebpratim Adak, Huiyang Zhou, Eric Rotenberg, Amro AwadHPCA 2025 · 3 citations
- VDom: Fast and Unlimited Virtual Domains on Multiple ArchitecturesZiqi Yuan, Siyu Hong, Rui Chang, Yajin Zhou et al.ASPLOS 2023 · 19 citations
- Donky: Domain Keys - Efficient In-Process Isolation for RISC-V and x86David Schrammel, Samuel Weiser, Stefan Steinegger, Martin Schwarzl et al.USENIX Security 2020
- Hardware-Based Domain Virtualization for Intra-Process Isolation of Persistent Memory ObjectsYuanchao Xu, Chencheng Ye, Yan Solihin, Xipeng ShenISCA 2020 · 24 citations
