mirror of
https://github.com/zerotier/ZeroTierOne.git
synced 2025-06-05 20:13:44 +02:00
GitHub issue #990
This commit is contained in:
parent
21467596bc
commit
639fc60257
1 changed files with 10 additions and 1 deletions
|
@ -136,7 +136,7 @@ public:
|
||||||
if (_isCredentialTimestampValid(nconf,*v)&&(v->owns(r)))
|
if (_isCredentialTimestampValid(nconf,*v)&&(v->owns(r)))
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
return false;
|
return _isV6NDPEmulated(nconf,r);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -191,6 +191,15 @@ public:
|
||||||
static uint64_t credentialKey(const Credential::Type &t,const uint32_t i) { return (((uint64_t)t << 32) | (uint64_t)i); }
|
static uint64_t credentialKey(const Credential::Type &t,const uint32_t i) { return (((uint64_t)t << 32) | (uint64_t)i); }
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
inline bool _isV6NDPEmulated(const NetworkConfig &nconf,const MAC &m) const { return false; }
|
||||||
|
inline bool _isV6NDPEmulated(const NetworkConfig &nconf,const InetAddress &ip) const
|
||||||
|
{
|
||||||
|
if ((ip.isV6())&&(nconf.ndpEmulation())&&((InetAddress::makeIpv66plane(nconf.networkId,nconf.issuedTo.toInt()).ipsEqual(ip))||(InetAddress::makeIpv6rfc4193(nconf.networkId,nconf.issuedTo.toInt()).ipsEqual(ip)))) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
template<typename C>
|
template<typename C>
|
||||||
inline bool _isCredentialTimestampValid(const NetworkConfig &nconf,const C &remoteCredential) const
|
inline bool _isCredentialTimestampValid(const NetworkConfig &nconf,const C &remoteCredential) const
|
||||||
{
|
{
|
||||||
|
|
Loading…
Add table
Reference in a new issue