reject mappings with wildcard ExternalPort

This commit is contained in:
Thomas Bernard 2016-02-12 15:58:19 +01:00
parent 9c28a0745f
commit 4eda8234c2
1 changed files with 0 additions and 2 deletions

View File

@ -427,14 +427,12 @@ AddPortMapping(struct upnphttp * h, const char * action, const char * ns)
eport = (unsigned short)atoi(ext_port); eport = (unsigned short)atoi(ext_port);
iport = (unsigned short)atoi(int_port); iport = (unsigned short)atoi(int_port);
/* TODO : check if we are supporting wildcard ExternalPort
if (strcmp(ext_port, "*") == 0 || eport == 0) if (strcmp(ext_port, "*") == 0 || eport == 0)
{ {
ClearNameValueList(&data); ClearNameValueList(&data);
SoapError(h, 716, "Wildcard not permited in ExtPort"); SoapError(h, 716, "Wildcard not permited in ExtPort");
return; return;
} }
*/
leaseduration = leaseduration_str ? atoi(leaseduration_str) : 0; leaseduration = leaseduration_str ? atoi(leaseduration_str) : 0;
#ifdef IGD_V2 #ifdef IGD_V2