aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2013-10-08 11:09:48 +0000
committerFelix Fietkau <nbd@openwrt.org>2013-10-08 11:09:48 +0000
commit7dbd213406e6c48b6e0c6e69e52692313a499b80 (patch)
treedf650084b161e55e8946dc3943236f093eba54a8
parenta8cf4fe00a8dd7f0df7a5fe00afc403f2e3f6d74 (diff)
downloadupstream-7dbd213406e6c48b6e0c6e69e52692313a499b80.tar.gz
upstream-7dbd213406e6c48b6e0c6e69e52692313a499b80.tar.bz2
upstream-7dbd213406e6c48b6e0c6e69e52692313a499b80.zip
hostapd: add external registrar support
Setting wireless.@wifi-iface[N].ext_registrar=1 will enable UPNP advertising and add an external registrar to the interface this vif belongs to (br-lan if the vif is included in the LAN bridge). By enabling this we append upnp_iface=xxx to the hostapd config file. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Mathieu Olivari <mathieu@qca.qualcomm.com> Signed-off-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@38338 3c298f89-4303-0410-b956-a3cf2f4a3e73
-rw-r--r--package/network/services/hostapd/files/hostapd.sh3
1 files changed, 3 insertions, 0 deletions
diff --git a/package/network/services/hostapd/files/hostapd.sh b/package/network/services/hostapd/files/hostapd.sh
index ce0f2271de..f856a0b739 100644
--- a/package/network/services/hostapd/files/hostapd.sh
+++ b/package/network/services/hostapd/files/hostapd.sh
@@ -196,6 +196,9 @@ hostapd_set_bss_options() {
config_get manufacturer "$vif" wps_manufacturer "openwrt.org"
config_get wps_pin "$vif" wps_pin "12345670"
+ config_get_bool ext_registrar "$vif" ext_registrar 0
+ [ "$ext_registrar" -gt 0 -a -n "$bridge" ] && append "$var" "upnp_iface=$bridge" "$N"
+
append "$var" "eap_server=1" "$N"
append "$var" "ap_pin=$wps_pin" "$N"
append "$var" "wps_state=${wps_not_configured:-2}" "$N"