Formally Verified Hardening of C Programs against Hardware Fault Injection - Archive ouverte HAL
Communication Dans Un Congrès Année : 2025

Formally Verified Hardening of C Programs against Hardware Fault Injection

Résumé

A fault attack is a malicious manipulation of the hardware (e.g., electromagnetic or laser pulse) that modifies the behavior of the software. Fault attacks typically target sensitive applications such as cryptography services, authentication, boot-loaders or firmware updaters. They can be defended against by adding countermeasures, that is, control flow checks and redundancies, either in the hardware, or in the software running on it. In particular, software countermeasures may be added automatically during compilation. In this paper, we describe a formally verified implementation of this approach in the CompCert verified compiler for the C language. We implemented two existing countermeasures protecting the control flow of the program as program transformations over a middle-end intermediate representation of CompCert, RTL. We proved that these countermeasures are correct, that is, they do not change the observable behavior of the program during an execution without fault injection. We then modeled the effect of a fault on the behavior of the program as an extension of the semantic model of RTL. We used this new model to formally prove the efficacy of the countermeasure: all attacks are either caught, or produce no observable effects. In addition to this formal reasoning, we evaluated the protected program using Lazart, a tool for symbolic fault injection, and measured the effect of optimizations on security and performance.
Fichier principal
Vignette du fichier
hal_chamois_arsene2024.pdf (508.69 Ko) Télécharger le fichier
Origine Fichiers produits par l'(les) auteur(s)
Licence

Dates et versions

hal-04818801 , version 1 (04-12-2024)

Licence

Identifiants

Citer

Basile Pesin, Sylvain Boulmé, David Monniaux, Marie-Laure Potet. Formally Verified Hardening of C Programs against Hardware Fault Injection. 14th ACM SIGPLAN International Conference on Certified Programs and Proofs (CPP’25), Jan 2025, Denver (CO), United States. ⟨10.1145/3703595.3705880⟩. ⟨hal-04818801v1⟩
0 Consultations
0 Téléchargements

Altmetric

Partager

More