Age | Commit message (Collapse) | Author | Files | Lines |
|
This commit fixes a bug when using manual ipv4 addressing.
The first time it works, but once the service is reconnected it uses
an invalid netmask: 255.255.255.255.
|
|
Use value set in the kernel as the initial IPv6 privacy
setting. This also allows distros to set the privacy value
without needing to tweak connman.
|
|
Show FIXED configuration IP address info in service IPv4 and
IPv6 properties. If IP address is not available via
ipconfig->system, use the provider configured ones instead.
Fixes BMC#25084
|
|
|
|
In order to be able to request a certain ipconfig type, add the type
as a parameter to __connman_ipconfig_get_gateway_from_index().
|
|
|
|
We don't have yet an ipconfig for this interface, that means
the service.c does not yet know this interface. In order to
be able to get into sync we disable IPv6 auto connection at this point.
If the service state machine decides to connect, it will enable it
again.
|
|
|
|
When enabling IPv6 when loading the Service properties, the Service
state machine gets out of sync when AutoConnect is disabled.
At this point we should only load the properties and let the
Service state machine decide when to enable the ipconfigs.
And the good news is that the core handles this already.
|
|
|
|
According the D-Bus API, the Service interface accepts
variant types.
|
|
|
|
|
|
|
|
Because we do not check that origin pointer is not this ipconfig,
it is possible that we might try to unref the ipconfig one time
too many.
Something like this was seen in the log file:
connmand[19208]: src/ipconfig.c:enable_ipv6()
connmand[19208]: src/ipconfig.c:__connman_ipconfig_unref() ipconfig 0x47502f0 refcount 0
connmand[19208]: src/ipconfig.c:__connman_ipconfig_disable() ipconfig 0x47502f0
connmand[19208]: src/ipconfig.c:disable_ipv6()
connmand[19208]: src/ipconfig.c:__connman_ipconfig_unref() ipconfig 0x47502f0 refcount -1
|
|
Prefix them with a "__".
|
|
The DHCPv6 is used when doing autoconfiguration so we must allow
address setting/unsetting in auto mode.
|
|
|
|
Route changes should not trigger ip_bound or ip_release callbacks
in service.c as that can cause too early transition into IPv6 ready state.
The ip_bound (in __connman_ipconfig_newaddr()) and ip_release (in
__connman_ipconfig_deladdr()) are enough to trigger a transition
in IPv6 state.
This also prevents too many notifier calls in session as we only
notify session when address changes.
|
|
The ipdevice address list is only used for detecting duplicate
addresses so there is no need to copy the gateway information
into the list. The same gateway data was actually used in every
list element which is not a correct thing to do as there would
be different gateways in IPv4 and IPv6 anyway.
|
|
This is done so that if the method is not found
in settings file, then we enable IPv6 by default.
|
|
It is possible that ipdevice does not contain ipconfig for
some reason. If that happens, then ipconfig is not removed
from ipconfig_list which will then escalate into freed memory
access when interface is taken down.
The problem was seen with valgrind when tethering was enabled
and then disabled for wifi.
|
|
g_atomic_int_exchange_and_add() has been removed from glib 2.30
and g_atomic_int_add() should be used. Though there are still
quite a few distros out which do not ship a glib version with
g_atomic_int_add().
Instead of maintaing a compatiblilty glib layer we just use
the built-in functions for atomic memory access.
|
|
|
|
Show IPv4.Configuration properties also for
CONNMAN_IPCONFIG_METHOD_FIXED configuration method.
Fixes BMC#23444
|
|
|
|
|
|
|
|
The new function removes the address from interface but does not
touch internal data structures.
|
|
|
|
|
|
|
|
|
|
Switch the gateway and prefix_length order to be consistent with the ipv4
version.
|
|
|
|
|
|
|
|
|
|
This routine is unused.
|
|
This routine is unused.
|
|
For point to point interfaces, our IPv4 gateway will be NULL.
|
|
ipconfig_set_gateway() sets the gateway pointer while gateway_add() sets
the route.
|
|
|
|
|
|
|
|
|
|
|
|
this sets the IPv6 status correctly by
- enabling IPv6 when service config is loaded and method is AUTO or MANUAL
- and disabling IPv6 when service is connected and method is OFF
|
|
This is done so that if service is disconnected, the kernel
created autoconf routes need to be cleared also.
That can be done easily by disabling IPv6 for that interface.
The disabling of IPv6 is only done for autoconfigured interfaces.
When service is connected, the IPv6 is enabled for the used
interface.
|
|
|