Ori Newman
9939671ccc
[NOD-1147] Implement address exchange ( #795 )
...
* [NOD-1147] Implement address exchange
* [NOD-1147] Put placeholder for source address
* [NOD-1147] Fix tests
* [NOD-1147] Add comment
* [NOD-1147] Remove needAddresses from MsgGetAddr
* [NOD-1147] Use rand.Shuffle
* [NOD-1147] Remove redundant const
* [NOD-1147] Move defer to its correct place
* [NOD-1147] Fix typo
* [NOD-1147] Use EnqueueWithTimeout for outgoingRoute
* [NOD-1147] Rename MsgGetAddr->MsgGetAddresses
* [NOD-1147] Rename MsgGetAddr->MsgGetAddresses
* [NOD-1147] Rename MsgAddr->MsgAddresses
* [NOD-1147] Rename fakeSrcAddr->fakeSourceAddress
* [NOD-1147] Remove redundant files
* [NOD-1147] CmdAddr -> CmdAddress
* [NOD-1147] Rename addr to address in protocol package
2020-07-15 17:19:46 +03:00
Ori Newman
433cdb6006
[NOD-1126] implement block relay flow ( #786 )
...
* [NOD-1126] Implement block relay flow
* [NOD-1126] Add StartGetRelayBlocksListener
* [NOD-1126] Implement block relay flow
* [NOD-1126] Integrate with new interface
* [NOD-1126] Fix comments
* [NOD-1126] Refactor protocol.go
* [NOD-1126] Split long lines
* [NOD-1126] Fix comment
* [NOD-1126] move sharedRequestedBlocks to a separate file
* [NOD-1126] Fix error message
* [NOD-1126] Move handleInv to StartBlockRelay
* [NOD-1126] Create hashesQueueSet type
* [NOD-1126] Make deleteFromRequestedBlocks a method
* [NOD-1126] Fix comment
* [NOD-1126] Add block logger
* [NOD-1126] Rename advertisedProtoVer->advertisedProtocolVer
* [NOD-1126] Fix comment and an error message
* [NOD-1126] Remove redundant loop
* [NOD-1126] Move requestBlocks upper
* [NOD-1126] Remove exiting blocks in requestedBlocks from hashesToRequest
* [NOD-1126] Change comment
* [NOD-1126] Rename stallResponseTimeout->timeout
* [NOD-1126] Use switch inside readMsgBlock
* [NOD-1126] Fix error message and remove redundant log
* [NOD-1126] Rename pacakge names
* [NOD-1126] Fix comment
* [NOD-1126] Change file names
* [NOD-1126] Convert block to partial if needed
* [NOD-1126] Remove function redeclaration
* [NOD-1126] continue instead of return
* [NOD-1126] Rename LogBlockBlueScore->LogBlock
* [NOD-1126] Add minimum functions to utils
* [NOD-1126] Flip condition on readInv
* [NOD-1126] Rename utilMath->mathUtil
* [NOD-1126] Fix comment
2020-07-12 16:11:42 +03:00
Ori Newman
22fd38c053
[NOD-1060] Don't sync from misbehaving peer ( #768 )
...
* [NOD-1038] Give higher priority for requesting missing ancestors when sending a getdata message (#767 )
* [NOD-1060] Don't sync from peers that break the netsync protocol
2020-06-22 17:15:03 +03:00
Ori Newman
1271d2f113
[NOD-1038] Give higher priority for requesting missing ancestors when sending a getdata message ( #767 )
2020-06-17 11:52:10 +03:00
Ori Newman
0744e8ebc0
[NOD-1042] Ignore very high orphans ( #761 )
...
* [NOD-530] Remove coinbase inputs and add blue score to payload
* [NOD-1042] Ignore very high orphans
* [NOD-1042] Add ban score to an orphan with malformed blue score
* [NOD-1042] Fix log
2020-06-15 16:08:25 +03:00
Ori Newman
d4c9fdf6ac
[NOD-614] Add ban score ( #760 )
...
* [NOD-614] Copy bitcoin-core ban score policy
* [NOD-614] Add ban score to disconnects
* [NOD-614] Fix wrong branch of AddBanScore
* [NOD-614] Add ban score on sending too many addresses
* [NOD-614] Add comments
* [NOD-614] Remove redundant reject messages
* [NOD-614] Fix log message
* [NOD-614] Ban every node that sends invalid invs
* [NOD-614] Make constants for ban scores
2020-06-15 12:12:38 +03:00