|
|
|
|
@ -41,6 +41,7 @@
|
|
|
|
|
#include "NodeConfig.hpp" |
|
|
|
|
#include "Service.hpp" |
|
|
|
|
#include "Demarc.hpp" |
|
|
|
|
#include "SoftwareUpdater.hpp" |
|
|
|
|
|
|
|
|
|
namespace ZeroTier { |
|
|
|
|
|
|
|
|
|
@ -265,6 +266,11 @@ bool PacketDecoder::_doOK(const RuntimeEnvironment *_r,const SharedPtr<Peer> &pe
|
|
|
|
|
unsigned int vRevision = at<uint16_t>(ZT_PROTO_VERB_HELLO__OK__IDX_REVISION); |
|
|
|
|
TRACE("%s(%s): OK(HELLO), version %u.%u.%u",source().toString().c_str(),_remoteAddress.toString().c_str(),vMajor,vMinor,vRevision); |
|
|
|
|
peer->setRemoteVersion(vMajor,vMinor,vRevision); |
|
|
|
|
|
|
|
|
|
// If a supernode has a version higher than ours, this causes a software
|
|
|
|
|
// update check to run now.
|
|
|
|
|
if ((_r->updater)&&(_r->topology->isSupernode(peer->address()))) |
|
|
|
|
_r->updater->sawRemoteVersion(vMajor,vMinor,vRevision); |
|
|
|
|
} break; |
|
|
|
|
case Packet::VERB_WHOIS: { |
|
|
|
|
// Right now only supernodes are allowed to send OK(WHOIS) to prevent
|
|
|
|
|
|