-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
staking: verify staking/slashing tx relationship in staking requests (#…
…46) First step of #7 This PR adds verification on the relationship between staking/slashing tx in staking requests using `babylon_btcstaking::tx_verify::check_transactions`. This also involves further refactoring of datagen library, and a bug fix in taproot pk script generation where we mistakenly used secp256k1 FFI that bloats contract size. NOTE: this PR still results in a wasm contract slightly bigger than the standard 800 KB. There are two ways to go ahead before optimisation is in place: 1. merge it into a feature branch for full validation for now, optimise in subsequent PRs, or 2. merge it into `main`, but before that add a Rust feature to allow to enable/disable the full validation I'm inclined to 2 but open to other ideas cc @maurolacy @gusin13 --- TODOs before ready: - [x] fixing size of BTC staking contract (current it's 1.9MB) - [x] making all tests use corresponding parameters in [datagen](https://github.com/babylonlabs-io/babylon-contract/blob/647b1f4f16a8b37f3d5a11a543cdb093f2d7d830/datagen/utils/btcstaking.go)
- Loading branch information
1 parent
a36f194
commit 187839b
Showing
44 changed files
with
491 additions
and
301 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.