summaryrefslogtreecommitdiff
path: root/plugins/wifi.c
diff options
context:
space:
mode:
authorChengyi Zhao <chengyi1.zhao@archermind.com>2013-07-11 10:00:31 +0800
committerZhang zhengguang <zhengguang.zhang@intel.com>2014-10-31 16:06:21 +0800
commitcdc3af7c29f82b71c2ce76fb6aa28dd6b3d9e5cd (patch)
tree990642f8d185bc542b34c4aef56cb3d8efeb79e1 /plugins/wifi.c
parentd0fcec2219e62723f4ed4e67e1724b8dc2c1cd96 (diff)
downloadconnman-cdc3af7c29f82b71c2ce76fb6aa28dd6b3d9e5cd.tar.gz
connman-cdc3af7c29f82b71c2ce76fb6aa28dd6b3d9e5cd.tar.bz2
connman-cdc3af7c29f82b71c2ce76fb6aa28dd6b3d9e5cd.zip
Tethering: Add hidden access point support in technology
Change-Id: I73fccf5f322ee2597f8f58d5e3d7f60ddeb0a641
Diffstat (limited to 'plugins/wifi.c')
-rw-r--r--plugins/wifi.c13
1 files changed, 10 insertions, 3 deletions
diff --git a/plugins/wifi.c b/plugins/wifi.c
index b5bc3bae..21f9912d 100644
--- a/plugins/wifi.c
+++ b/plugins/wifi.c
@@ -2927,7 +2927,8 @@ struct wifi_tethering_info {
GSupplicantSSID *ssid;
};
-static GSupplicantSSID *ssid_ap_init(const char *ssid, const char *passphrase)
+static GSupplicantSSID *ssid_ap_init(const char *ssid,
+ const char *passphrase, bool hidden)
{
GSupplicantSSID *ap;
@@ -2952,6 +2953,12 @@ static GSupplicantSSID *ssid_ap_init(const char *ssid, const char *passphrase)
ap->passphrase = passphrase;
}
+ if (hidden)
+ ap->ignore_broadcast_ssid =
+ G_SUPPLICANT_AP_HIDDEN_SSID_ZERO_CONTENTS;
+ else
+ ap->ignore_broadcast_ssid = G_SUPPLICANT_AP_NO_SSID_HIDING;
+
return ap;
}
@@ -3032,7 +3039,7 @@ static void sta_remove_callback(int result,
static int tech_set_tethering(struct connman_technology *technology,
const char *identifier, const char *passphrase,
- const char *bridge, bool enabled)
+ const char *bridge, bool enabled, bool hidden)
{
GList *list;
GSupplicantInterface *interface;
@@ -3085,7 +3092,7 @@ static int tech_set_tethering(struct connman_technology *technology,
info->wifi = wifi;
info->technology = technology;
info->wifi->bridge = bridge;
- info->ssid = ssid_ap_init(identifier, passphrase);
+ info->ssid = ssid_ap_init(identifier, passphrase, hidden);
if (!info->ssid) {
g_free(info);
continue;