Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add validation for complete-deposit transactions #545

Open
wants to merge 12 commits into
base: main
Choose a base branch
from

Conversation

djordon
Copy link
Contributor

@djordon djordon commented Sep 18, 2024

Description

Closes #479.

Changes

  • Change the AsContractCall::validate function to have a different signature.
  • Implement the CompleteDepositV1::validate function.
  • Added some fields to the CompleteDepositV1 struct. These new parameters should be used in the contract call once feat: check against known burn hash when completing deposit #493 gets updated and lands.
  • Fix a bunch of random typos that I spotted.

Note that when #543 gets done we'll probably want to add another integration test, but the logic introduced here should be correct and won't need much updating (famous last words).

Testing Information

This PR adds integration tests that checks for each of the failure modes in the function.

Checklist:

  • I have performed a self-review of my code

@djordon djordon added the sbtc bootstrap signer The sBTC Bootstrap Signer. label Sep 18, 2024
@djordon
Copy link
Contributor Author

djordon commented Sep 18, 2024

These sporadic errors seem to be unrelated to the changes in this PR.

@djordon djordon changed the title feat: implement validate for complete-deposit transactions feat: add validation for complete-deposit transactions Sep 18, 2024
@djordon
Copy link
Contributor Author

djordon commented Sep 19, 2024

Ugh, I forgot to check the signer bitmap. Will update tomorrow.

There is no bitmap, I'm going to bed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
sbtc bootstrap signer The sBTC Bootstrap Signer.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Feature]: Validate complete-deposit-wrapper contract calls
1 participant