summaryrefslogtreecommitdiff
path: root/node/Peer.cpp
diff options
context:
space:
mode:
authorAdam Ierymenko <adam.ierymenko@gmail.com>2015-06-19 10:23:25 -0700
committerAdam Ierymenko <adam.ierymenko@gmail.com>2015-06-19 10:23:25 -0700
commit7bae95836c8824a76e0299df776a708eb3e58576 (patch)
tree67fd37bb38b209fffcc7e480004dbd298a507d10 /node/Peer.cpp
parent07f84a99b4458b3ddf5c14b9ce9b7c1dc5e2763e (diff)
downloadinfinitytier-7bae95836c8824a76e0299df776a708eb3e58576.tar.gz
infinitytier-7bae95836c8824a76e0299df776a708eb3e58576.zip
Root server terminology cleanup, and tighten up a security check by checking full identity of peers instead of just address.
Diffstat (limited to 'node/Peer.cpp')
-rw-r--r--node/Peer.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/node/Peer.cpp b/node/Peer.cpp
index 3093ef41..96caa72c 100644
--- a/node/Peer.cpp
+++ b/node/Peer.cpp
@@ -122,16 +122,16 @@ void Peer::received(
/* Announce multicast groups of interest to direct peers if they are
* considered authorized members of a given network. Also announce to
- * rootservers and network controllers. */
+ * root servers and network controllers. */
if ((pathIsConfirmed)&&((now - _lastAnnouncedTo) >= ((ZT_MULTICAST_LIKE_EXPIRE / 2) - 1000))) {
_lastAnnouncedTo = now;
- const bool isRootserver = RR->topology->isRootserver(_id.address());
+ const bool isRoot = RR->topology->isRoot(_id);
Packet outp(_id.address(),RR->identity.address(),Packet::VERB_MULTICAST_LIKE);
const std::vector< SharedPtr<Network> > networks(RR->node->allNetworks());
for(std::vector< SharedPtr<Network> >::const_iterator n(networks.begin());n!=networks.end();++n) {
- if ( (isRootserver) || ((*n)->isAllowed(_id.address())) ) {
+ if ( (isRoot) || ((*n)->isAllowed(_id.address())) ) {
const std::vector<MulticastGroup> mgs((*n)->allMulticastGroups());
for(std::vector<MulticastGroup>::const_iterator mg(mgs.begin());mg!=mgs.end();++mg) {
if ((outp.size() + 18) > ZT_UDP_DEFAULT_PAYLOAD_MTU) {