Util: : Lookup: Exploiting Key Decoding in Cryptographic Libraries
Florian Sieck, Sebastian Berndt, Jan Wichelmann, Thomas Eisenbarth
Abstract
Implementations of cryptographic libraries have been scrutinized for secret-dependent execution behavior exploitable by microarchitectural side-channel attacks. To prevent unintended leakages, most libraries moved to constant-time implementations of cryptographic primitives. There have also been efforts to certify libraries for use in sensitive areas, like Microsoft CNG and Botan, with specific attention to leakage behavior. In this work, we show that a common oversight in these libraries is the existence of utility functions, which handle and thus possibly leak confidential information. We analyze the exploitability of base64 decoding functions across several widely used cryptographic libraries. Base64 decoding is used when loading keys stored in PEM format. We show that these functions by themselves leak sufficient information even if libraries are executed in trusted execution environments. In fact, we show that recent countermeasures to transient execution attacks such as LVI ease the exploitability of the observed faint leakages, allowing us to robustly infer sufficient information about RSA private keys with a single trace. We present a complete attack, including a broad library analysis, a high-resolution last level cache attack on SGX enclaves, and a fully parallelized implementation of the extend-and-prune approach that allows a complete key recovery at medium costs.
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.
8 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
- TDXdown: Single-Stepping and Instruction Counting Attacks against Intel TDX cites Microwalk-CI: Practical Side-Channel Analysis for JavaScript Applications
- TDXdown: Single-Stepping and Instruction Counting Attacks against Intel TDX cites Inferring Fine-grained Control Flow Inside SGX Enclaves with Branch Shadowing
- TDXdown: Single-Stepping and Instruction Counting Attacks against Intel TDX cites ZombieLoad: Cross-Privilege-Boundary Data Sampling
- Spectre Attacks: Exploiting Speculative Execution cites Inferring Fine-grained Control Flow Inside SGX Enclaves with Branch Shadowing
- Bending microarchitectural weird machines towards practicality cites Spectre Attacks: Exploiting Speculative Execution
- Bending microarchitectural weird machines towards practicality cites ZombieLoad: Cross-Privilege-Boundary Data Sampling
- Bending microarchitectural weird machines towards practicality cites Meltdown: Reading Kernel Memory from User Space
- Bending microarchitectural weird machines towards practicality cites Foreshadow: Extracting the Keys to the Intel SGX Kingdom with Transient Out-of-Order Execution
- ZombieLoad: Cross-Privilege-Boundary Data Sampling cites Spectre Attacks: Exploiting Speculative Execution
- Controlled Preemption: Amplifying Side-Channel Attacks from Userspace cites Inferring Fine-grained Control Flow Inside SGX Enclaves with Branch Shadowing
- Meltdown: Reading Kernel Memory from User Space cites Spectre Attacks: Exploiting Speculative Execution
- Obelix: Mitigating Side-Channels Through Dynamic Obfuscation cites Spectre Attacks: Exploiting Speculative Execution
- Foreshadow: Extracting the Keys to the Intel SGX Kingdom with Transient Out-of-Order Execution cites Inferring Fine-grained Control Flow Inside SGX Enclaves with Branch Shadowing
- Foreshadow: Extracting the Keys to the Intel SGX Kingdom with Transient Out-of-Order Execution cites Spectre Attacks: Exploiting Speculative Execution
Cited by top-tier papers8
- Obelix: Mitigating Side-Channels Through Dynamic ObfuscationJan Wichelmann, Anja Rabich, Anna Pätschke, Thomas EisenbarthS&P 2024 · 15 citations
- Microwalk-CI: Practical Side-Channel Analysis for JavaScript ApplicationsJan Wichelmann, Florian Sieck, Anna Pätschke, Thomas EisenbarthCCS 2022 · 12 citations
- TDXdown: Single-Stepping and Instruction Counting Attacks against Intel TDXLuca Wilke, Florian Sieck, Thomas EisenbarthCCS 2024 · 9 citations
- Controlled Preemption: Amplifying Side-Channel Attacks from UserspaceYongye Zhu, Boru Chen, Zirui Neil Zhao, Christopher W. FletcherASPLOS 2025 · 5 citations
- Bending microarchitectural weird machines towards practicalityPing-Lun Wang, Riccardo Paccagnella, Riad S. Wahby, Fraser BrownUSENIX Security 2024 · 2 citations
Builds on17
- 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
- Foreshadow: Extracting the Keys to the Intel SGX Kingdom with Transient Out-of-Order ExecutionJo Van Bulck, Marina Minkin, Ofir Weisse, Daniel Genkin et al.USENIX Security 2018 · 1,175 citations
- Inferring Fine-grained Control Flow Inside SGX Enclaves with Branch ShadowingSangho Lee, Ming-Wei Shih, Prasun Gera, Taesoo Kim et al.USENIX Security 2017 · 536 citations
- ZombieLoad: Cross-Privilege-Boundary Data SamplingMichael Schwarz, Moritz Lipp, Daniel Moghimi, Jo Van Bulck et al.CCS 2019 · 464 citations
Related papers
- SCASE: Automated Secret Recovery via Side-Channel-Assisted Symbolic ExecutionDaniel Weber, Lukas Gerlach, Leon Trampert, Youheng Lü et al.USENIX Security 2025
- Hardware-Backed Heist: Extracting ECDSA Keys from Qualcomm's TrustZoneKeegan RyanCCS 2019 · 90 citations
- Telling Your Secrets without Page Faults: Stealthy Page Table-Based Attacks on Enclaved ExecutionJo Van Bulck, Nico Weichbrodt, Rüdiger Kapitza, Frank Piessens et al.USENIX Security 2017 · 316 citations
- Load-Step: A Precise TrustZone Execution Control Framework for Exploring New Side-channel Attacks Like Flush+EvictZili Kou, Wenjian He, Sharad Sinha, Wei ZhangDAC 2021 · 23 citations
- STACCO: Differentially Analyzing Side-Channel Traces for Detecting SSL/TLS Vulnerabilities in Secure EnclavesYuan Xiao, Mengyuan Li, Sanchuan Chen, Yinqian ZhangCCS 2017 · 77 citations
