|
| 1 | +--- |
| 2 | +layout: page |
| 3 | +title: Projects |
| 4 | +permalink: /projects/ |
| 5 | +--- |
| 6 | + |
| 7 | +This page lists the different subprojects included in the AeneasVerif umbrella. |
| 8 | +We happily welcome contributions, issues, and pull requests on GitHub! |
| 9 | + |
| 10 | +## Charon |
| 11 | + |
| 12 | +[Charon](https://github.com/AeneasVerif/charon) acts as an interface between |
| 13 | +the rustc compiler and program verification projects. Its purpose is to process |
| 14 | +Rust crates and convert them into files easy to handle by program verifiers. It |
| 15 | +is implemented as a custom driver for the rustc compiler. |
| 16 | + |
| 17 | +Charon operates on MIR, one of the intermediate representations of the rustc |
| 18 | +compiler. Charon converts MIR code to ULLBC (Unstructured Low-Level Borrow |
| 19 | +Calculus), a slightly simplified, verification-oriented representation of MIR. |
| 20 | +It then performs control-flow reconstruction to translate ULLBC to LLBC |
| 21 | +(Low-Level Borrow Calculus). While Charon is implemented in Rust, it includes |
| 22 | +JSON serializers for both ULLBC and LLBC, enabling the development of Rust |
| 23 | +analyses in other programming languages. In particular, it also provides an |
| 24 | +OCaml library, dubbed `charon-ml`, with utilities to manipulate ULLBC and LLBC |
| 25 | +representations in OCaml. |
| 26 | + |
| 27 | +## Aeneas |
| 28 | + |
| 29 | +[Aeneas](https://github.com/AeneasVerif/aeneas) is a verification toolchain for |
| 30 | +Rust programs. It relies on a translation from Charon's LLBC language to a |
| 31 | +pure, functional model, and supports several verification backends, including |
| 32 | +[F\*](https://www.fstar-lang.org), [Coq](https://coq.inria.fr/), |
| 33 | +[HOL4](https://hol-theorem-prover.org/) and |
| 34 | +[Lean](https://leanprover.github.io/). |
| 35 | +Aeneas currently targets a *safe*, sequential Rust code. See the [Aeneas |
| 36 | +README](https://github.com/AeneasVerif/aeneas?tab=readme-ov-file#targeted-subset-and-current-limitations) |
| 37 | +for more details about the Rust subset currently supported! |
| 38 | + |
| 39 | +To simplify verification of Rust programs, Aeneas also provides specific proof |
| 40 | +automation for several backends. We particularly recommend the use of the Lean |
| 41 | +backend, which provides support for partial functions and extrinsic proofs of |
| 42 | +termination, as well as tactics specialized for monadic programs. See our |
| 43 | +[tutorial](https://github.com/AeneasVerif/aeneas/blob/main/tests/lean/Tutorial) |
| 44 | +on using Lean for verifying Rust programs translated by Aeneas. |
| 45 | + |
| 46 | +## Eurydice |
| 47 | + |
| 48 | +Eurydice is a compiler from (a subset of) Rust to C. The purpose of Eurydice is to provide a |
| 49 | +backwards-compatibility story as the verification ecosystem gradually |
| 50 | +transitions to Rust. New programs can be written in Rust, in turn making them |
| 51 | +safer and easier to verify; but for legacy environments that cannot yet take a |
| 52 | +dependency on the Rust toolchain, Eurydice allows generating C code as a |
| 53 | +stopgap measure. |
| 54 | + |
| 55 | +Currently (late 2023), the flagship example for Eurydice is Kyber, also known as ML-KEM, |
| 56 | +a Post-Quantum cryptographic algorithm authored and verified in Rust for the |
| 57 | +general public, and [compiled to C](https://github.com/cryspen/hacl-packages/tree/7a7bfbb17d1d912bdb1a80e86a917e1eec8b6264/libcrux/src) |
| 58 | +via Eurydice for Mozilla's NSS library. |
| 59 | + |
| 60 | +In terms of software architecture, Eurydice consumes Rust programs via the |
| 61 | +Charon infrastructure, then extracts Rust to |
| 62 | +[KaRaMeL](https://github.com/FStarLang/karamel)'s internal AST via a |
| 63 | +type-driven translation. Once in the KaRaMeL AST, 30+ nano-passes allow going |
| 64 | +from Rust down to C code. About half of these passes were already implemented |
| 65 | +for KaRaMeL, the rest of the passes reuse the KaRaMeL infrastructure but were |
| 66 | +freshly written for Eurydice. |
| 67 | + |
0 commit comments