Papers
Topics
Authors
Recent
Gemini 2.5 Flash
Gemini 2.5 Flash
110 tokens/sec
GPT-4o
56 tokens/sec
Gemini 2.5 Pro Pro
44 tokens/sec
o3 Pro
6 tokens/sec
GPT-4.1 Pro
47 tokens/sec
DeepSeek R1 via Azure Pro
28 tokens/sec
2000 character limit reached

Verus: Verifying Rust Programs using Linear Ghost Types (extended version) (2303.05491v2)

Published 9 Mar 2023 in cs.LO and cs.PL

Abstract: The Rust programming language provides a powerful type system that checks linearity and borrowing, allowing code to safely manipulate memory without garbage collection and making Rust ideal for developing low-level, high-assurance systems. For such systems, formal verification can be useful to prove functional correctness properties beyond type safety. This paper presents Verus, an SMT-based tool for formally verifying Rust programs. With Verus, programmers express proofs and specifications using the Rust language, allowing proofs to take advantage of Rust's linear types and borrow checking. We show how this allows proofs to manipulate linearly typed permissions that let Rust code safely manipulate memory, pointers, and concurrent resources. Verus organizes proofs and specifications using a novel mode system that distinguishes specifications, which are not checked for linearity and borrowing, from executable code and proofs, which are checked for linearity and borrowing. We formalize Verus' linearity, borrowing, and modes in a small lambda calculus, for which we prove type safety and termination of specifications and proofs. We demonstrate Verus on a series of examples, including pointer-manipulating code (an xor-based doubly linked list), code with interior mutability, and concurrent code.

User Edit Pencil Streamline Icon: https://streamlinehq.com
Authors (9)
  1. Andrea Lattuada (5 papers)
  2. Travis Hance (6 papers)
  3. Chanhee Cho (1 paper)
  4. Matthias Brun (2 papers)
  5. Isitha Subasinghe (1 paper)
  6. Yi Zhou (438 papers)
  7. Jon Howell (2 papers)
  8. Bryan Parno (8 papers)
  9. Chris Hawblitzel (4 papers)
Citations (45)

Summary

We haven't generated a summary for this paper yet.