Add NODE_BLOOM service bit and bump protocol version
Lets nodes advertise that they offer bloom filter support explicitly. The protocol version bump allows SPV nodes to assume that NODE_BLOOM is set if NODE_NETWORK is set for pre-170004 nodes. Also adds an option to turn bloom filter support off for nodes which advertise a version number >= 170004. Nodes attempting to use bloom filters on such protocol versions are banned, and a later upgade should drop nodes of an older version which attempt to use bloom filters. Much code stolen from Peter Todd. Zcash: Implements Zcash equivalent of BIP 111; deploys with Overwinter
This commit is contained in:
@@ -9,7 +9,7 @@
|
||||
* network protocol versioning
|
||||
*/
|
||||
|
||||
static const int PROTOCOL_VERSION = 170003;
|
||||
static const int PROTOCOL_VERSION = 170004;
|
||||
|
||||
//! initial proto version, to be increased after version/verack negotiation
|
||||
static const int INIT_PROTO_VERSION = 209;
|
||||
@@ -30,4 +30,7 @@ static const int BIP0031_VERSION = 60000;
|
||||
//! "mempool" command, enhanced "getdata" behavior starts with this version
|
||||
static const int MEMPOOL_GD_VERSION = 60002;
|
||||
|
||||
//! "filter*" commands are disabled without NODE_BLOOM after and including this version
|
||||
static const int NO_BLOOM_VERSION = 170004;
|
||||
|
||||
#endif // BITCOIN_VERSION_H
|
||||
|
||||
Reference in New Issue
Block a user