Computationally Sound Verification of Source Code

Michael Backes, Matteo Maffei, Dominique Unruh

TL;DR

This paper bridges the gap between symbolic verification of cryptographic protocols and their actual source code implementation. It introduces a method to prove that if a protocol implemented in F# is secure according to a symbolic analysis, it's also secure when using real cryptographic algorithms, thus providing computational soundness for source code.

What Problem Does This Paper Address?

Verifying the security of cryptographic protocols is crucial, but traditional methods often rely on symbolic abstractions (like the Dolev-Yao model). While these models simplify analysis and enable automation, they can overlook attacks that exploit the mathematical properties of actual cryptographic algorithms. This disconnect means symbolic security doesn't always guarantee computational security. Furthermore, existing computational soundness results often work on abstract protocol representations, not directly on source code. This leaves room for implementation errors that could undermine security, even if the abstract protocol is proven secure. This paper aims to provide a computationally sound verification method that works directly on source code, accounting for both implementation details and cryptographic realities.

Methods

The authors build upon the F7 verification framework and the RCF calculus, which models a core fragment of F# and supports concurrency and symbolic cryptography. Their core contribution is establishing a computational soundness result for RCF programs. This is achieved by:

  1. Reducing RCF's computational soundness to CoSP: They leverage the CoSP framework, which provides a modular way to prove computational soundness for symbolic abstractions.
  2. Defining a Dolev-Yao (DY) library: This library encodes an arbitrary symbolic model within RCF, allowing for symbolic security definitions.
  3. Proving a simulation between DY and Sealing-based libraries: They show that security properties proven using a sealing-based library (which is amenable to type-checking with tools like F7) can be translated to the DY library.
  4. Establishing a chain of implications: The proof establishes a sequence: symbolic security of RCF programs using the DY library implies robust SExec-safety, which in turn implies robust computational safety when using actual cryptographic algorithms.

This approach allows them to use existing symbolic verification tools (like F7) while guaranteeing computational security.

Datasets

Not discussed in the paper.

Key Insights and Ideas

  • Bridging the gap: The paper's main achievement is connecting symbolic protocol analysis directly to source code implementations with computational guarantees. This is a significant step towards more trustworthy cryptographic software.
  • Modularity via CoSP: Using the CoSP framework allows them to modularize the proof, separating the concerns of protocol modeling from the cryptographic soundness proofs. This makes the approach extensible to new cryptographic primitives.
  • Simulation is key: The core of the proof relies on demonstrating that executions using a symbolic library (DY) can be simulated by executions using a sealing-based library, and vice-versa. This simulation allows them to transfer security guarantees.
  • F7 integration: By showing how their work integrates with the F7 type-checker, they provide a practical path for developers to verify their F# code.

Key Results

The paper establishes computational soundness for RCF programs with respect to public-key encryptions and digital signatures. Specifically, they prove that:

  • If an RCF program is symbolically secure when linked to a Dolev-Yao library, it is computationally secure when using actual cryptographic algorithms.
  • This result extends to programs using a sealing-based library, which can be analyzed by tools like F7.
  • Well-typed RCF programs (using the F7 type-checker) are computationally sound.

Limitations and Future Work

The authors acknowledge several limitations:

  • Safety properties only: The current results focus on safety properties (authorization policies) and do not cover liveness properties.
  • Single network channel: The analysis assumes a single public network channel for communication with the adversary.
  • Restrictions on primitives: Protocols are restricted from encrypting or sending secret keys.
  • No assumptions/assertions in symbolic libraries: Symbolic libraries themselves cannot contain assumptions or assertions, though wrapper libraries can be used.
  • Efficiency of decidability: The definition of "efficiently decidable" refers to the decidability of a property in a given execution, not necessarily the protocol guaranteeing the property.

They suggest future work could include extending the results to liveness properties, supporting multiple network channels, and exploring observational equivalence. They also believe their approach can be extended to other cryptographic primitives supported by CoSP.

Summary updated

BibTeX
@article{backes2010computationally,
  author = {Michael Backes and Matteo Maffei and Dominique Unruh},
  title = {{Computationally Sound Verification of Source Code}},
  journal = {IACR Cryptol. ePrint Arch.},
  year = {2010},
}

Loading related content...

Figure