Hyper Hoare Logic: (Dis-)Proving Program Hyperproperties (extended version)

01/24/2023
by   Thibault Dardinier, et al.
0

Hoare logics are proof systems that allow one to formally establish properties of computer programs. Traditional Hoare logics prove properties of individual program executions (so-called trace properties, such as functional correctness). On the one hand, Hoare logic has been generalized to prove properties of multiple executions of a program (so-called hyperproperties, such as determinism or non-interference). These program logics prove the absence of (bad combinations of) executions. On the other hand, program logics similar to Hoare logic have been proposed to disprove program properties (e.g., Incorrectness Logic), by proving the existence of (bad combinations of) executions. All of these logics have in common that they specify program properties using assertions over a fixed number of states, for instance, a single pre- and post-state for functional properties or pairs of pre- and post-states for non-interference. In this paper, we present Hyper Hoare Logic, a generalization of Hoare logic that lifts assertions to properties of arbitrary sets of states. The resulting logic is simple yet expressive: its judgments can express arbitrary trace- and hyperproperties over the terminating executions of a program. By allowing assertions to reason about sets of states, Hyper Hoare Logic can reason about both the absence and the existence of (combinations of) executions, and, thereby, supports both proving and disproving program (hyper-)properties within the same logic. In fact, we prove that Hyper Hoare Logic subsumes the properties handled by numerous existing correctness and incorrectness logics, and can express hyperproperties that no existing Hoare logic can. We also prove that Hyper Hoare Logic is sound and complete. All our technical results have been proved in Isabelle/HOL.

READ FULL TEXT
research
05/10/2021

Incorrectness Logic for Graph Programs

Program logics typically reason about an over-approximation of program b...
research
09/15/2022

Proving Hypersafety Compositionally

Hypersafety properties of arity n are program properties that relate n t...
research
05/23/2022

Sound Automation of Magic Wands (extended version)

The magic wand -* (also called separating implication) is a separation l...
research
02/07/2020

RHLE: Automatic Verification of ∀∃-Hyperproperties

Specifications of program behavior typically consider single executions ...
research
03/14/2018

An Assertion-Based Program Logic for Probabilistic Programs

Research on deductive verification of probabilistic programs has conside...
research
05/17/2022

Local Completeness Logic on Kleene Algebra with Tests

Local Completeness Logic (LCL) has been put forward as a program logic f...
research
01/30/2020

VERONICA: Expressive and Precise Concurrent Information Flow Security (Extended Version with Technical Appendices)

Methods for proving that concurrent software does not leak its secrets h...

Please sign up or login with your details

Forgot password? Click here to reset