Commit Graph

24 Commits

Author SHA1 Message Date
Kevin Peters 9d477e0585 ethereum: EVM fork protection
Added a `uint256 evmChainId` state variable to the Core, Token and NFT Bridge
contracts. `evmChainId` is compared to `block.chainid` in the `chainId`
function. When they don't match, a "bad fork" Chain ID is returned,
otherwise the Wormhole Chain ID is returned.
2022-09-09 13:16:27 -05:00
Evan Gray a58c5ae950 ethereum: remove wormhole from token name 2022-08-31 17:21:52 -04:00
justinschuldt d7b102df70 add EVM contract for batched VAA development 2022-08-15 08:41:40 -05:00
Csongor Kiss c453f4cf6d evm: Make finality a state variable 2022-06-28 21:31:23 +01:00
Csongor Kiss 745d3db68d
Run ethereum tests on CI (#1028)
* Add makefile to run ethereum tests

* Run tests on CI

* single rm in make clean

Co-authored-by: Jeff Schroeder <jeffschroeder@computer.org>

* Fix WETH address in bridge test

Change-Id: Idd7455cc873d2db86c2ccc130bd673b065311e67

* Don't kill ganache-cli if already running

Instead error the test

* eth: omit mainnet stuff from ci

Co-authored-by: Csongor Kiss <ckiss@jumptrading.com>
Co-authored-by: Jeff Schroeder <jeffschroeder@computer.org>
Co-authored-by: Drew Sterioti <asterioti@jumptrading.com>
Co-authored-by: Evan Gray <battledingo@gmail.com>
2022-03-31 00:32:27 -04:00
Evan Gray a3272dce4a remove pyth2wormhole 2022-03-07 10:23:34 -05:00
Stanisław Drozd 2ea41b8176
[WIP] Pr/drozdziak1/p2w batching/5e704f8b (#877)
* ethereum: p2w contract -> p2w emitter, fill in essential envs

Change-Id: I6fa9364a96738d2cc02ec829a31fedba0586d8e8

commit-id:0a56f1f8

* Add p2w-relay, a p2w-sdk integration test

commit-id:6bfab639

* p2w-sdk: Expand README

Change-Id: I17cb547d6aaddc240588923561c26d11a787df2e

commit-id:6ebd6a22

* p2w-sdk: don't build ETH contracts, only the types

Change-Id: I7cbd18328227700635d7688aa24a9671e8919fcd

commit-id:adf079f7

* p2w: configurability and sane envs

commit-id:f10fd90e

* Solitaire: Implement Option<T> support in structs

commit-id:31aa12d6

* bridge/governance.rs: Stop pestering about EMITTER_ADDRESS

commit-id:d5bd7234

* p2w-attest: price batching

This commit introduces support for multiple Pyth product/price pairs
per call. The initial maximum batch size is 5 and is enforced using a
`P2W_MAX_BATCH_SIZE` constant.

solana/pyth2wormhole/program:
* On-chain batching logic
* Batch message parsing logic

solana/pyth2wormhole/client:
* Off-chain batching logic - divides any number of symbols into
largest possible batches
* Use a multi-symbol config file instead of CLI arguments

third_party/pyth/p2w-sdk:
* Expose batch parsing logic

third_party/pyth/p2w-relay:
* Comment out target chain calls until ETH contract supports batching
* Test the batch parsing function

third_party/pyth/p2w_autoattest.py:
* Generate and use the symbol config file  with pyth2wormhole-client

third_party/pyth/pyth_publisher.py:
* Add a configurable number of mock Pyth symbols
* Adjust HTTP endpoint for multiple symbols

commit-id:73787a61

* p2w-attest: mention attestation size in batch

This commit ensures that no matter the attestation format, a batch
will never contain attestations of different sizes. This guarantee
enables forward compatibility by adding new constant-size fields at
the end of a batch at all times. An older implementation will simply
not consume the remaining newer values while respecting the stated
batch member alignment.

commit-id:210da230

* pyth2wormhole-client: use fresh blockhashes, harden batch errors

This commit makes sure we don't have to deal with expired transactions
due to stale blockhashes. The problem existed with larger symbol
configs as well as on Solana mainnet. Additionally, the attestation logic
now treats transaction errors as non-critical - a failure for a batch
does not prevent attestation attempts for batches farther in the queue

commit-id:5e704f8b
2022-02-23 19:12:16 +01:00
Csongor Kiss 3a24a26a7d eth deploy updates 2022-02-10 15:37:19 -05:00
Csongor Kiss 3484921b70 ethereum: Add fantom testnet & aurora testnet to truffle-config 2022-02-09 16:07:57 -05:00
valentin 7e2cf1f981 pyth data bridge target chain module for EVM
Change-Id: Ieaeed6374e72a5348e05c40bd25598b74061a9a0
2021-09-16 13:46:51 +00:00
Hendrik Hofstadt 6ff21f8d01 add ethereum NFT bridge
Change-Id: I5cc8cfe431f5f9b043adc7baf662760ffe9e7a35
2021-09-10 23:43:14 +00:00
valentin 45d22ce84f bridge: move evm state setup into a separate contract
Change-Id: Ibc790ba971be5144c0af65870d424c9c62b52039
2021-08-19 10:19:40 +00:00
valentin a055af1416 move EVM state setup into a seperate contract
Change-Id: Ie000dd042c4ebbd7084511d38d87a7555c5d8048
2021-08-19 10:19:26 +00:00
valentin 2e6a93b643 ethereum token bridge on wormhole
Change-Id: Iab8d6f6aae6163d1c65f7d5a7395a943c62cdb0c
2021-07-21 14:11:58 +00:00
valentin 58fd2bcbcb clean up deployment & add etherscan verification
Change-Id: Idd37f92c5ca61710bece77a473fad35af44ac8f9
2021-07-20 20:54:27 +00:00
Hendrik Hofstadt f665fe4c7b Fix signature schema and use a single initial guardian in ETH
Change-Id: Ia1995df4ed8f86443cdd62acee7914ffc745d407
2021-07-02 10:48:54 +00:00
valentin c3fa835196 ethereum generalized messaging & governance
Change-Id: I412111a10749050ca095458f2fcfe81ce0fe189c
2021-05-27 16:01:49 +02:00
Leo c31777d1b3 e2e: add bidirectional end-to-end tests 2020-11-29 17:07:15 +01:00
Leo 13f79a96b3 devnet: use real account and nonce for send-lockups.js
ghstack-source-id: fb233fa727
Pull Request resolved: https://github.com/certusone/wormhole/pull/61
2020-10-28 22:47:12 +01:00
Hendrik Hofstadt 59449a30b3 Update VAA structure 2020-08-19 16:41:25 +02:00
Leo dc7a2147b7 devnet: fix generation of deterministic contract addresses
We previously had an extra contract that was deleted, which
changed the contract addresses.

As a workaround, deploy Wormhole twice to fix the tests.
2020-08-17 12:03:16 +02:00
Leo f8b313cab8 ethereum: remove unused Schnorr references from tests 2020-08-16 01:54:49 +02:00
Hendrik Hofstadt 6e5a3fa118 Update ETH smart contract for new signature schema 2020-08-15 00:09:48 +02:00
Hendrik Hofstadt 6e0fe64937 Add smart contract tests 2020-08-06 23:32:31 +02:00