Zipline is a permissionless block header oracle from Gasper chains (Ethereum/Gnosis beacon chain) to EVM chains! It uses fault proofs to ensure that any relayed block roots that have not been finalized by the origin chain can be proven fraudulent.
This repo contains a proof-of-concept implementation of the main components that make up the protocol. Primarily the contracts that run on the destination chain and the provable execution that runs in an emulator off-chain (but can be proven on-chain) to verify chain finality.
It also contains a book describing the design of the protocol in detail.
Component | Description | Doc |
---|---|---|
Contracts | The Destination chain contracts. These implement the fraud proving game and store the trusted origin chain checkpoints | |
Demo | A demo that can be run locally showing the different components interact to produce the protocol | |
Finality Client | A Rust implementation of a Casper finality client | |
Preprocessor | A typescript CLI and daemon that poll a Gasper chain to produce proofs for a finality client | |
Hashi Adapter | An example of integrating Zipline with the Hashi EVM block oracle aggregator | |
Zipline State Transition (MIPS) | A Rust implementation of the Zipline state transition function that builds to a Cannon compatible MIPS binary. This wraps the finality client in a form that can be run in the emulator and proven on-chain | |
Emulator | A Rust implementation of a MIPS emulator that is compatible with Cannon | |
Specification | An MDBook describing the protocol in detail. Also hosted at https://chainsafe.github.io/Zipline-Casper |
Want to see it run for yourself? The easiest way is to run the demo script. This will create a local testnet destination chain using anvil and simulate two actors interacting with the protocol and show how one can successfully prove fraud in the case a non-finalized origin chain block is submitted.
This repo uses just for running scripts. You can install it with cargo.
- Willem Olding
- Eric Tu
- Cayman Nava