-
Notifications
You must be signed in to change notification settings - Fork 714
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
[Consensus] New signatures for network messages #1024
[Consensus] New signatures for network messages #1024
Conversation
1af0a9b
to
d37a0de
Compare
7c48935
to
f47447a
Compare
813857e
to
14f5d67
Compare
so mnb can still be signed on Ledger HW wallets which can sign only ASCII encoded messages.
serialize/unserialize nMessVersion at the end
2a86311
to
7f93bd9
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have created some masternodes, budget proposals and checked if they were properly created, voted on and finalized for some budget-cycles.
Everything went well, just some minor hickups which aren't related to this PR and will be addressed separately,
Summary:
- masternode payment winner -> works
- masternode ping -> works
- budget vote -> works
- finalized budget vote -> works
- consensus vote -> works
- masternode broadcast -> works
- obfuscation relay -> this seems to be dead code
- spork message -> not tested because I don't have the latest spork-key
ACK from my side.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ACK 7f93bd9
7f93bd9 [Trivial] Fix error messages: Setkey -> GetKeysFromSecret (random-zebra) 152d384 [Trivial][Cleanup] fix a few log lines (random-zebra) d7b8db0 [RPC] decodemasternodebroadcast: add nMessVersion field for MNB and MNP (random-zebra) 640c3c1 [Bug] Fix messages serialization for version MESS_VER_STRMESS (random-zebra) 1d54b41 [Core] mnb: sign the hex representation of the double hash of the data (random-zebra) e4099bd [RPC] Refactor masternode start/broadcast (random-zebra) d6eb7a4 [RPC] fix startmasternode "alias/missing" relay (random-zebra) 9ab844a [Fix] mnp sigtime and signature check for mnb in CheckAndUpdate (random-zebra) 1db4fe2 [Trivial] better log for CHashSigner::VerifyHash failures (random-zebra) 0c86ed6 [Fix] default public key for mnb (random-zebra) d4b0d9d [Fix] remove CMasternode explicit constructor from mnb (random-zebra) 8d04cd5 [Fix] Double signatures swap in CMasternode (random-zebra) f01e28e [Consensus] fNewSigs always defaults to false (random-zebra) 294ab82 [Refactor] CSignedMessage parent of CSporkMessage (random-zebra) 9e77217 [Refactor] CSignedMessage parent of CObfuscationRelay (random-zebra) 3b4f2ed [Refactor] CSignedMessage parent of CConsensusVote (random-zebra) d0c1215 [Refactor] Abstract GetPublicKey in CSignedMessage (random-zebra) 37f8629 [Refactor] CSignedMessage parent of CBudgetVote/CFinalizedBudgetVote (random-zebra) a36db49 [Refactor] CSignedMessage parent of CMasternodePaymentWinner (random-zebra) 73bc65f [Refactor] CSignedMessage parent of CMasternode and CMasternodePing (random-zebra) a4cee54 [Refactor] define CSignedMessage parent class (random-zebra) d091f25 [Consensus] Reject old message versions for CSporkMessage (random-zebra) 95689d4 [Consensus] Reject old message versions for CMasternodePaymentWinner (random-zebra) c752a96 [Consensus] add nMessVersion to signature hash (random-zebra) 4051846 [Core] Add a field 'nMessVersion' to signed messages (random-zebra) 75f24d3 [Refactor] CFinalizedBudget/Broadcast cleanup constructors (random-zebra) e45836d [Core] make signatures private variables in their classes (random-zebra) 34d59e8 [Consensus] New signature for CSporkMessage (random-zebra) 228b783 [Consensus] New signature for CObfuScationRelay (random-zebra) b3bce53 [Trivial] rename mnb: sig --> vchSig, VerifySignature --> CheckSignature (random-zebra) e2a6ae2 [Consensus] New signature for CMasternodeBroadcast (random-zebra) 567b4b1 [Trivial] Align the format of the log messages (random-zebra) 3535544 [Trivial] CConsensusVote: rename SignatureValid() to CheckSignature() (random-zebra) 3916a0c [Consensus] New signature for CConsensusVote (SwiftX) (random-zebra) a4ac445 [Trivial] constructors with arg list for BV and FBV (random-zebra) f8966a7 [Trivial] FBV: rename SignatureValid() to CheckSignature() (random-zebra) 61b1824 [Consensus] New signature for CFinalizedBudgetVote (random-zebra) ac517dc [Trivial] CBudgetVote: rename SignatureValid() to CheckSignature() (random-zebra) 0171209 [Consensus] New signature for CBudgetVote (random-zebra) b30da1c [Consensus] Include blockhash in CMasternodePing hash (random-zebra) 44edf2d [Consensus] New signature for CMasternodePing (random-zebra) 722af5a [Trivial] MPW: rename SignatureValid() to CheckSignature() (random-zebra) 161392c [Consensus] New signature for CMasternodePaymentWinner (random-zebra) 171c56c [Refactor] Define messageSigner and hashSigner classes (random-zebra) 8550898 [Core] Placeholder block height for activation of new signatures (random-zebra) Pull request description: Sign the following messages based on the hash of their binary content instead of their string representation: * masternode payment winner * masternode ping * budget vote * finalized budget vote * consensus vote * masternode broadcast * obfuscation relay * spork message ACKs for top commit: Fuzzbawls: ACK 7f93bd9 Tree-SHA512: 6ccd83934f9a64210bc64fb78ce349e7de5e82a66c4be5209c4a9a242d69aea1027772771dee4a9c260388131f049bfc84d37acdb7471d4d6e1520ed3ffea0b6
Sign the following messages based on the hash of their binary content instead of their string representation: