This commit is contained in:
Adam Ierymenko 2016-08-05 15:55:38 -07:00
parent e2f783ebbd
commit 4d7f625aa1
5 changed files with 39 additions and 360 deletions

View file

@ -482,6 +482,44 @@ bool Network::filterIncomingPacket(
const unsigned int etherType,
const unsigned int vlanId)
{
uint32_t remoteTagIds[ZT_MAX_NETWORK_TAGS];
uint32_t remoteTagValues[ZT_MAX_NETWORK_TAGS];
const Tag *relevantLocalTags[ZT_MAX_NETWORK_TAGS];
unsigned int relevantLocalTagCount = 0;
Mutex::Lock _l(_lock);
Membership &m = _memberships[ztDest];
const unsigned int remoteTagCount = m.getAllTags(_config,remoteTagIds,remoteTagValues,ZT_MAX_NETWORK_TAGS);
if (_doZtFilter(
RR,
_id,
true,
sourcePeer->address(),
ztDest,
macSource,
macDest,
frameData,
frameLen,
etherType,
vlanId,
_config.rules,
_config.ruleCount,
_config.tags,
_config.tagCount,
remoteTagIds,
remoteTagValues,
remoteTagCount,
relevantLocalTags,
relevantLocalTagCount
)) {
return true;
}
return false;
}
bool Network::subscribedToMulticastGroup(const MulticastGroup &mg,bool includeBridgedGroups) const