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

Feature/powpeg validation protocol integration #374

Open
wants to merge 112 commits into
base: master
Choose a base branch
from

Conversation

julia-zack
Copy link
Contributor

@julia-zack julia-zack commented Jan 10, 2025

Changes needed to implement SVP, described in RSKIP419

Description

Implementation of the Powpeg Spendability Validation Protocol, as described in RSKIP419

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)

rskj:feature/powpeg_validation_protocol-integration
rit:disable-rskip419

Copy link

github-actions bot commented Jan 10, 2025

Dependency Review

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

OpenSSF Scorecard

PackageVersionScoreDetails

Scanned Manifest Files

@marcos-iov marcos-iov force-pushed the feature/powpeg_validation_protocol-integration branch from 00b0319 to dbd0236 Compare January 10, 2025 20:36
TransactionListener listener = watched.getListener();
Wallet watchedFederationWallet = new BridgeBtcWallet(btcContextThin, Collections.singletonList(watchedFederation));

if (PegUtilsLegacy.isValidPegInTx(btcTx, watchedFederation, watchedFederationWallet, bridgeConstants, federatorSupport.getConfigForBestBlock())) {

Check notice

Code scanning / CodeQL

Deprecated method or constructor invocation Note

Invoking
PegUtilsLegacy.isValidPegInTx
should be avoided because it has been deprecated.
listener.onTransaction(tx);
}

if (PegUtilsLegacy.isPegOutTx(btcTx, Collections.singletonList(watchedFederation), federatorSupport.getConfigForBestBlock())) {

Check notice

Code scanning / CodeQL

Deprecated method or constructor invocation Note

Invoking
PegUtilsLegacy.isPegOutTx
should be avoided because it has been deprecated.
* </p>
*
* @param currentBlockNumber the current block number in the blockchain
* @param svpTxHash the Keccak256 hash of the svp spend transaction waiting to be signed

Check notice

Code scanning / CodeQL

Spurious Javadoc @param tags Note

@param tag "svpTxHash" does not match any actual parameter of method "isSVPSpendTxReadyToSign()".
Federation expectedFederation = createP2shErpFederation(
getFederationMembersFromPks(1, 1000, 2000, 3000, 4000, 5000));
Address expectedFederationAddress = expectedFederation.getAddress();
Integer federationSize = 5;

Check warning

Code scanning / CodeQL

Boxed variable is never null Warning test

The variable 'federationSize' is only assigned values of primitive type and is never 'null', but it is declared with the boxed type 'Integer'.
@marcos-iov marcos-iov force-pushed the feature/powpeg_validation_protocol-integration branch from dbd0236 to 1fa8546 Compare January 15, 2025 14:24
@marcos-iov marcos-iov marked this pull request as ready for review January 15, 2025 14:24
@marcos-iov marcos-iov requested a review from a team as a code owner January 15, 2025 14:24
@marcos-iov marcos-iov force-pushed the feature/powpeg_validation_protocol-integration branch from 1fa8546 to 7aaee31 Compare January 15, 2025 17:19
…rt of new federationa and fix the rest of exisiting tests to accomdate new condition
apancorb and others added 28 commits January 17, 2025 12:35
…e to build federation after validating the federation size
@marcos-iov marcos-iov force-pushed the feature/powpeg_validation_protocol-integration branch from 7aaee31 to 7231fa9 Compare January 17, 2025 15:35
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.

2 participants