projects
/
libeap.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
d0ebf32
)
WPS: Drop subscription if it does not have any valid callback address
author
Jouni Malinen
<jouni.malinen@atheros.com>
Sun, 17 Oct 2010 17:11:03 +0000
(20:11 +0300)
committer
Jouni Malinen
<j@w1.fi>
Sun, 17 Oct 2010 17:11:03 +0000
(20:11 +0300)
src/wps/wps_upnp.c
patch
|
blob
|
history
diff --git
a/src/wps/wps_upnp.c
b/src/wps/wps_upnp.c
index
29806ec
..
9108caa
100644
(file)
--- a/
src/wps/wps_upnp.c
+++ b/
src/wps/wps_upnp.c
@@
-692,6
+692,13
@@
struct subscription * subscription_start(struct upnp_wps_device_sm *sm,
s->timeout_time = expire;
uuid_make(s->uuid);
subscr_addr_list_create(s, callback_urls);
s->timeout_time = expire;
uuid_make(s->uuid);
subscr_addr_list_create(s, callback_urls);
+ if (dl_list_empty(&s->addr_list)) {
+ wpa_printf(MSG_DEBUG, "WPS UPnP: No valid callback URLs in "
+ "'%s' - drop subscription", callback_urls);
+ subscription_destroy(s);
+ return NULL;
+ }
+
/* Add to end of list, since it has the highest expiration time */
dl_list_add_tail(&sm->subscriptions, &s->list);
/* Queue up immediate event message (our last event)
/* Add to end of list, since it has the highest expiration time */
dl_list_add_tail(&sm->subscriptions, &s->list);
/* Queue up immediate event message (our last event)