Back to search

University of British Columbia

Formal specification and verification techniques for mutable references and advanced aliasing in Rust

Abstract

dc:description

Verification tools allow developers to write specifications (or rules) that are used to verify the correctness of their programs, i.e., that the programs follow the specified rules. Prusti and Creusot are two verification tools that can be used to verify programs written in Rust. The way Rust handles aliasing mutation has interesting implications when it comes to verification. Prusti and Creusot each use different techniques to take advantage of this; Prusti uses separation logic while Creusot uses its prophecy model. In this thesis, we present several enhancements to these tools that relate to aliasing mutation. The first is a type system for defining well-typed Prusti specifications, which we use to develop a translation from Prusti's specification language to Creusot's specification language. Because of the differences in the way Prusti and Creusot handle mutable references, this translation is non-trivial. We then propose an updated soundness proof for Creusot that allows proving the soundness of a new version of its ghost type. The old version of the ghost type was found to be unsound. The existing soundness proof for Creusot has limitations, which require us to make non-trivial changes to its prophecy model to allow it to prove the soundness of our new version of this ghost type. Lastly, we introduce a new type for Rust that can be used with verification tools such as Prusti or Creusot to verify safety in cases where, because of the aliasing restrictions on Rust's reference types, raw pointers are required to implement data structures.

Degree

thesis:*
Name thesis:degree_name
Master of Science - MSc
Level thesis:degree_level
master's
Discipline thesis:degree_discipline
Computer Science
Grantor dc:publisher
University of British Columbia
Year dc:date
2023

Author and committee

dc:creator, dc:contributor.*
Author dc:creator
  • Ewert, David
Contributors dc:contributor
  • Summers, Alexander J.

Rights

dc:rights
Statement dc:rights
  • Attribution-NonCommercial-NoDerivatives 4.0 International
Language dc:language
eng

Identifiers

dc:identifier.*
Handle dc:identifier
http://hdl.handle.net/2429/86986

Chain of custody

source
Harvested from
University of British Columbia
Base URL
circle.library.ubc.ca/oai/request
Last updated
2026-11-19
Source record
OAI-PMH GetRecord
related terms
citation

Ewert, David. Formal specification and verification techniques for mutable references and advanced aliasing in Rust. master's thesis, University of British Columbia, 2023. http://hdl.handle.net/2429/86986