Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bridge] [Framework] Expand specification of the atomic bridge #95

Open
franck44 opened this issue Nov 11, 2024 · 0 comments
Open

[Bridge] [Framework] Expand specification of the atomic bridge #95

franck44 opened this issue Nov 11, 2024 · 0 comments
Assignees
Labels
enhancement New feature or request

Comments

@franck44
Copy link

Problem

In MIP-39, there is a formal model (timed automata in UPPAAL) of the bridge components (contracts and relayer). This model can be used to prove some quantitative properties of the bridge under some assumptions.

The model uses an abstract semantics of the contracts, approximating the changes on the "states" on the two chains.
The model also relies on correctly modelling revert/abort conditions.

Warning

For the verification results to be meaningful, we should make sure that the model is valid i.e. that we have properly captured the behaviours of the contracts (and relayer).

For the relayer (Rust) and the L1 contracts (Solidity) we can test the contracts to be more confident that are properly modelled in our formal model.

Important

For the L2 contract (Move) side, we can formally verify the assumptions made in the model with the Move Prover.

Proposed work

The atomic_bridge.move code has a companion specification atomic_bridge.spec.move.

Warning

Currently the specification does not cover all of the modules in package.

For instance the following modules have not been verified:

The proposal is to write some specification for these modules including:

  • conditions under which a function call aborts,
  • some post-conditions (ensures) on the status of the bridge transfers.

These properties (once proved) can be matched against the assumptions and encoding in the UPPAAL models.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants