Rosita++: Automatic Higher-Order Leakage Elimination from Cryptographic Code

Madura A. Shelton, Łukasz Chmielewski, Niels Samwel, Markus Wagner, Lejla Batina +1 more
9/24/2021
cs.CR

Official code: 0xADE1A1DE/Rositaplusplus (7 stars, C, Apache-2.0, last commit 2022-11-15).

Abstract

Side-channel attacks are a major threat to the security of cryptographic implementations, particularly for small devices that are under the physical control of the adversary. While several strategies for protecting against side-channel attacks exist, these often fail in practice due to unintended interactions between values deep within the CPU.

Show full abstract

To detect and protect from side-channel attacks, several automated tools have recently been proposed; one of their common limitations is that they only support first-order leakage. In this work, we present the first automated tool for detecting and eliminating higher-order leakage from cryptographic implementations. Rosita++ proposes statistical and software-based tools to allow high-performance higher-order leakage detection. It then uses the code rewrite engine of Rosita (Shelton et al. NDSS 2021) to eliminate detected leakage. For the sake of practicality we evaluate Rosita++ against second and third order leakage, but our framework is not restricted to only these orders. We evaluate Rosita++ against second-order leakage with three-share implementations of two ciphers, PRESENT and Xoodoo, and with the second-order Boolean-to-arithmetic masking, a core building block of masked implementations of many cryptographic primitives, including SHA-2, ChaCha and Blake. We show effective second-order leakage elimination at a performance cost of 36% for Xoodoo, 189% for PRESENT, and 29% for the Boolean-to-arithmetic masking. For third-order analysis, we evaluate Rosita++ against the third-order leakage using a four-share synthetic example that corresponds to typical four-share processing. Rosita++ correctly identified this leakage and applied code fixes.

View on arXivView PDF

Code Implementations(1)

Apache-2.0

Rosita++

72C, C++Sep 11, 20214 years agoApache-2.0

Similar Papers

Cite this paper

@article{shelton2021rosita,
  title  = {Rosita++: Automatic Higher-Order Leakage Elimination from Cryptographic Code},
  author = {Madura A. Shelton and Łukasz Chmielewski and Niels Samwel and Markus Wagner and Lejla Batina and Yuval Yarom},
  year   = {2021},
  eprint = {2109.11741},
  archivePrefix = {arXiv},
  url    = {https://arxiv.org/abs/2109.11741}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2109.11741.svg)](https://codeofpaper.com/paper/2109.11741)

Discussion