Summary
I'd like to propose adding a Lean 4 proof export backend to hevm that translates symbolic execution traces into machine-checkable proof obligations. I have a pending EF ESP grant for this work and wanted to gauge maintainer interest before proceeding.
Motivation
When hevm's SMT solver returns "unsatisfiable" for a property, the result is ephemeral. There is no persistent, auditable artifact that a third party can independently check. For high-value contracts, this gap matters.
A proof export backend would:
- Translate symbolic execution paths into Lean 4 theorem statements
- Automatically generate Lean 4 proofs for properties hevm fully verifies
- Produce partial proof skeletons (with explicit
sorry gaps) for properties that exceed hevm's bounds
Scope
The proposed work is designed as a modular addition to minimize maintenance burden:
- Trace extraction module: A new module exporting symbolic execution traces (path conditions, storage transitions, branch metadata) as a structured IR (JSON or S-expressions). This is the only part that touches hevm's Haskell codebase.
- External translation tool: A standalone tool converting the IR to Lean 4 proof obligations. Lives outside hevm's repo.
- Lean 4 libraries: EVM semantics library and tactic library for automated proof generation. Also external.
Questions for maintainers
- Is this a direction you'd be open to seeing for hevm?
- Would you be willing to review/merge a trace export module PR, assuming it's well-scoped and doesn't affect existing functionality?
- Are there any architectural preferences for how trace export should hook into hevm's internals?
- Are there other efforts in this direction I should be aware of?
Full proposal available on request. Thanks for your time.
Summary
I'd like to propose adding a Lean 4 proof export backend to hevm that translates symbolic execution traces into machine-checkable proof obligations. I have a pending EF ESP grant for this work and wanted to gauge maintainer interest before proceeding.
Motivation
When hevm's SMT solver returns "unsatisfiable" for a property, the result is ephemeral. There is no persistent, auditable artifact that a third party can independently check. For high-value contracts, this gap matters.
A proof export backend would:
sorrygaps) for properties that exceed hevm's boundsScope
The proposed work is designed as a modular addition to minimize maintenance burden:
Questions for maintainers
Full proposal available on request. Thanks for your time.