From 002bc0bbd5bfd721d7c80d7cdd35a47165f7c1ff Mon Sep 17 00:00:00 2001 From: Pieter Wuille Date: Fri, 9 Aug 2019 16:52:18 -0700 Subject: [PATCH] Support NODE_NETWORK_LIMITED by default --- main.cpp | 12 ++++++++---- protocol.h | 3 +++ 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/main.cpp b/main.cpp index 60cc864..6f08112 100644 --- a/main.cpp +++ b/main.cpp @@ -147,10 +147,14 @@ public: } } if (filter_whitelist.empty()) { - filter_whitelist.insert(1); - filter_whitelist.insert(5); - filter_whitelist.insert(9); - filter_whitelist.insert(13); + filter_whitelist.insert(NODE_NETWORK); + filter_whitelist.insert(NODE_NETWORK | NODE_BLOOM); + filter_whitelist.insert(NODE_NETWORK | NODE_WITNESS); + filter_whitelist.insert(NODE_NETWORK | NODE_WITNESS | NODE_BLOOM); + filter_whitelist.insert(NODE_NETWORK_LIMITED); + filter_whitelist.insert(NODE_NETWORK_LIMITED | NODE_BLOOM); + filter_whitelist.insert(NODE_NETWORK_LIMITED | NODE_WITNESS); + filter_whitelist.insert(NODE_NETWORK_LIMITED | NODE_WITNESS | NODE_BLOOM); } if (host != NULL && ns == NULL) showHelp = true; if (showHelp) fprintf(stderr, help, argv[0]); diff --git a/protocol.h b/protocol.h index e9be1c2..876cc5a 100644 --- a/protocol.h +++ b/protocol.h @@ -60,6 +60,9 @@ class CMessageHeader enum { NODE_NETWORK = (1 << 0), + NODE_BLOOM = (1 << 2), + NODE_WITNESS = (1 << 3), + NODE_NETWORK_LIMITED = (1 << 10), }; class CAddress : public CService