Prevent recursive transit of ZeroTier packets, toward GitHub issue #56
This commit is contained in:
parent
b117ff5435
commit
c9294c1a78
6 changed files with 141 additions and 13 deletions
|
@ -27,6 +27,7 @@
|
|||
|
||||
#include "Peer.hpp"
|
||||
#include "Switch.hpp"
|
||||
#include "AntiRecursion.hpp"
|
||||
|
||||
#include <algorithm>
|
||||
|
||||
|
@ -164,6 +165,7 @@ Path::Type Peer::send(const RuntimeEnvironment *_r,const void *data,unsigned int
|
|||
|
||||
if ((bestPath)&&(_r->sm->send(bestPath->address(),bestPath->tcp(),bestPath->type() == Path::PATH_TYPE_TCP_OUT,data,len))) {
|
||||
bestPath->sent(now);
|
||||
_r->antiRec->logOutgoingZT(data,len);
|
||||
return bestPath->type();
|
||||
}
|
||||
return Path::PATH_TYPE_NULL;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue