Checking lan only in non-thirdparty mode.
This commit is contained in:
parent
28b3afbb8f
commit
924b6d1613
|
@ -1568,11 +1568,15 @@ int ProcessIncomingPCPPacket(int s, unsigned char *buff, int len,
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
lan_addr = get_lan_for_peer(senderaddr);
|
/* If we're in allow third party-mode, we probably don't care
|
||||||
if(lan_addr == NULL) {
|
* about locality either. Let's hope firewall is ok. */
|
||||||
syslog(LOG_WARNING, "PCP packet sender %s not from a LAN, ignoring",
|
if (!GETFLAG(PCP_ALLOWTHIRDPARTYMASK)) {
|
||||||
addr_str);
|
lan_addr = get_lan_for_peer(senderaddr);
|
||||||
return 0;
|
if(lan_addr == NULL) {
|
||||||
|
syslog(LOG_WARNING, "PCP packet sender %s not from a LAN, ignoring",
|
||||||
|
addr_str);
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (processPCPRequest(buff, len, &pcp_msg_info) ) {
|
if (processPCPRequest(buff, len, &pcp_msg_info) ) {
|
||||||
|
|
Loading…
Reference in New Issue