Skip to content

Use proTxHash instead of outpoint when calculating masternode scores#2440

Merged
UdjinM6 merged 5 commits into
dashpay:developfrom
codablock:pr_dip3_quorums
Nov 13, 2018
Merged

Use proTxHash instead of outpoint when calculating masternode scores#2440
UdjinM6 merged 5 commits into
dashpay:developfrom
codablock:pr_dip3_quorums

Conversation

@codablock
Copy link
Copy Markdown

See individual commits.

Turned out that SPV clients are currently unable to calculate quorums on their own as the collateral outpoint was not part of DIP4. Instead of adding the outpoint to DIP4, we decided to use the proTxHash for these calculations.

This also required to reimplement the protection against hash grinding of collaterals (which would now be for proTxHash). This means, we track the confirmedHash (+15 blocks after registration on mainnet) for each MN now and take this into the score calculation. The confirmedHash is also added to DIP4 so that SPV clients have all data necessary to calculate quorums.

@UdjinM6 UdjinM6 added this to the 13.0 milestone Nov 13, 2018
Copy link
Copy Markdown

@UdjinM6 UdjinM6 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

utACK, travis seems to be (relatively) happy as well

@UdjinM6 UdjinM6 merged commit 4ad2f64 into dashpay:develop Nov 13, 2018
@codablock codablock deleted the pr_dip3_quorums branch November 13, 2018 13:14
Copy link
Copy Markdown
Member

@PastaPastaPasta PastaPastaPasta left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Post merge utack

CryptoCentric pushed a commit to absolute-community/absolute that referenced this pull request Jun 29, 2020
…ashpay#2440)

* Track confirmedHash of masternodes

* Also include confirmedHash in DIP4

* Implement CalculateQuorum and CalculateScores in CDeterministicMNList

* Use new ProRegTx based scoring function in GetMasternodeScores

* Update test vectors for simplifiedmns_merkleroots tests
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.

3 participants