Commit Graph

112 Commits

Author SHA1 Message Date
Chirantan Ekbote 1753bb34f0 Send re-observation request when re-broadcasting local observations
Currently if an observation hasn't reached quorum within 5 minutes, the
processor will re-broadcast the signed local observation to the other
guardians in the network. However if not enough guardians actually
observed the original tx, then no amount of re-broadcasting will help
the network reach quorum.

Fix this issue by sending a re-observation request whenever we
re-broadcast a signed local observation.  This ensures that any
guardians that missed the tx the first time it happened have a chance to
re-observe it and help the network reach quorum.
2022-08-24 17:59:42 +09:00
Paul Noel eae0b51d37
Algorand mainnet deploy (#1434)
* algorand mainnet deploy

* Changes to sdk/js

* Update sdk changlog

Co-authored-by: Bruce Riley <briley@jumptrading.com>
2022-08-16 10:14:48 -05:00
bruce-riley 99fb46d549
Don't allow obs reqs if the queue is full (#1429)
Change-Id: Ifb0d038fa3adeddc6226e2289fe9dbfc8e39b4e7
2022-08-15 07:33:45 -05:00
jumpsiegel 3f965da33b
node: add near support (#1397)
* node: add near support

* Tweaks suggested in zoom review

Co-authored-by: Bruce Riley <briley@jumptrading.com>
2022-08-05 13:49:16 -04:00
Evan Gray e0fd3e788f
node: pythnet testnet support (#1380) 2022-07-28 12:30:00 -05:00
bruce-riley 7402259fc7
Chain governor (#1277)
* Rebase

* Reload from db on start up

Change-Id: I1deac9db28ad1157ea7e0c84af41c35b38497f4e

* Console commands

Change-Id: Ic242038312b7c837443a2df8823f100b3cdffd77

* Query prices from CoinGecko

Change-Id: I9a8c282ba374d32ef7045d11979a27ede3c52827

* Move chain config to separate file

Change-Id: I6a790eca765bce1f2caf48134e225df5c4daff15

* More code cleanup

Change-Id: Id12affa78cdc2d394d6dab0c53bb7ad06df8007e

* Few minor tweaks

Change-Id: I6cb511599d669e0b3d716d9f314ac0f26935ee92

* Create separate tests for different packages

Change-Id: Idb4da6817c9daad2a7420abc11bdaa702ae056dc

* Fix lint errors

Change-Id: I137c9e7e4574aee9c9fec22e91e19eee0e86a349

* Simplify chainlock message tests

* Add more governor db test coverage

* Next batch of review rework

Change-Id: Ife54852fca6c6990d1ffb3d60a8dd7f49d526f0a

* Still more rework

Change-Id: I43a8aa7fa4e1a7cea4d7fde68c963123c1ca8d53

* More rework

Change-Id: I9382412af4ffeda74967a834a6b0195a9d28b720

* Fix lint errors

Change-Id: Idaafce9b0314192557b7207911375d000bac5ae2

* Add rest and prometheus support

Change-Id: Ib870ed7eb305ef1ebbf6a7cedabc665c37c19171

* Add separate configs for testnet and devnet

Change-Id: I76b11d8940a8dc9935b3f276a008ed20ef60b850

* Update mainnet tokens to fix decimals

Change-Id: Iab018827766bc7748038b7be2f51342afb79b87c

* Let small enqueued VAAs go out when big ones can't

Change-Id: I7d3ef88d4579702d0c6ff4eaf5a8524799610ff6

* Tweak testnet config parameters

Change-Id: Id2c54151a7183ab3fb4af8060929198f6021ba4e

* Rework / enhancements from testnet testing

Change-Id: I1387b1d22667fa6ffe0bb1832dbc0b31196505d3

* Use known emitter maps

Change-Id: If330ee9d30ac3c2d1c6dca674f7777dc759de230

* Fix typo and out of date comments

Change-Id: I54a19792104ccc6ca023020303a710ef3ba18f74

Co-authored-by: claudijd <jclaudius@jumptrading.com>
2022-07-19 14:08:06 -04:00
Jeff Schroeder deeabc096d
Update injective url/s (#1350)
* node/pkg/terra: remove setEvents

The guardian set should only be authoritative from ethereum, so having
this code in the terra watcher is unnecessary. Getting this information
on injective requires a few more hoops to jump through but it is never
used. It is easier to maintain less code, so remove it.

* node/cmd/guardiand: remove setEvents from cosmwasm

This removes the set events from:

* terra 2
* injective
* terra classic

* node/pkg/terra: don't query guardianset from cosmwasm

* node/pkg/terra: support injective

* node/pkg/terra: update queryLatency metric

To show the query latency of fetching the latest block height from rpc
2022-07-14 13:41:31 -04:00
Evan Gray 59fd0d36c7 node: optional chains in tilt 2022-07-11 10:35:00 -04:00
Csongor Kiss f856240792
node: Prepare development binary release (#1332)
* node: Shrink final docker image size

* Tiltfile: guardiand should run the build stage

* node: allow building without -race

* node: Support development builds

A development build must use the --unsafeDevMode flag.

* CI: build docker image

Co-authored-by: Csongor Kiss <ckiss@jumptrading.com>
2022-07-06 19:27:49 +01:00
bruce-riley d7b7cefa99
Guardian support for Injective (#1327) 2022-07-06 10:19:57 -04:00
Bruce Riley b96ba36d25 Terra2 Mainnet Guardian Changes 2022-06-22 11:12:30 -04:00
Evan Gray 5931368ed7 node: terra2 support 2022-06-21 10:47:16 -04:00
bruce-riley 24c5b17267
Neon to testnet (#1262)
* WIP: neon

* Watcher support

* Use eth_getLogs for Neon

* bridge_ui: update sdk version

* Setting WETH address for Neon

* Portal bridge support for WNEON

* relayer: update sdk

Co-authored-by: Evan Gray <battledingo@gmail.com>
2022-06-14 10:22:49 -04:00
Bruce Riley d6f4740136 Undo formatting changes 2022-06-07 10:36:12 -04:00
Bruce Riley 0ac89c3c06 Move polygon stuff to a different branch 2022-06-07 10:36:12 -04:00
Bruce Riley cf4722a546 Refactor to generalize polling
Change-Id: Ie30056486ec86f6dceffed231ac227fa9c3499a7
2022-06-07 10:36:12 -04:00
Bruce Riley 5562141599 Only require 64 confs in polygon testnet 2022-06-06 12:49:44 -04:00
Bruce Riley dcce155f43 Acala mainnet deploy 2022-06-03 14:44:22 -04:00
tbjump 1c2a70554b
supress gosec issue (#1216)
supress gosec issue
2022-05-23 11:25:24 +02:00
bruce-riley 018908a420
Klaytn mainnet deploy (#1185)
* Klaytn mainnet deploy
2022-05-16 10:06:17 -04:00
Bruce Riley d266438654 Celo mainnet deploy changes 2022-05-13 13:11:28 -04:00
Josh Siegel c9d7a617ee Rewrite algorand guardian watcher to directly hit the node instead of depending on indexer 2022-05-12 06:50:07 -05:00
bruce-riley c7ba459de8
Moonbeam to testnet (#1150)
* Moonbeam to testnet

* Fix typo

* Shouldn't touch the CLI with this PR

* Update SDK version
2022-05-10 11:23:07 -04:00
bruce-riley a94a3cf2fb
Karura mainnet deploy (#1142)
* Start of move to mainnet

* Rework to safe mode check

* Update truffle-config

* Should not check safe mode in dev mode
2022-05-02 14:28:17 -04:00
Evan Gray 1229ca5cff algo: guardian 2022-04-29 20:56:46 -04:00
bruce-riley d04328b858
Celo testnet support (#1051)
* Initial Celo support

Change-Id: Iee98ee29a8b09af9ca76945792b750d96a170702

* Watcher support

* Fix high level make file

* Remove node binary committed by mistake

* Port change from EthWatcher to CeloWatcher

* Use docker to build ABIs

* Refactor watcher to eliminate massive redunancy

* Fix lint-and-tests to handle multiple defs on link

* Minor code cleanup

* Celo should use ganache in devnet

* Prep for mainnet deploy

* Code review rework

* Remove celo from sdk package.json
2022-04-28 12:20:38 -04:00
Bruce Riley 10f00b934b Promote Aurora to Mainnet 2022-04-11 17:05:07 -04:00
bruce-riley 879670c0e5
Klaytn testnet support (#1038)
* Klaytn support for testnet

Change-Id: Id0647fd6c603ab298f860c2cae20481555467315

* token_bridge client changes

Change-Id: If49ba994a67041044bdec054f19e69b4cfc2785b

* Get rid of special handling

* More cleanup

* Need to add Klaytn to structs tests

* Update SDK version

* Add SDK version

* fix klaytn bridge chain id

Co-authored-by: Evan Gray <battledingo@gmail.com>
2022-04-04 18:11:03 -04:00
bruce-riley eb898b0555
Aurora and Fantom handled wrong in a couple cases in guardian (#1044)
* Aurora and Fantom handled wrong in a couple cases

Change-Id: I09b7d2da46507e219bd99d945256e63fefad529c

* Original test covered upper / lower case

Change-Id: I0384b0aac6f63bf9782d393fcd4e4e67f353775a
2022-04-04 15:08:16 -04:00
bruce-riley b718225e45
Testnet support for Aurora (#947)
* Testnet support

* Upgrade contract for 1conf

* Formatting changes

Change-Id: Id06481d77d770a04eb200aadb82574e23cddcd36
2022-03-15 10:41:10 -04:00
bruce-riley d1da11785f
Karura and Acala support (#862)
* Karura and Acala support

Change-Id: I74c88b9b7a220e419e31a11cf77931343c9a8159

* env files got dropped

Change-Id: If330887782a4e38f3419dff2efcc100a5949d3f2

* Updates for latest parameters

Change-Id: Ie25f377f6d70dfb7d4b28efabd4064088e001c0a
2022-03-03 16:40:32 -05:00
Jeff Schroeder fd96dced3a
Fantom updates (#928)
* node: Add fantom to guardiand admin list-nodes

* node: check fantom readiness for mainnet
2022-03-01 20:32:31 -05:00
bruce-riley 60363dd3d1
Fantom deploy (#920)
* Truffle changes

* Always require fantomRPC
2022-02-28 16:32:22 -05:00
Jeff Schroeder b54b7e1183 node: add fantom support
Only run in testnet until the contracts are deployed to mainnet.
2022-02-15 13:51:11 -05:00
Evan Gray 9ed71c0038 node: terra reobservation 2022-02-12 15:03:32 +01:00
Leo c28b492e03 node: add reobservation requests for Eth chains
commit-id:e4fa6adf
2022-02-12 01:06:06 +01:00
Leo 7ae4b3d6aa node: increase Polygon minimum confirmation to 512
It appears that in spite of exceeding the recommended value by 2x,
256 offers insufficient safety margin given that we saw two reorgs
of depths 178 and 187 recently: https://polygonscan.com/blocks_forked

This will increase confirmation delay from ~10 minutes to ~20 minutes.

commit-id:cf2b1503
2022-02-08 17:39:53 +01:00
Leo 73a5b72857 node: implement observation requests via gossip
Limitations:

- Only supported for Solana and for confirmation level Finalized,
  which the token/NFT bridges use. Need to take a close look before
  enabling it for both (since we're bypassing the tx fetcher and would
  fetch and process accounts of the "wrong" confirmation levels).

- Rate limiting not implemented yet, will be done in a future release
  when things are not currently on fire.

Test: https://gist.github.com/leoluk/bab3a18e922057109facea1cf1f26b2f

commit-id:6a0d4c32
2022-01-26 13:00:23 +01:00
Leo b8c30314b5 node: avoid clobbering terminal with binary data
commit-id:222d1f31
2022-01-25 22:36:24 +01:00
Leo af2bd5be36 node/cmd: add public telemetry for logs
commit-id:582fc943
2022-01-11 15:10:12 +01:00
Leo 81d1e821c0 node/pkg/ethereum: minimum confirmations for Polygon
commit-id:0d95a63c
2022-01-11 15:10:12 +01:00
Leo ab18f278fe node/cmd: use plain global root logger
Get our own root logger and pass that to ipfslog. Prerequisite for
getting fancy about using Zap plugins.

commit-id:ad22324d
2022-01-11 15:10:12 +01:00
jumpsiegel f90ed66ca0
Stub out algorand support in wormhole (#611)
* Stub out algorand support in wormhole

  1) Introduce the algorand chain constant in all the appropriate places
  2) Deploy pyth/hernandc algorand smart contracts into devnet
  3) Fund all the correct contracts for devnet testing

Change-Id: I6e4402b5b21223b32ea89653f8c7606f5c7f2843

* pr/jsiegel/algorand-v1: ALGORAND is not a EVM chain @ gusc1a-ossdev-jsl1

* pr/jsiegel/algorand-v1: fix lint @ gusc1a-ossdev-jsl1

* pr/jsiegel/algorand-v1: put the requirements into the image @ gusc1a-ossdev-jsl1

* jsiegel/algorand: make the watcher hang forever @ gusc1a-ossdev-jsl1

* jsiegel/algorand: comment these out @ gusc1a-ossdev-jsl1

* jsiegel/algorand: put this back in @ gusc1a-ossdev-jsl1

* jsiegel/algorand: fix guardian example @ gusc1a-ossdev-jsl1

* Generate teal source code

commit-id:a537a109

* jsiegel/algorand: it builds @ gusc1a-ossdev-jsl1

* pr/jsiegel/algorand-v1: add Dockerfile.teal @ gusc1a-ossdev-jsl1

* jsiegel/algorand: improve the dependencies @ gusc1a-ossdev-jsl1

* pr/jsiegel/algorand-v1: Fix up build @ gusc1a-ossdev-jsl1

* dead file

* pr/jsiegel/algorand-v1: remove more stuff @ gusc1a-ossdev-jsl1

* pr/jsiegel/algorand-v1: fix build @ gusc1a-ossdev-jsl1

* pr/jsiegel/algorand-v1: freeze the requirements @ gusc1a-ossdev-jsl1

* pr/jsiegel/algorand-v1: Fix teal to use pipenv @ gusc1a-ossdev-jsl1

* pr/jsiegel/algorand-v1: fix miss-merge @ gusc1a-ossdev-jsl1

Co-authored-by: Leo <leo@certus.one>
2021-12-22 11:22:04 -05:00
Leo 17508ff29c Revert "node: move oasis to testnet mode"
This reverts commit 9ad792c6ee.

commit-id:896988bd
2021-12-21 22:00:15 +01:00
Leo 9ad792c6ee node: move oasis to testnet mode
We're not ready to release this yet.

commit-id:c2d6531f
2021-12-21 21:01:47 +01:00
Leo 3c1ee3bdc3 node: add oasis support
commit-id:31eeeb35
2021-12-20 20:57:11 +01:00
justinschuldt 024ced81d9 PubSub infra for bigtable data enrichment
Change-Id: Ide08774960ad7e9dee04090bc990be49357c79a2

commit-id:928fad6e
2021-12-20 16:56:56 +01:00
Leo 2a7c32ca3f node: re-observe backfilled VAAs
commit-id:8a9af802
2021-12-20 16:05:22 +01:00
Leo 537d56b37a devnet: avalanche fix
commit-id:3ab70784
2021-12-15 00:16:18 +01:00
Leo e950bb831a node: enabled avalanche on mainnet
commit-id:45e694bd
2021-12-15 00:00:31 +01:00
Leo 864e983e04 node: add avalanche support in testnet mode
Change-Id: Icdf6c26187547d1b1929e43530beeec17c142e3f
2021-12-10 11:48:03 +00:00
Leo bc48b1b51d node: add spy service
Change-Id: Ieb04e6d26c7778d8a8afbbeaee79d764d9f2cd31
2021-12-03 02:01:56 +01:00
Leo 8800d7bfd3 *: add ropsten chainID and guardiand implementation
Change-Id: Ib99316c28237d946eb2b6d013f4e275a620d4aa8
2021-11-22 22:32:36 +00:00
Leo 964566c559 node/cmd: add missing bsc and polygon readiness registrations
This would cause the readiness check to not detect failures.

Change-Id: I7f38e8a201929bb10a71bc707a3513b565b05960
2021-10-29 19:08:45 +00:00
Leo 9ba59fa2b2 node/cmd: fix infura warnings
The string can appear anywhere.

Change-Id: Ib45acc8e3b24308446434b29a709ebf532bcb30a
2021-10-27 14:20:02 +00:00
Leo c64576cc0b node: add Polygon support
Change-Id: Ia919861879eb6c831d4dd9ccbe1748e7123502e5
2021-10-21 10:11:21 +00:00
Leo f275823461 node/cmd: blacklist mainnet.infura.io
Change-Id: I13335a80ba7b241beca30737384114b0e7b771c4
2021-10-19 14:29:23 +00:00
Leo 659b7b2547 node: add Discord notifications for missing signatures
Change-Id: If09643c2e02c4c166577082cd9be9124d2e775d4
2021-10-06 14:12:21 +02:00
Leo bd5f957e1b node: remove unused terraChainID command line flag
Change-Id: I5f02faa3f00098725e7242c289f65978c4879c3c
2021-10-03 21:03:43 +02:00
Leo 7914512797 node: handle inbound SignedVAAWithQuorum messages
Change-Id: I539155bb4e59d728ea528e6e2f70b6fbb3338a41
2021-09-13 17:51:47 +00:00
Leo 9a85dbafe5 Add Go linting stage to CI
rustfmt appears to be a little more complicated since it wants to
download dependencies and needs nightly Rust.

Change-Id: Ia348def30a6459ae2ab6c29a8c3a413216f5eb4b
2021-08-31 08:58:17 +00:00
Leo 4ac19518bd node: remove remaining "bridge" mentions
Ensure there's no core vs. token bridge ambiguity.

Breaking changes to the CLI:

* "guardiand bridge" CLI is now "guardiand node"
* --solanaBridgeAddress is now --solanaContract
* --bridgeKey is now --guardianKey

The Heartbeat proto message had one of its fields renamed from
BridgeAddress to ContractAddress, but this won't break the wire
format and the only consumer appears to be the CLI.

Change includes a "go mod tidy" - it insisted.

Change-Id: Id8b312827737f07f2d5f3944ebce469d946e7f51
2021-08-31 08:58:17 +00:00