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] Implement P2WSH tests/logic #250

Closed
b-j-roberts opened this issue Oct 4, 2024 · 5 comments · Fixed by #279
Closed

[feat] Implement P2WSH tests/logic #250

b-j-roberts opened this issue Oct 4, 2024 · 5 comments · Fixed by #279
Assignees
Labels

Comments

@b-j-roberts
Copy link
Contributor

Bitcoin has many different transaction types, one of them being P2WSH.

In order to support these, we will need to make sure all edge cases and some mainnet P2WSH transactions can successfully be validated by Shinigami.

Since Shinigami's design is heavily inspired by btcd, I recommend looking through all the witness transaction logic there and replicating it inside Shinigami's engine, where needed. Many witness features are implemented, but notably witness signature calculation is not done in OP_CHECKSIG/OP_CHECKMULTISIG/...
The learnmeabitcoin link can be super helpful in understanding Bitcoin P2WSH transactions in depth.

Then, using the learnmeabitcoin P2WSH examples and existing Shinigami transaction tests, create a set of tests to ensure all P2WSH transactions run properly.

Resources

learnmeabitcoin P2WSH
Existing P2PK & P2PKH tests in Shinigami
witness sig btcd

@Kaminar-i
Copy link

hello @b-j-roberts i would love to work on this issue :)

@CollinsC1O
Copy link

Hello @b-j-roberts I'm a front-end and a blockchain developer. I will love to work on this

@manlikeHB
Copy link
Contributor

Hi @b-j-roberts, can I work on this?

@augustin-v
Copy link

Hello, I have experience contributing to Kakarot zkEVM and I would love to spend time on this issue

@ptisserand
Copy link
Contributor

Hi @b-j-roberts can I work on this ?

@ptisserand ptisserand mentioned this issue Oct 18, 2024
3 tasks
b-j-roberts added a commit that referenced this issue Oct 20, 2024
<!-- enter the gh issue after hash -->

- [x] issue #250 
- [x] follows contribution
[guide](https://github.com/keep-starknet-strange/shinigami/blob/main/CONTRIBUTING.md)
- [x] code change includes tests

<!-- PR description below -->
Add tests for P2WSH:
- transaction validation is OK
- script execution failed 
- wrong hash for witness script

---------

Co-authored-by: Brandon Roberts <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants