Go to file
Hendrik Hofstadt 941220bc85 bridge: optimize VAA claim derivation
Instead of hashing the body manually, we pass the body to the address derivation syscall.
2020-08-31 20:09:06 +02:00
bridge bridge: setup pubsub before connecting to bootnodes; buffer observations 2020-08-31 16:11:09 +02:00
devnet Run devnet_setup.sh as solana-devnet sidecar 2020-08-22 10:52:51 +02:00
docs Add docs/security.md stub 2020-08-31 12:18:07 +02:00
ethereum bridge: require single step guardian set index changes 2020-08-31 09:25:41 +02:00
proto all: consider decimals on wrapped assets, fix VAA posting, fix solana account parsing 2020-08-28 15:10:42 +02:00
solana bridge: optimize VAA claim derivation 2020-08-31 20:09:06 +02:00
third_party all: consider decimals on wrapped assets, fix VAA posting, fix solana account parsing 2020-08-28 15:10:42 +02:00
tools bridge: grpc codegen 2020-08-20 18:42:46 +02:00
web web: client-side VAA submission 2020-08-31 20:07:26 +02:00
.gitignore Add VAA serialization logic 2020-08-04 23:43:16 +02:00
DEVELOP.md Remove instructions for running devnet_setup.sh 2020-08-22 11:03:20 +02:00
Dockerfile.agent Add builds for protos and the Solana agent 2020-08-15 22:15:26 +02:00
LICENSE Add Apache2 license 2020-08-17 19:17:12 +02:00
README.md Add repo overview to README.md 2020-08-28 15:34:42 +02:00
Tiltfile Remove devnet_setup.sh live sync 2020-08-21 23:15:48 +02:00
buf.yml Add builds for protos and the Solana agent 2020-08-15 22:15:26 +02:00
dev-install.sh dev-install.sh: fix idempotency, add instructions to source env 2020-08-18 11:45:33 +02:00
generate-abi.sh Add tooling to regenerate the Go ABI 2020-08-17 23:02:06 +02:00
generate-protos.sh bridge: grpc codegen 2020-08-20 18:42:46 +02:00

README.md

Wormhole

⚠️ WORK IN PROGRESS — UNAUDITED, DO NOT USE.

See DEVELOP.md for instructions on how to set up a local devnet.

Repo overview:

  • bridge/ — The guardian node which connects to both chains, observes lockups and submits VAAs. Written in pure Go.

    • cmd/guardiand — Most of the business logic for cross-chain communication lives here. Consists of multiple loosely coupled services communicating via Go channels.
    • pkg/devnet — Constants and helper functions for the deterministic local devnet.
    • pkg/ethereum — Ethereum chain interface with auto-generated contract ABI. Uses go-ethereum to directly connect to an Eth node.
    • pkg/solana — Solana chain interface. Light gRPC wrapper around a Rust agent (see below) which actually talks to Solana.
    • pkg/supervisor — Erlang-inspired process supervision tree imported from Certus One's internal code base. We use this everywhere in the bridge code for fault tolerance and fast convergence.
    • pkg/vaa — Go implementation of our VAA structure, including serialization code.
  • ethereum/ — Ethereum wormhole contract, tests and fixtures.

    • contracts/ — Wormhole itself, the wrapped token and helper libraries.
    • migrations/ — Ganache migration that deploys the contracts to a local devnet. This is the starting point for both the tests and the devnet. Note that devnet and tests result in different devnet states.
    • src/send-lockups.js — Sends ETH lockups in a loop. See DEVELOP.md for usage.
  • solana/ — Solana sidecar agent, contract and CLI.

    • agent/ — Rust agent sidecar deployed alongside each Guardian node. It serves a local gRPC API to interface with the Solana blockchain. This is far easier to maintain than a pure-Go Solana client.
    • bridge/ — Solana Wormhole smart contract code.
    • cli/ — Wormhole user CLI tool for interaction with the smart contract.
    • devnet_setup.sh — Devnet initialization and lockup generator (the Solana equivalent to the Ganache migration + send-lockups.js). Runs as a sidecar alongside the Solana devnet.
  • proto/ — Protocol Buffer definitions for the P2P network and the local Solana agent RPC. These are heavily commented and a good intro.

  • third_party/ — Build machinery and tooling for third party applications we use.

    • abigen/ — Reproducible build for the go-ethereum ABI code generator we use.
    • solana/ — Build for the full Solana project plus a floating patchset we maintain while waiting for features to be implemented in the upstream project.
  • docs/ — Operator documentation and project specs.

  • web/ — User interface for cross-chain transfers. Not yet wired into the local devnet. Uses Metamask and Web3.js to initiate transfers from a browser. Watch this video as an introduction.

  • tools/ — Reproducible builds for local development tooling like buf and protoc-gen-go.

  • Tiltfile, devnet/ and various Dockerfiles — deployment code and fixtures for local development. Deploys a determimistic devnet with an Ethereum devnet, Solana devnet, and a variably sized guardian set that can be used to simulate full cross-chain transfers. The Dockerfiles are carefully designed for fast incremental builds with local caching, and require a recent Docker version with Buildkit support. See DEVELOP.md for usage.

  • generate-abi.sh and generate-protos.sh — Helper scripts to (re-)build generated code. The Eth ABI is committed to the repo, so you only need to run this script if the Wormhole.sol interface changes. The protobuf libraries are not committed and will be regenerated automatically by the Tiltfile.