Send connman mailing list submissions to
[email protected]
To subscribe or unsubscribe via the World Wide Web, visit
https://lists.01.org/mailman/listinfo/connman
or, via email, send a message with subject or body 'help' to
[email protected]
You can reach the person managing the list at
[email protected]
When replying, please edit your Subject line so it is more specific
than "Re: Contents of connman digest..."
Today's Topics:
1. [PATCH 1/3] docs: update manager-api.txt to include
BrowserOnly Key (Atul Anand)
2. [PATCH 2/3] src/proxy.c: modify the proxy_lookup ()
supporting non-browser schemes (Atul Anand)
3. [PATCH 3/3] unit: Add tests for BrowserOnly Key (Atul Anand)
4. Re: [PATCH 1/3] technology: Add specific D-Bus methods for
WPS connections (Patrik Flykt)
----------------------------------------------------------------------
Message: 1
Date: Mon, 29 Aug 2016 13:55:40 +0530
From: Atul Anand <[email protected]>
To: [email protected]
Subject: [PATCH 1/3] docs: update manager-api.txt to include
BrowserOnly Key
Message-ID: <[email protected]>
It has been documented that we are adding a new dict key BrowserOnly
on PACrunner DBus interface.
---
doc/manager-api.txt | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/doc/manager-api.txt b/doc/manager-api.txt
index 9e6209d..0e0b7aa 100644
--- a/doc/manager-api.txt
+++ b/doc/manager-api.txt
@@ -60,6 +60,12 @@ Methods object CreateProxyConfiguration(dict
settings)
Interface name like "wlan0" etc. to provide
consistent results for myIpAddress function.
+ boolean BrowserOnly [optional]
+
+ If this value is set, proxy configuration will
+ be used for only browser schemes. If no Key is
+ received PACrunner assumes FALSE by default.
+
array{string} Domains [optional]
Domain names and IP range for which this proxy
--
2.5.5
------------------------------
Message: 2
Date: Mon, 29 Aug 2016 13:55:41 +0530
From: Atul Anand <[email protected]>
To: [email protected]
Subject: [PATCH 2/3] src/proxy.c: modify the proxy_lookup ()
supporting non-browser schemes
Message-ID: <[email protected]>
Content-Type: text/plain; charset=UTF-8
As discussed, the proxy lookup for browser and non browser schemes should
be handled in an order as follows:
A request for a "browser" protocol would match the following configs
order of preference (if they exist):
? Matching "Domains", BrowserOnly==TRUE
? Matching "Domains", BrowserOnly==FALSE
? Domains==NULL, BrowserOnly==TRUE
? Domains==NULL, BrowserOnly==FALSE
A request for a non-browser protocol would match the following:
? Matching "Domains", BrowserOnly==FALSE
? Domains==NULL, BrowserOnly==FALSE (except if a config exists with
Matching "Domains", BrowserOnly==TRUE, in which case we need to
return NULL).
---
src/manager.c | 11 +++++-
src/pacrunner.h | 2 +-
src/proxy.c | 121 +++++++++++++++++++++++++++++++++++++++++++++-----------
3 files changed, 108 insertions(+), 26 deletions(-)
diff --git a/src/manager.c b/src/manager.c
index 5a8b4fd..fa8a7b4 100644
--- a/src/manager.c
+++ b/src/manager.c
@@ -142,6 +142,7 @@ static DBusMessage *create_proxy_config(DBusConnection
*conn,
const char *url = NULL, *script = NULL;
char **servers = NULL, **excludes = NULL;
char **domains = NULL, **nameservers = NULL;
+ gboolean browser_only = FALSE;
sender = dbus_message_get_sender(msg);
@@ -199,13 +200,18 @@ static DBusMessage *create_proxy_config(DBusConnection
*conn,
nameservers = extract_string_array(&list);
}
break;
+ case DBUS_TYPE_BOOLEAN:
+ if (g_str_equal(key, "BrowserOnly"))
+ dbus_message_iter_get_basic(&value,
+ &browser_only);
+ break;
}
dbus_message_iter_next(&array);
}
DBG("sender %s method %s interface %s", sender, method, interface);
- DBG("url %s script %p", url, script);
+ DBG("browser-only %u url %s script %p", browser_only, url, script);
if (!method) {
reply = g_dbus_create_error(msg,
@@ -226,7 +232,8 @@ static DBusMessage *create_proxy_config(DBusConnection
*conn,
nameservers = NULL;
- if (pacrunner_proxy_set_domains(config->proxy, domains) < 0)
+ if (pacrunner_proxy_set_domains(config->proxy, domains,
+ browser_only) < 0)
pacrunner_error("Failed to set proxy domains");
if (g_str_equal(method, "direct")) {
diff --git a/src/pacrunner.h b/src/pacrunner.h
index 87c51da..e31d7ef 100644
--- a/src/pacrunner.h
+++ b/src/pacrunner.h
@@ -64,7 +64,7 @@ const char *pacrunner_proxy_get_interface(struct
pacrunner_proxy *proxy);
const char *pacrunner_proxy_get_script(struct pacrunner_proxy *proxy);
int pacrunner_proxy_set_domains(struct pacrunner_proxy *proxy,
- char **domains);
+ char **domains, gboolean browser_only);
int pacrunner_proxy_set_direct(struct pacrunner_proxy *proxy);
int pacrunner_proxy_set_manual(struct pacrunner_proxy *proxy,
char **servers, char **excludes);
diff --git a/src/proxy.c b/src/proxy.c
index db49c58..7579887 100644
--- a/src/proxy.c
+++ b/src/proxy.c
@@ -40,6 +40,7 @@ struct pacrunner_proxy {
char *script;
GList **servers;
GList **excludes;
+ gboolean browser_only;
GList *domains;
void *jsctx;
};
@@ -159,13 +160,37 @@ const char *pacrunner_proxy_get_script(struct
pacrunner_proxy *proxy)
return proxy->script;
}
-int pacrunner_proxy_set_domains(struct pacrunner_proxy *proxy, char **domains)
+static gboolean check_browser_protocol(const char *url)
+{
+ static const char *browser_schemes[] = {
+ "http://",
+ "https://",
+ "ftp://",
+ "nntp://",
+ "nntps://",
+ };
+ guint i;
+
+ for (i = 0; i < G_N_ELEMENTS(browser_schemes); i++) {
+ if (strncmp(browser_schemes[i], url,
+ strlen(browser_schemes[i])) == 0)
+ return TRUE;
+ }
+
+ return FALSE;
+}
+
+int pacrunner_proxy_set_domains(struct pacrunner_proxy *proxy, char **domains,
+ gboolean browser_only)
{
int len;
char *slash, **domain;
char ip[INET6_ADDRSTRLEN + 1];
- DBG("proxy %p domains %p", proxy, domains);
+ DBG("proxy %p domains %p browser-only %u", proxy,
+ domains, browser_only);
+
+ proxy->browser_only = browser_only;
if (!proxy)
return -EINVAL;
@@ -476,13 +501,34 @@ static int compare_host_in_domain(const char *host,
struct proxy_domain *match)
return -1;
}
+/**
+ * A request for a "browser" protocol would match the following configs
+ * order of preference (if they exist):
+ * ? Matching "Domains", BrowserOnly==TRUE
+ * ? Matching "Domains", BrowserOnly==FALSE
+ * ? Domains==NULL, BrowserOnly==TRUE
+ * ? Domains==NULL, BrowserOnly==FALSE
+ *
+ * A request for a non-browser protocol would match the following :
+ * ? Matching "Domains", BrowserOnly==FALSE
+ * ? Domains==NULL, BrowserOnly==FALSE (except if a config exists with
+ * Matching "Domains", BrowserOnly==TRUE, in which case we need to
+ * return NULL).
+ **/
char *pacrunner_proxy_lookup(const char *url, const char *host)
{
GList *l, *list;
+ int protocol = 0;
struct in_addr ip4_addr;
struct in6_addr ip6_addr;
- struct pacrunner_proxy *selected_proxy = NULL, *default_proxy = NULL;
- int protocol = 0;
+ gboolean request_is_browser;
+ struct pacrunner_proxy *proxy = NULL;
+
+ /* Four classes of 'match' */
+ struct pacrunner_proxy *alldomains_browseronly = NULL;
+ struct pacrunner_proxy *alldomains_allprotos = NULL;
+ struct pacrunner_proxy *domainmatch_browseronly = NULL;
+ struct pacrunner_proxy *domainmatch_allprotos = NULL;
DBG("url %s host %s", url, host);
@@ -512,12 +558,16 @@ char *pacrunner_proxy_lookup(const char *url, const char
*host)
}
}
+ request_is_browser = check_browser_protocol(url);
+
for (list = g_list_first(proxy_list); list; list = g_list_next(list)) {
- struct pacrunner_proxy *proxy = list->data;
+ proxy = list->data;
if (!proxy->domains) {
- if (!default_proxy)
- default_proxy = proxy;
+ if (proxy->browser_only && !alldomains_browseronly)
+ alldomains_browseronly = proxy;
+ else if (!proxy->browser_only && !alldomains_allprotos)
+ alldomains_allprotos = proxy;
continue;
}
@@ -531,54 +581,79 @@ char *pacrunner_proxy_lookup(const char *url, const char
*host)
case 4:
if (compare_legacy_ip_in_net(&ip4_addr,
data) == 0) {
- selected_proxy = proxy;
DBG("match proxy %p Legacy IP range %s",
proxy, data->domain);
- goto found;
+ goto matches;
}
break;
case 6:
if (compare_ipv6_in_net(&ip6_addr,
data) == 0) {
- selected_proxy = proxy;
DBG("match proxy %p IPv6 range %s",
proxy, data->domain);
- goto found;
+ goto matches;
}
break;
default:
if (compare_host_in_domain(host, data) == 0) {
- selected_proxy = proxy;
DBG("match proxy %p DNS domain %s",
proxy, data->domain);
- goto found;
+ goto matches;
}
break;
}
}
+ /* No match */
+ continue;
+
+ matches:
+ if (proxy->browser_only == request_is_browser) {
+ goto found;
+ } else if (proxy->browser_only) {
+ /* A non-browser request will return DIRECT instead of
+ * falling back to alldomains_* if this exists.
+ */
+ if (!domainmatch_browseronly)
+ domainmatch_browseronly = proxy;
+ } else {
+ /* We might fall back to this, for a browser request */
+ if (!domainmatch_allprotos)
+ domainmatch_allprotos = proxy;
+ }
}
- if (!selected_proxy) {
- DBG("default proxy %p", default_proxy);
- selected_proxy = default_proxy;
+ if (request_is_browser) {
+ /* We'll have bailed out immediately if we found a domain match
+ * with proxy->browser_only==TRUE. Fallbacks in order of prefe-
+ * rence.
+ */
+ proxy = domainmatch_allprotos;
+ if (!proxy)
+ proxy = alldomains_browseronly;
+ if (!proxy)
+ proxy = alldomains_allprotos;
+ } else {
+ if (!domainmatch_browseronly)
+ proxy = alldomains_allprotos;
+ else
+ proxy = NULL;
}
-found:
+ found:
pthread_mutex_unlock(&proxy_mutex);
- if (!selected_proxy)
+ if (!proxy)
return NULL;
- switch (selected_proxy->method) {
+ switch (proxy->method) {
case PACRUNNER_PROXY_METHOD_UNKNOWN:
case PACRUNNER_PROXY_METHOD_DIRECT:
break;
case PACRUNNER_PROXY_METHOD_MANUAL:
- return __pacrunner_manual_execute(url, host,
- selected_proxy->servers,
- selected_proxy->excludes);
+ return __pacrunner_manual_execute(url, host, proxy->servers,
+ proxy->excludes);
case PACRUNNER_PROXY_METHOD_AUTO:
- return __pacrunner_js_execute(selected_proxy, url, host);
+ return __pacrunner_js_execute(proxy, url, host);
}
return NULL;
--
2.5.5
------------------------------
Message: 3
Date: Mon, 29 Aug 2016 13:55:42 +0530
From: Atul Anand <[email protected]>
To: [email protected]
Subject: [PATCH 3/3] unit: Add tests for BrowserOnly Key
Message-ID: <[email protected]>
Content-Type: text/plain; charset=utf-8
test-pacrunner and suites have been fixed to test BrowserOnly key
and it's function.
---
unit/suite/manual_basic.test | 13 +++++++++++
unit/suite/manual_exclude.test | 11 +++++++++
unit/suite/pac_basic.test | 5 +++++
unit/suite/pac_direct.test | 5 +++++
unit/suite/proxy_domain.test | 13 +++++++++--
unit/suite/stub.test | 3 +++
unit/test-pacrunner.c | 51 +++++++++++++++++++++++++++---------------
7 files changed, 81 insertions(+), 20 deletions(-)
diff --git a/unit/suite/manual_basic.test b/unit/suite/manual_basic.test
index 4406d9c..ed0d7f8 100644
--- a/unit/suite/manual_basic.test
+++ b/unit/suite/manual_basic.test
@@ -10,6 +10,9 @@ socks4://sockproxy.internal.com
[excludes]
+[browseronly]
+FALSE
+
[domains]
[config]
@@ -24,3 +27,13 @@ https://bar.net/?property=true bar.net
PROXY secproxy.internal.com; PROXY proxy.internal.com; SOCKS4
sockproxy.internal.com
socks4://sockaccess.external.net:8888/sock_script sockaccess.external.net
SOCKS4 sockproxy.internal.com; PROXY proxy.internal.com; PROXY
secproxy.internal.com
+smtp://mail.client.com/drafts mail.client.com
+PROXY proxy.internal.com; PROXY secproxy.internal.com; SOCKS4
sockproxy.internal.com
+http://foo.intel.com foo.intel.com
+PROXY proxy2.com; PROXY secproxy2.com
+smtp://mail.intel.com mail.intel.com
+DIRECT
+ftp://bar.redhat.com bar.redhat.com
+SOCKS4 server.one.com; SOCKS5 server.two.com
+imap://mail.redhat.com mail.redhat.com
+SOCKS4 server.one.com; SOCKS5 server.two.com
diff --git a/unit/suite/manual_exclude.test b/unit/suite/manual_exclude.test
index 211ae16..4281614 100644
--- a/unit/suite/manual_exclude.test
+++ b/unit/suite/manual_exclude.test
@@ -15,6 +15,9 @@ ftp://
*net
tri*
+[browseronly]
+TRUE
+
[domains]
[config]
@@ -33,3 +36,11 @@ trivial.co.uk:2984 trivial.co.uk
DIRECT
http://failed.com:99999/ failed.com
DIRECT
+http://foo.intel.com foo.intel.com
+PROXY proxy2.com; PROXY secproxy2.com
+smtp://foo.intel.com foo.intel.com
+DIRECT
+imap://foo.redhat.com foo.redhat.com
+SOCKS4 server.one.com; SOCKS5 server.two.com
+smtp://no.match.com no.match.com
+DIRECT
diff --git a/unit/suite/pac_basic.test b/unit/suite/pac_basic.test
index c63757e..7975371 100644
--- a/unit/suite/pac_basic.test
+++ b/unit/suite/pac_basic.test
@@ -17,6 +17,9 @@ function FindProxyForURL(url, host)
[excludes]
+[browseronly]
+TRUE
+
[domains]
[config]
@@ -25,3 +28,5 @@ VALID
[tests]
http://www.example.com/site/test.html www.example.com
PROXY proxy.example.com
+smtp://foo.com foo.com
+DIRECT
diff --git a/unit/suite/pac_direct.test b/unit/suite/pac_direct.test
index b820abc..a19519d 100644
--- a/unit/suite/pac_direct.test
+++ b/unit/suite/pac_direct.test
@@ -11,6 +11,9 @@ function FindProxyForURL(url, host)
[excludes]
+[browseronly]
+FALSE
+
[domains]
[config]
@@ -21,3 +24,5 @@ http://truc.com truc.com
DIRECT
ftp://test.boujou.org test.boujou.org
DIRECT
+smtp://foo.com foo.com
+DIRECT
diff --git a/unit/suite/proxy_domain.test b/unit/suite/proxy_domain.test
index 8c2c5e4..607f0af 100644
--- a/unit/suite/proxy_domain.test
+++ b/unit/suite/proxy_domain.test
@@ -8,6 +8,9 @@ http://proxy.suite.com
[excludes]
+[browseronly]
+TRUE
+
[domains]
suite.com
test.suite.com
@@ -32,6 +35,12 @@ PROXY secproxy2.com; PROXY proxy2.com
http://192.168.4.4/index.html 192.168.4.4
PROXY proxy2.com; PROXY secproxy2.com
socks4://baz.domain3.com/xyz baz.domain3.com
-SOCKS4 sockproxy3.com; PROXY proxy3.com
+SOCKS4 server.one.com; SOCKS5 server.two.com
http://[fe80:96db:12ce::43ef]/ip6.mp4 [fe80:96db:12ce::43ef]
-PROXY proxy3.com; SOCKS4 sockproxy3.com
+SOCKS4 server.one.com; SOCKS5 server.two.com
+imap://mail.google.com/id=inbox mail.google.com
+DIRECT
+imap://foo.redhat.com foo.redhat.com
+SOCKS4 server.one.com; SOCKS5 server.two.com
+smtp://bar.intel.com bar.intel.com
+DIRECT
diff --git a/unit/suite/stub.test b/unit/suite/stub.test
index cde0aeb..2b1238f 100644
--- a/unit/suite/stub.test
+++ b/unit/suite/stub.test
@@ -11,6 +11,9 @@ Stub suite file
[excludes]
#?If so, optional exlusion rules can be written here
+[browseronly]
+# Specifies if this configuration is for browser only schemes.
+
[domains]
# List of domains are here
diff --git a/unit/test-pacrunner.c b/unit/test-pacrunner.c
index 0c4ac69..812789c 100644
--- a/unit/test-pacrunner.c
+++ b/unit/test-pacrunner.c
@@ -38,14 +38,15 @@
#include "pacrunner.h"
enum test_suite_part {
- SUITE_TITLE = 0,
- SUITE_PAC = 1,
- SUITE_SERVERS = 2,
- SUITE_EXCLUDES = 3,
- SUITE_DOMAINS = 4,
- SUITE_CONFIG = 5,
- SUITE_TESTS = 6,
- SUITE_NOTHING = 7,
+ SUITE_TITLE = 0,
+ SUITE_PAC = 1,
+ SUITE_SERVERS = 2,
+ SUITE_EXCLUDES = 3,
+ SUITE_BROWSER_ONLY = 4,
+ SUITE_DOMAINS = 5,
+ SUITE_CONFIG = 6,
+ SUITE_TESTS = 7,
+ SUITE_NOTHING = 8,
};
enum cu_test_mode {
@@ -59,6 +60,7 @@ struct pacrunner_test_suite {
gchar *pac;
gchar **servers;
gchar **excludes;
+ gboolean browser_only;
gchar **domains;
bool config_result;
@@ -145,6 +147,9 @@ static void print_test_suite(struct pacrunner_test_suite
*suite)
} else
printf("(none)\n");
+ printf("\nBrowser Only: %s\n",
+ suite->browser_only ? "TRUE" : "FALSE");
+
printf("\nDomains:\n");
if (suite->domains) {
for (line = suite->domains; *line; line++)
@@ -250,6 +255,13 @@ static struct pacrunner_test_suite *read_test_suite(const
char *path)
suite->excludes = array;
break;
+ case SUITE_BROWSER_ONLY:
+ if (strncmp(*line, "TRUE", 4) == 0)
+ suite->browser_only = TRUE;
+ else
+ suite->browser_only = FALSE;
+
+ break;
case SUITE_DOMAINS:
array = _g_strappendv(suite->domains, *line);
if (!array)
@@ -291,6 +303,8 @@ static struct pacrunner_test_suite *read_test_suite(const
char *path)
part = SUITE_SERVERS;
else if (strncmp(*line, "[excludes]", 10) == 0)
part = SUITE_EXCLUDES;
+ else if (strncmp(*line, "[browseronly]", 13) == 0)
+ part = SUITE_BROWSER_ONLY;
else if (strncmp(*line, "[domains]", 9) == 0)
part = SUITE_DOMAINS;
else if (strncmp(*line, "[config]", 8) == 0)
@@ -363,7 +377,8 @@ static void test_proxy_domain(void)
{
int val = 0;
- if (pacrunner_proxy_set_domains(proxy, test_suite->domains) != 0)
+ if (pacrunner_proxy_set_domains(proxy, test_suite->domains,
+ test_suite->browser_only) != 0)
val = -1;
proxy2 = pacrunner_proxy_create("eth1");
@@ -381,15 +396,16 @@ static void test_proxy_domain(void)
if (pacrunner_proxy_set_manual(proxy2, servers, NULL) != 0)
val = -1;
- if (pacrunner_proxy_set_domains(proxy2, domains) != 0)
+ /* BrowserOnly = TRUE */
+ if (pacrunner_proxy_set_domains(proxy2, domains, TRUE) != 0)
val = -1;
}
proxy3 = pacrunner_proxy_create("wl0");
if (proxy3) {
char *servers[] = {
- "http://proxy3.com",
- "socks4://sockproxy3.com",
+ "socks4://server.one.com",
+ "socks5://server.two.com",
NULL};
char *domains[] = {
"redhat.com",
@@ -400,7 +416,8 @@ static void test_proxy_domain(void)
if (pacrunner_proxy_set_manual(proxy3, servers, NULL) != 0)
val = -1;
- if (pacrunner_proxy_set_domains(proxy3, domains) != 0)
+ /* BrowserOnly = FALSE */
+ if (pacrunner_proxy_set_domains(proxy3, domains, FALSE) != 0)
val = -1;
}
@@ -499,9 +516,7 @@ static void run_test_suite(const char *test_file_path, enum
cu_test_mode mode)
CU_add_test(cu_suite, "Manual config test",
test_manual_config);
- if (test_suite->domains)
- CU_add_test(cu_suite, "Proxy domain test",
- test_proxy_domain);
+ CU_add_test(cu_suite, "Proxy Domain test", test_proxy_domain);
if (test_suite->config_result && test_suite->tests)
CU_add_test(cu_suite, "Proxy requests test",
@@ -509,10 +524,10 @@ static void run_test_suite(const char *test_file_path,
enum cu_test_mode mode)
test_config = false;
- if (test_suite->domains) {
+ if (proxy2)
pacrunner_proxy_unref(proxy2);
+ if (proxy3)
pacrunner_proxy_unref(proxy3);
- }
switch (mode) {
case CU_MODE_BASIC:
--
2.5.5
------------------------------
Message: 4
Date: Mon, 29 Aug 2016 11:42:27 +0300
From: Patrik Flykt <[email protected]>
To: Jose Blanquicet <[email protected]>, [email protected]
Subject: Re: [PATCH 1/3] technology: Add specific D-Bus methods for
WPS connections
Message-ID: <[email protected]>
Content-Type: text/plain; charset="UTF-8"
Hi,
On Fri, 2016-07-22 at 15:54 +0200, Jose Blanquicet wrote:
> Two D-Bus methods were added to Technology Interface:
> - void Start_AP_WPS(string authentication)
> - void Start_STA_WPS(string authentication)
I'm trying to wrap my brains around the functionality added here. AFAIK
having these two functions in the technology API makes ConnMan able to
pass?WiFi Alliance testing, right? And you also propose this for
regular use? But then the precedence between StartSTAWPS() and already
connected services are not that clear cut.
Drop '_' from method names.
> With Start_STA_WPS method, WPS was completely detached from Service
> and now ConnMan follows WiFi Alliance specifications. This patch
> keeps current WPS implementation for compatibility support, but as
> deprecated.
As far as I understand the above correctly, the point of this is to
have ConnMan the STA to "push the WPS button" first, right? And with
connman requesting WPS, the first AP to also enable WPS will then get
selected.
And the code for (manually) selecting a service which happens to be
broadcasting/announcing WPS, will automatically of course be connected
using WPS as before.
> In case of multiple interfaces, Start_STA_WPS will prioritize the
> STA-only interfaces if they exist, otherwise it will try on STA/AP
> ones and only as last option it will use STA/AP/P2P interfaces.
If the?STA/AP/P2P capability detection works, then yes. To be sure, AP
interfaces were marked such only after successfully setting up an AP
for tethering as the capabilities haven't been that perfectly provided
by wpa_supplicant in the past.
> If the selected interface is already connected to a service or p2p
> device, it will be disconnected and then the WPS Session will start
> on it.
Hmm, disconnecting a connected interface sounds a bit unfortunate. Is
this encouraged by the WiFi Alliance specification? If yes, we might
not want not to do that, the STA or P2P connection in use can be more
important for the user than the opposite. From a ConnMan point of view
it is ok to return an -EBUSY equivalent over D-Bus if everything is
already in use. Opinions anyone?
> Interfaces in AP mode (Tethering enabled) will not be taken into
> account, they will be skipped.
Good.
> Start_STA_WPS method will finished successfully when WPS-Credentials
> are correctly received. From that point, all the notifications(error
> or success) will be sent through the service corresponding to the
> received credentials.
Shouldn't StartSTAWPS() return the service path on success or how else
is it known which service got connected via WPS? We do want to provide
the user with complete information on what the end result was.
> In addition, by using Start_AP_WPS method, ConnMan now supports WPS
> in AP mode (As registrar) which allows external devices get connect
> by using WPS. For this method, if tethering is enabled it will start
> a WPS Session on the corresponding tethering interface, otherwise it
> will reply with a "PermissionDenied" error or "NotSupported" error if
> the interface has tethering enabled but it does not support WPS.
This leaves a time window when tethering is enabled using a passphrase,
but WPS is not active, which was the intention? Else one needs to have
an attribute for WiFi that can be set before tethering is enabled.
> Technology documentation was updated.
>
>
> ---
> ?doc/agent-api.txt?????????|???6 +
> ?doc/technology-api.txt????|??35 +++++
Although small, these two should go into two different patches as they
document things.
> ?gsupplicant/gsupplicant.h |??15 +++
> ?gsupplicant/supplicant.c??| 272 +++++++++++++++++++++++++-----------
> ---
Separate patch for the basic work on the low level supplicant methods.
> ?include/technology.h??????|??10 ++
> ?plugins/wifi.c????????????| 322
> +++++++++++++++++++++++++++++++++++++++++++---
> ?src/connman.h?????????????|???1 +
> ?src/peer.c????????????????|???5 +-
> ?src/technology.c??????????| 119 +++++++++++++++++
>From here I'd single out the patches in plugins/wifi.c and src/peer.c
from the ones in technology. I hope plugins/wifi.c then handles all of
the WPS STA/peer things for the old and new cases with the same code.
Cheers,
Patrik
------------------------------
Subject: Digest Footer
_______________________________________________
connman mailing list
[email protected]
https://lists.01.org/mailman/listinfo/connman
------------------------------
End of connman Digest, Vol 10, Issue 39
***************************************