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

Ignore non-standard outputs when searching for the witness commitment hash #2931

Merged
merged 9 commits into from
Jan 27, 2025

Conversation

nathanieliov
Copy link
Contributor

@nathanieliov nathanieliov commented Jan 13, 2025

Ignore non-standard outputs when searching for the witness commitment hash.

## Motivation and Context

Coinbase transactions may sometimes contain non-standard outputs that cause the Bridge to fail parsing them. When iterating through the outputs of a coinbase transaction in search for the witness commitment hash, non-standard outputs should be ignored and continue searching through the remaining outputs.

How Has This Been Tested?

Unit tests

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)

Checklist:

  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • Tests for the changes have been added (for bug fixes / features)
  • Requires Activation Code (Hard Fork)

fed:coinbase-parsing-integration-rebased

Copy link

github-actions bot commented Jan 13, 2025

Dependency Review

✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.

OpenSSF Scorecard

PackageVersionScoreDetails

Scanned Manifest Files

@nathanieliov nathanieliov force-pushed the coinbase-parsing-integration-rebased branch from c66a50b to 37f8fba Compare January 13, 2025 15:51
@nathanieliov nathanieliov marked this pull request as ready for review January 13, 2025 15:52
@nathanieliov nathanieliov requested a review from a team as a code owner January 13, 2025 15:52
@marcos-iov marcos-iov force-pushed the invalid-pegin-as-processed-integration-rebased branch from b877d0a to da9c490 Compare January 13, 2025 19:38
@nathanieliov nathanieliov force-pushed the coinbase-parsing-integration-rebased branch from 37f8fba to c6b323f Compare January 14, 2025 02:14
@nathanieliov nathanieliov force-pushed the invalid-pegin-as-processed-integration-rebased branch from da9c490 to 34a2c25 Compare January 15, 2025 16:06
@nathanieliov nathanieliov force-pushed the coinbase-parsing-integration-rebased branch from c6b323f to 4a022ab Compare January 15, 2025 16:11
@marcos-iov marcos-iov force-pushed the invalid-pegin-as-processed-integration-rebased branch from 34a2c25 to 326de39 Compare January 24, 2025 17:51
@marcos-iov marcos-iov force-pushed the coinbase-parsing-integration-rebased branch from 545c46b to eeb4d41 Compare January 24, 2025 17:55
@marcos-iov marcos-iov force-pushed the invalid-pegin-as-processed-integration-rebased branch from 326de39 to 7b48c64 Compare January 24, 2025 18:47
Base automatically changed from invalid-pegin-as-processed-integration-rebased to master January 24, 2025 20:14
@marcos-iov marcos-iov force-pushed the coinbase-parsing-integration-rebased branch from eeb4d41 to 5be57f3 Compare January 24, 2025 20:17
marcos-iov and others added 9 commits January 27, 2025 10:34
…460 activation

- Add real cases testing malformed mainnet and testnet coinbase transaction
- Get rid of use of BtcTransaction. findWitnessCommitment since this method was removed in the new bitcoinj thin version.
…d exceptions.

- Use all activations instead of lovell
…om script bytes removing parsing operation from the logic

- Add border test case
@marcos-iov marcos-iov force-pushed the coinbase-parsing-integration-rebased branch from 57b7a3b to 43a94d9 Compare January 27, 2025 13:34
Copy link

Quality Gate Failed Quality Gate failed

Failed conditions
C Maintainability Rating on New Code (required ≥ A)

See analysis details on SonarQube Cloud

Catch issues before they fail your Quality Gate with our IDE extension SonarQube for IDE

@Vovchyk Vovchyk merged commit 03bd0cd into master Jan 27, 2025
12 of 13 checks passed
@Vovchyk Vovchyk deleted the coinbase-parsing-integration-rebased branch January 27, 2025 14:24
@aeidelman aeidelman added this to the Lovell 7.0.0 milestone Jan 28, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants