Periodic Reporting for period 1 - UniversalContracts (Formalizing, Verifying and Applying ISA Security Guarantees as Universal Contracts)
Reporting period: 2022-09-01 to 2025-02-28
The high-level goals of this project are to contribute reusable techniques and tools for applying universal contracts in realistic ISAs. Specifically, the goals are to (1) design, prove and evaluate universal contracts for ISAs with state-of-practice security primitives, (2) develop semi-automation machinery for verifying universal contracts of ISAs, (3) extend universal contracts to deal with semantic complications like concurrency or micro-architectural side-channels and (4) design, implement and evaluate techniques which facilitate the construction of trusted software that relies on universal contracts, particularly assembly-level reasoning support and secure compilers. If successful, the project will fundamentally improve the security foundations of all software-based systems, by (1) clearly dividing the security responsibilities between hardware and software developers and (2) enabling scalable, rigorous, full-system security proofs.
On the one hand, we have invested significantly in the technical infrastructure and tools for verifying universal contracts of ISAs.
Particularly, the Katamaran symbolic-execution-based verifier for Sail has been significantly improved and its foundations have been strengthened and validated.
New techniques based on a domain-specific modal program logic have been developed (initially in the simpler context of verified type inference, but subsequently ported to the Katamaran verifier) for facilitating and automating Katamaran's soundness proof.
We have also invested in the construction of a new backend for Sail that (mostly-)automatically translates functional ISA specs in Sail to deeply-embedded μSail code that can be verified using Katamaran and this work is reaching completion.
Furthermore, we have demonstrated and validated the use of universal contracts for formalizing, verifying and applying ISA security guarantees by applying it to two different ISAs: RISC-V PMP and MinimalCaps (modeled after CHERI-RISC-V).
We have also started extending Katamaran with support for relational verification, which will significantly enhance its capabilities for verifying confidentiality properties but also for capturing ISA architectural security guarantees that constrain micro-architectural side-channels.
Finally, in the context of the Cerise program logic for a minimal capability machine, we are exploring, with our collaborators, the definition of universal contracts that capture the guarantees of trusted execution primitives, as well as revocation primitives like local capabilities.
Additionally, Katamaran is currently the most advanced foundationally-verified program verifier and its internal use of Kripke-indexed monadic computations and domain-specific modal program logics is highly innovative.
We also expect that these ideas are more broadly applicable in building verified program verifiers; we have already demonstrated this for verifying type inference engines and we hope to demonstrate this broad applicability further in the future.