[PATCH v1 1/1] doc: update online check information
by Ingo Albrecht
Update doc to reflect the new EnableOnlineCheck configuration option
introduced with 4de35cde5a93271e785a3bb5a0f3d39aea34d77b
Correct typo.
---
diff --git a/README b/README
index 700426a7..cff3131e 100644
--- a/README
+++ b/README
@@ -385,15 +385,17 @@ from ipv4.connman.net (for IPv4 connectivity) and ipv6.connman.net
(for IPv6 connectivity). The used URL looks like this
http://ipv{4|6}.connman.net/online/status.html
+See connman.conf(5) for the EnableOnlineCheck option, if you need to
+disable the feature.
+
During the online check procedure, ConnMan will temporarily install
a host route to both the ipv4.connman.net and ipv6.connman.net so that
the online check query can be directed via the correct network
interface which the connected service is using. This host route is
-automatically removed when the online check is done. While ConnMan has no
-option to skip or diaable the online check, note that the server expressly
-does not log any connection information, including IPv4/6 addresses of
-connecting clients. The server runtime logs cycle in RAM memory depending
-on amount of connections processed.
+automatically removed when the online check is done. Note that the server
+expressly does not log any connection information, including IPv4/6
+addresses of connecting clients. The server runtime logs cycle in RAM
+memory depending on amount of connections processed.
ConnMan sends this very minimal information in http header when doing
the online check request (example):
diff --git a/doc/connman.conf.5.in b/doc/connman.conf.5.in
index 9c999107..95b177f5 100644
--- a/doc/connman.conf.5.in
+++ b/doc/connman.conf.5.in
@@ -138,7 +138,7 @@ be used by DHCP servers to identify specific clients without having to
rely on MAC address ranges, etc
.TP
.BI EnableOnlineCheck=true\ \fR|\fB\ false
-Enable or disable use of http get as on online status check.
+Enable or disable use of HTTP GET as an online status check.
When a service is in a READY state, and is selected as default,
ConnMan will issue an HTTP GET request to verify that end-to-end
connectivity is successful. Only then the service will be
@@ -154,15 +154,5 @@ ethernet tethering.
AllowHostnameUpdates = false
TetheringTechnologies = ethernet,wifi,bluetooth,gadget
.fi
-.SH "NOTES"
-When a service is connected, ConnMan tries to detect if it has internet
-connectivity or not. During this online check procedure, ConnMan will
-temporarily install a host route to both the ipv4.connman.net and
-ipv6.connman.net so that the online check query can be directed via the
-correct network interface which the connected service is using.
-
-Currently there is no option to skip or disable this online check. ConnMan,
-however, limits transmitted data to a minimum. See the ConnMan README for
-more information.
.SH "SEE ALSO"
.BR connman (8)
5 years, 1 month
[PATCH] ofono: Fix shared usage of interface index
by Lukasz Nowak
From: Lukasz Nowak <lnowak(a)tycoint.com>
IPv4 and IPv6 share the interface index value in the network_context structure.
Because of that, they should not overwrite it with -1 every time a Settings
or IPv6.Setting modem property is received.
Problem observed when a modem was first reporting IPv4 Settings, with a valid
interface name and method dhcp. And then IPv6.Settings with method=OFF and
no interface name.
In that case, extract_ipv6_settings would wrongly set context->index = -1
causing the set_connected() fail and modem being incorrectly kept disconnected.
---
plugins/ofono.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/plugins/ofono.c b/plugins/ofono.c
index f6b2b52..78f8f19 100644
--- a/plugins/ofono.c
+++ b/plugins/ofono.c
@@ -841,7 +841,6 @@ static void extract_ipv4_settings(DBusMessageIter *array,
connman_ipaddress_free(context->ipv4_address);
context->ipv4_address = NULL;
- context->index = -1;
if (dbus_message_iter_get_arg_type(array) != DBUS_TYPE_ARRAY)
return;
@@ -944,7 +943,6 @@ static void extract_ipv6_settings(DBusMessageIter *array,
connman_ipaddress_free(context->ipv6_address);
context->ipv6_address = NULL;
- context->index = -1;
if (dbus_message_iter_get_arg_type(array) != DBUS_TYPE_ARRAY)
return;
--
2.7.4
5 years, 1 month
[PATCH] ofono: Fix segfault during modem_removed
by Lukasz Nowak
From: Lukasz Nowak <lnowak(a)tycoint.com>
Prevent sending any further dbus messages after modem_removed signal.
Sequence causing a segfault is:
- modem_removed
- remove_modem
- remove_all_contexts
- remove_cm_context
- remove_network
- connman_device_remove_network
- network_disconnect
- context_set_active
- set_property
---
plugins/ofono.c | 9 +++++++++
1 file changed, 9 insertions(+)
diff --git a/plugins/ofono.c b/plugins/ofono.c
index 70b085a..f6b2b52 100644
--- a/plugins/ofono.c
+++ b/plugins/ofono.c
@@ -2500,16 +2500,19 @@ static void remove_modem(gpointer data)
if (modem->call_set_property) {
dbus_pending_call_cancel(modem->call_set_property);
dbus_pending_call_unref(modem->call_set_property);
+ modem->call_set_property = NULL;
}
if (modem->call_get_properties) {
dbus_pending_call_cancel(modem->call_get_properties);
dbus_pending_call_unref(modem->call_get_properties);
+ modem->call_get_properties = NULL;
}
if (modem->call_get_contexts) {
dbus_pending_call_cancel(modem->call_get_contexts);
dbus_pending_call_unref(modem->call_get_contexts);
+ modem->call_get_contexts = NULL;
}
/* Must remove the contexts before the device */
@@ -2699,6 +2702,9 @@ static int network_connect(struct connman_network *network)
DBG("%s network %p", modem->path, network);
+ if (!g_hash_table_lookup(modem_hash, modem->path))
+ return -ENODEV;
+
context = get_context_with_network(modem->context_list, network);
if (!context)
return -ENODEV;
@@ -2720,6 +2726,9 @@ static int network_disconnect(struct connman_network *network)
DBG("%s network %p", modem->path, network);
+ if (!g_hash_table_lookup(modem_hash, modem->path))
+ return -ENODEV;
+
context = get_context_with_network(modem->context_list, network);
if (!context)
return -ENODEV;
--
2.7.4
5 years, 1 month