Paper 2023/1713 Original: eprint.iacr.org/2023/1713 ↗

High-assurance zeroization

Santiago Arranz Olmos
Gilles Barthe
Ruben Gonzalez
Benjamin Grégoire
Vincent Laporte
Jean-Christophe Léchenet
Tiago Oliveira
Peter Schwabe
Abstract

In this paper, we revisit the problem of erasing sensitive data from memory and registers when returning from a cryptographic routine. While the problem and related attacker model are fairly easy to phrase, it turns out to be surprisingly hard to guarantee security in this model when implementing cryptography in common languages such as C/C++ or Rust. We revisit the issues surrounding zeroization and then present a principled solution in the sense that it guarantees that sensitive data is erased and it clearly defines when this happens. We implement our solution as an extension to the formally verified Jasmin compiler and extend the correctness proof of the compiler to cover zeroization. We show that the approach seamlessly integrates with state-of-the-art protections against microarchitectural attacks by integrating zeroization into Libjade, a cryptographic library written in Jasmin with systematic protections against timing and Spectre-v1 attacks. We present benchmarks showing that, in many cases, the overhead of zeroization is barely measurable and stays below 2% except for highly optimized symmetric crypto routines on short inputs.

Metadata
Available format(s)
PDF
Category
Implementation
Publication info
Preprint.
History
2024-08-17: last updated
2023-11-05: published
Short URL
https://ia.cr/2023/1713
License
https://creativecommons.org/publicdomain/zero/1.0/

BibTeX

@misc{cryptoeprint:2023/1713,
      author = {Santiago Arranz Olmos and Gilles Barthe and Ruben Gonzalez and Benjamin Grégoire and Vincent Laporte and Jean-Christophe Léchenet and Tiago Oliveira and Peter Schwabe},
      title = {High-assurance zeroization},
      howpublished = {Cryptology {ePrint} Archive, Paper 2023/1713},
      year = {2023},
      url = {https://eprint.iacr.org/2023/1713}
}
Note: In order to protect the privacy of readers, this archive does not use cookies or embedded third party content.