miniupnpd/upnpsoap: check Service ID in SetDefaultConnectionService method

This commit is contained in:
Thomas Bernard 2013-06-05 11:11:53 +02:00
parent 58827720da
commit 4077b0069d
2 changed files with 9 additions and 2 deletions

View File

@ -1,4 +1,7 @@
$Id: Changelog.txt,v 1.341 2013/05/29 21:27:21 nanard Exp $
$Id: Changelog.txt,v 1.342 2013/06/05 09:10:46 nanard Exp $
2013/06/05:
check Service ID in SetDefaultConnectionService method
2013/05/29:
Remove namespace from variable name elements in Events "propertyset"

View File

@ -1,4 +1,4 @@
/* $Id: upnpsoap.c,v 1.116 2013/05/16 10:41:57 nanard Exp $ */
/* $Id: upnpsoap.c,v 1.117 2013/06/05 09:10:47 nanard Exp $ */
/* MiniUPnP project
* http://miniupnp.free.fr/ or http://miniupnp.tuxfamily.org/
* (c) 2006-2013 Thomas Bernard
@ -1038,8 +1038,12 @@ SetDefaultConnectionService(struct upnphttp * h, const char * action)
* 721 InvalidServiceID
* 723 InvalidConnServiceSelection */
#ifdef UPNP_STRICT
char * service;
service = strchr(p, ',');
if(0 != memcmp(uuidvalue, p, sizeof("uuid:00000000-0000-0000-0000-000000000000") - 1)) {
SoapError(h, 720, "InvalidDeviceUUID");
} else if(service == NULL || 0 != strcmp(service+1, SERVICE_ID_WANIPC)) {
SoapError(h, 721, "InvalidServiceID");
} else
#endif
{