Tomasz Bursztyka [Wed, 26 Oct 2011 10:43:27 +0000 (13:43 +0300)]
test: Tiny typo fix in test-session python script
Daniel Wagner [Fri, 28 Oct 2011 15:12:06 +0000 (17:12 +0200)]
session doc: Document PeriodicConnect and IdleTimeout
Daniel Wagner [Fri, 28 Oct 2011 15:12:05 +0000 (17:12 +0200)]
session doc: Document state transitions
Daniel Wagner [Fri, 28 Oct 2011 15:12:04 +0000 (17:12 +0200)]
session doc: Fix typo
Tomasz Bursztyka [Thu, 3 Nov 2011 08:46:30 +0000 (10:46 +0200)]
wifi: Handle erroneous disconnection after 4way-handshake
And interpret it as a wrong psk after 4 consecutive failures.
Tomasz Bursztyka [Thu, 3 Nov 2011 08:46:29 +0000 (10:46 +0200)]
gsupplicant: Add a function to enable or disable the selected network
Jukka Rissanen [Tue, 1 Nov 2011 09:24:48 +0000 (11:24 +0200)]
network: Check device pointer when doing IPv6 autoconf
The device can disappear if network is disconnected while setting
autoconf parameters.
Jukka Rissanen [Tue, 1 Nov 2011 09:09:55 +0000 (11:09 +0200)]
network: Disconnect network properly
When network is removed (for example when ethernet cable
is disconnected), then it needs to be disconnected also.
The disconnect was not done at all because of the reference
counting fixes in dhcp code.
Jukka Rissanen [Mon, 31 Oct 2011 15:38:15 +0000 (17:38 +0200)]
inet: Cleanup the router solicitations handler properly
Jukka Rissanen [Mon, 31 Oct 2011 10:53:11 +0000 (12:53 +0200)]
inet: Fix file descriptor leak when comparing subnets
Daniel Wagner [Mon, 31 Oct 2011 19:30:16 +0000 (20:30 +0100)]
device: Cancel pending trigger when device is removed
connmand[28326]: src/device.c:device_destruct() device 0x6b97c0 name candlejack.bmw-carit.intra-1
connmand[28326]: plugins/bluetooth.c:powered_reply()
connmand[28326]: Name "org.bluez" does not exist
connmand[28326]: src/device.c:device_pending_reset() device 0x6b97c0
Patrik Flykt [Tue, 25 Oct 2011 07:51:38 +0000 (10:51 +0300)]
test: Use session.Destroy()
Use session.Destroy() instead of the Manager API DestroySession()
method call.
Patrik Flykt [Tue, 25 Oct 2011 07:51:37 +0000 (10:51 +0300)]
doc: Document that DestroySession will not send Release to sessions
Patrik Flykt [Tue, 25 Oct 2011 07:51:36 +0000 (10:51 +0300)]
session: Implement Session API Destroy method call
Call session_disconnect() from destroy_session() thus adding
functionality to Session API Destroy method call.
Tomasz Bursztyka [Mon, 31 Oct 2011 09:33:48 +0000 (11:33 +0200)]
iptables: Fix xtables API version issues
Tomasz Bursztyka [Mon, 31 Oct 2011 09:33:47 +0000 (11:33 +0200)]
tools: Fix xtables API version issues with iptables-test
Jukka Rissanen [Fri, 28 Oct 2011 09:28:59 +0000 (12:28 +0300)]
gdhcp: Possible file descriptor leak
Patrik Flykt [Fri, 28 Oct 2011 08:04:48 +0000 (11:04 +0300)]
session: Add a list of pending connect/disconnect actions
deselect_service() and select_offline_service() want to clear
up the session state machinery by setting up a zero second
timeout function thereby letting the main loop run once through
all waiting actions. Unfortunately, if a service is being
removed meantime, the service structure stored in the timeout
functions will become invalid.
This is fixed by adding a list of pending connect/disconnect
actions per struct service_entry and cancelling all of them
if the service is removed.
Fixes BMC#22879
Tomasz Bursztyka [Thu, 27 Oct 2011 07:26:43 +0000 (10:26 +0300)]
iptables: Support builtin chain policies changes
Tomasz Bursztyka [Thu, 27 Oct 2011 07:26:42 +0000 (10:26 +0300)]
iptables: Disable getopt unknown option display
Tomasz Bursztyka [Thu, 27 Oct 2011 07:26:41 +0000 (10:26 +0300)]
iptables: Support for rule matches list
Tomasz Bursztyka [Thu, 27 Oct 2011 07:26:40 +0000 (10:26 +0300)]
iptables: Finalize matches extensions setup
Tomasz Bursztyka [Thu, 27 Oct 2011 07:26:39 +0000 (10:26 +0300)]
iptables: Add extensions options parsing for matches
Tomasz Bursztyka [Thu, 27 Oct 2011 07:26:38 +0000 (10:26 +0300)]
iptables: Finalize target extensions setup
Tomasz Bursztyka [Thu, 27 Oct 2011 07:26:37 +0000 (10:26 +0300)]
iptables: Add extensions options parsing for target
Tomasz Bursztyka [Thu, 27 Oct 2011 07:26:36 +0000 (10:26 +0300)]
iptables: Add x6_options matches handling
Tomasz Bursztyka [Thu, 27 Oct 2011 07:26:35 +0000 (10:26 +0300)]
iptables: Add x6_options target handling
Tomasz Bursztyka [Thu, 27 Oct 2011 07:26:34 +0000 (10:26 +0300)]
iptables: Move target and matches preparation routines
Tomasz Bursztyka [Thu, 27 Oct 2011 07:26:33 +0000 (10:26 +0300)]
iptables: Support matches rule list loading
Tomasz Bursztyka [Thu, 27 Oct 2011 07:26:32 +0000 (10:26 +0300)]
iptables: Refactor matches preparation
Tomasz Bursztyka [Thu, 27 Oct 2011 07:26:31 +0000 (10:26 +0300)]
iptables: Move target options merge to prepare_target
Tomasz Bursztyka [Thu, 27 Oct 2011 07:26:30 +0000 (10:26 +0300)]
iptables: Code preparation for option handling
Tomasz Bursztyka [Thu, 27 Oct 2011 07:24:59 +0000 (10:24 +0300)]
tools: Add iptables_test builtin chain policy changes
Tomasz Bursztyka [Thu, 27 Oct 2011 07:24:58 +0000 (10:24 +0300)]
tools: Initialize the iptables_test invert flag properly
The invert flag is specific to each option so it needs to be initialized
after each succesfully handled option.
Tomasz Bursztyka [Thu, 27 Oct 2011 07:24:57 +0000 (10:24 +0300)]
tools: Disable getopt unknown option display in iptables_test
Tomasz Bursztyka [Thu, 27 Oct 2011 07:24:56 +0000 (10:24 +0300)]
tools: Add support for rule matches list to iptables_test
Tomasz Bursztyka [Thu, 27 Oct 2011 07:24:55 +0000 (10:24 +0300)]
tools: Finalize matches extensions setup in iptables_test
Tomasz Bursztyka [Thu, 27 Oct 2011 07:24:54 +0000 (10:24 +0300)]
tools: Add extensions options parsing for matches to iptables-test
Tomasz Bursztyka [Thu, 27 Oct 2011 07:24:53 +0000 (10:24 +0300)]
tools: Finalize target extensions setup in iptables_test
Tomasz Bursztyka [Thu, 27 Oct 2011 07:24:52 +0000 (10:24 +0300)]
tools: Add extensions options parsing for target to iptables_test
Tomasz Bursztyka [Thu, 27 Oct 2011 07:24:51 +0000 (10:24 +0300)]
tools: Add x6_options matches handling to iptables-test
Tomasz Bursztyka [Thu, 27 Oct 2011 07:24:50 +0000 (10:24 +0300)]
tools: Add x6_options target handling to iptables_test
Tomasz Bursztyka [Thu, 27 Oct 2011 07:24:49 +0000 (10:24 +0300)]
tools: Target and matches preparation function moves in iptables_test
Tomasz Bursztyka [Thu, 27 Oct 2011 07:24:48 +0000 (10:24 +0300)]
tools: Add matches rule list loading support for iptables_test
Tomasz Bursztyka [Thu, 27 Oct 2011 07:24:47 +0000 (10:24 +0300)]
tools: Refactor iptables_test matches preparation
Tomasz Bursztyka [Thu, 27 Oct 2011 07:24:46 +0000 (10:24 +0300)]
tools: Move iptables_test target options merge in prepare_target
Tomasz Bursztyka [Thu, 27 Oct 2011 07:24:45 +0000 (10:24 +0300)]
tools: Code preparation for iptable-test option handling
Jukka Rissanen [Tue, 18 Oct 2011 10:17:46 +0000 (13:17 +0300)]
service: Remove the gateways when removing the service
This is needed because connection.c takes a reference
of the service so we want to remove the gateways properly
so that service can be deleted and IP addresses released
when disconnection comes from network side (like when
ethernet cable is disconnected).
Jukka Rissanen [Wed, 26 Oct 2011 07:15:59 +0000 (10:15 +0300)]
tools: Fix compilation in MeeGo
The _GNU_SOURCE needs to be defined so that O_CLOEXEC
symbols can be found in system header files.
The source does not compile without the patch in MeeGo 1.2
Jukka Rissanen [Wed, 26 Oct 2011 07:15:58 +0000 (10:15 +0300)]
core: Fix compilation in MeeGo
The _GNU_SOURCE needs to be defined so that O_CLOEXEC
symbols can be found in system header files.
The source does not compile without the patch in MeeGo 1.2
Jukka Rissanen [Wed, 26 Oct 2011 07:15:57 +0000 (10:15 +0300)]
plugins: Fix compilation in MeeGo
The _GNU_SOURCE needs to be defined so that O_CLOEXEC
symbol can be found in system header files.
The source does not compile without the patch in MeeGo 1.2
Daniel Wagner [Sun, 23 Oct 2011 12:16:30 +0000 (14:16 +0200)]
tools: Add SOCK_CLOEXEC to socket()
Make sure all file descriptor are closed.
Daniel Wagner [Sun, 23 Oct 2011 12:16:29 +0000 (14:16 +0200)]
core: Add SOCK_CLOEXEC to socket()
Make sure all file descriptor are closed.
Daniel Wagner [Sun, 23 Oct 2011 12:16:28 +0000 (14:16 +0200)]
plugins: Add SOCK_CLOEXEC to socket()
Make sure all file descriptor are closed.
Daniel Wagner [Sun, 23 Oct 2011 12:16:27 +0000 (14:16 +0200)]
gweb: Add SOCK_CLOEXEC to socket()
Make sure all file descriptor are closed.
Daniel Wagner [Sun, 23 Oct 2011 12:16:26 +0000 (14:16 +0200)]
gdhcp: Add SOCK_CLOEXEC to socket()
Make sure all file descriptor are closed.
Daniel Wagner [Sun, 23 Oct 2011 12:16:25 +0000 (14:16 +0200)]
core: Add O_CLOEXEC to open()
Make sure all file descriptor are closed.
Daniel Wagner [Sun, 23 Oct 2011 12:16:24 +0000 (14:16 +0200)]
plugins: Add O_CLOEXEC to open()
Make sure all file descriptor are closed.
Daniel Wagner [Sun, 23 Oct 2011 12:16:23 +0000 (14:16 +0200)]
tools: Add O_CLOEXEC to open()
Make sure all file descriptor are closed.
Jukka Rissanen [Fri, 21 Oct 2011 08:16:55 +0000 (11:16 +0300)]
service: Activate loose mode routing
If more than one service is connected at the same time,
then activate loose mode routing by setting the
/proc/sys/net/ipv4/conf/all/rp_filter to value 2
If the loose mode routing is not activated, then packets
are not routed properly if services are connected to same
subnet.
The original value of rp_filter is restored when the other
services are disconnected and only one service is connected.
For details of rp_filter setting, see Linux kernel file
Documentation/networking/ip-sysctl.txt
Fixes BMC#23606
Jukka Rissanen [Fri, 21 Oct 2011 08:16:54 +0000 (11:16 +0300)]
ipconfig: Set/unset IPv4 rp_filter setting
Jukka Rissanen [Tue, 18 Oct 2011 13:36:29 +0000 (16:36 +0300)]
network: Remove obsolete service lookup in disconnect
Jukka Rissanen [Tue, 18 Oct 2011 13:36:11 +0000 (16:36 +0300)]
service: Check NULL pointer
Daniel Wagner [Mon, 17 Oct 2011 13:50:17 +0000 (15:50 +0200)]
session: Do not select ongoing service again
In case Session.Connect() is called several times while
the selected services is still going from the IDLE state
to ONLINE state (or error state), do not call
select_and_connect() again. This leads to an inconsistent
ref counting on the service.
Fixes BMC#23630
Tomasz Bursztyka [Mon, 17 Oct 2011 13:51:32 +0000 (16:51 +0300)]
wispr: Reference count service properly according to contexts
Tomasz Bursztyka [Mon, 17 Oct 2011 13:51:31 +0000 (16:51 +0300)]
wispr: wispr_start will always re-start a new context
Tomasz Bursztyka [Mon, 17 Oct 2011 12:52:24 +0000 (15:52 +0300)]
service: wispr fallback when wpad fails
Tomasz Bursztyka [Mon, 17 Oct 2011 12:52:23 +0000 (15:52 +0300)]
wpad: Reference count service properly
Jukka Rissanen [Wed, 12 Oct 2011 13:41:46 +0000 (16:41 +0300)]
dhcp: Reference count network properly
Jukka Rissanen [Wed, 12 Oct 2011 13:05:18 +0000 (16:05 +0300)]
inet: Cleanup router solicitation callback properly after error
The cleanup routine must be called after an error and after
calling RS callback, otherwise the timeout is not removed
in right time.
Patrik Flykt [Wed, 12 Oct 2011 10:56:38 +0000 (13:56 +0300)]
notifier: Don't unnecessarily report "online" state on disconnect
When a service disconnects, don't send an extra 'online'
net.connman.Manager.StateChanged signal if another service is still
connected.
Fixes BMC#23421
Tomasz Bursztyka [Mon, 10 Oct 2011 10:09:11 +0000 (13:09 +0300)]
wispr: Set LoginRequired when wispr login is requested
Setting it while handling redirection is not bullet proof in case
of AP which does not implement well wispr and sends wispr content
with no redirection at first place.
Fixes BMC#23424
Yu A Wang [Tue, 11 Oct 2011 09:46:00 +0000 (09:46 +0000)]
dnsproxy: Fix can't resolv hostname
When we resolv hostname, we will append the domain name then we may
get question section mismatch error. After we get the DNS reply
we can remove the domain name again. This works well with one host
with only a A record, it may failed when the reply with many cnames
or additional records due to message compression error. But in a
local network we only resolv hostname will not meet these issues.
Modified by Julien Massot according to Samuel's comments.
Samuel Ortiz [Mon, 10 Oct 2011 16:12:35 +0000 (18:12 +0200)]
service: Update service order when changing the favorite flag
If the service order is not changed at the same time as the favorite
status, the service may stay on top of the service list despite not
being a favorite anymore.
Patch based on an initial fix from Danny Jeongseok Seo <s.seo@samsung.com>.
Yu A Wang [Mon, 10 Oct 2011 02:29:23 +0000 (22:29 -0400)]
Makefile: Add missed test files to test_scripts
Fixes BMC#23418
Yu A Wang [Mon, 10 Oct 2011 01:44:51 +0000 (21:44 -0400)]
service: Load ipconfig according to service identifier
We have seperate the storage file to different directories according
to service identifier, then we need to load it according to service
identifier too.
Fixes BMC#23475
Danny Jeongseok Seo [Fri, 7 Oct 2011 19:31:03 +0000 (21:31 +0200)]
service: Call __connman_service_disconnect from remove_service
Just calling __connman_network_disconnect() means missing proxy and
ipconfig clearance.
Patrik Flykt [Fri, 7 Oct 2011 09:35:41 +0000 (12:35 +0300)]
ipconfig: Show IPv4.Configuration properties for FIXED
Show IPv4.Configuration properties also for
CONNMAN_IPCONFIG_METHOD_FIXED configuration method.
Fixes BMC#23444
Patrik Flykt [Thu, 6 Oct 2011 13:08:10 +0000 (16:08 +0300)]
configure: Print errors if VPN binaries are not found
When a VPN has been enabled and its binary is not given
with '--with-<VPN>=PROGRAM', make an additional check
whether AC_PATH_PROG found the binary in question.
Marcel Holtmann [Thu, 6 Oct 2011 19:23:16 +0000 (12:23 -0700)]
log: Add support for backtrace symbole resolving
Marcel Holtmann [Thu, 6 Oct 2011 19:22:39 +0000 (12:22 -0700)]
build: Link session unit test with dynamic loader library
Alok Barsode [Thu, 6 Oct 2011 11:00:39 +0000 (14:00 +0300)]
technology: remove the pending_timeout source with g_source_remove
Alok Barsode [Thu, 6 Oct 2011 11:00:38 +0000 (14:00 +0300)]
device: Disconnect a connected network before disabling the device
When disabling a device, disconnect the device's connected network,
if there are any.
Fixes BCM#23165.
Samuel Ortiz [Thu, 6 Oct 2011 10:28:04 +0000 (12:28 +0200)]
AUTHORS: Mention Danny's contributions
Danny Jeongseok Seo [Thu, 6 Oct 2011 03:59:29 +0000 (12:59 +0900)]
device: Remove connections counter
The device connection counter is only used by the post scan auto connection
logic, and the connection status is handled by the autoconnection service
routine itself (__connman_service_auto_connect()).
Danny Jeongseok Seo [Thu, 6 Oct 2011 02:07:34 +0000 (11:07 +0900)]
device: Remove redundant connection numbers check
__connman_service_auto_connect() already checks for service state, so there
is no need to look at the device being connected or not.
Patrik Flykt [Fri, 30 Sep 2011 09:06:30 +0000 (12:06 +0300)]
service: Add interface name matching in __connman_service_lookup().
Fixes BMC#23419
Samuel Ortiz [Wed, 5 Oct 2011 09:46:08 +0000 (11:46 +0200)]
AUTHORS: Mention Philippe's contributions
Philippe Nunes [Fri, 30 Sep 2011 14:08:05 +0000 (16:08 +0200)]
ofono: Create the cellular network only when attached to the PS network
3G auto-connection may fail as the cellular network service may not be
ready to connect.
With this patch, the cellular network service should be exposed only after
PS network attachment is done.
Tomasz Bursztyka [Mon, 3 Oct 2011 07:43:23 +0000 (10:43 +0300)]
wispr: Setting the relevant service property when a login is required
When a wispr redirect occurs we set login required to the service
Fixes BMC#23424
Daniel Wagner [Thu, 29 Sep 2011 14:39:04 +0000 (16:39 +0200)]
session: Set dirty flag in de/select service function
Daniel Wagner [Thu, 29 Sep 2011 14:35:24 +0000 (16:35 +0200)]
session: Remove double assignment
The dirty flag is already cleared in append_notify()
Daniel Wagner [Fri, 30 Sep 2011 06:31:08 +0000 (08:31 +0200)]
session: Handle bearers update correctly
We cannot create a new service_list in populate_service_list
while we still hold pointers to entries (session->entry).
deselect_and_disconnect() would then operate on bogus pointers
leading to memory corruption
Fixes BMC#23325
Daniel Wagner [Tue, 27 Sep 2011 16:18:46 +0000 (18:18 +0200)]
session: Rename update_allowed_bearers()
Daniel Wagner [Tue, 27 Sep 2011 16:24:50 +0000 (18:24 +0200)]
session: Move update_allowed_bearers() up
Alok Barsode [Tue, 27 Sep 2011 08:47:17 +0000 (11:47 +0300)]
technology: Register a rfkilled technology in technology_add_rfkill
If a technology was rfkilled before connman ran, we need to register
it. If such tech was enabled, technology->device_list will be empty.
We save the state, rfkill unblock the type and exit. When the devices
get unblocked, they are automatically enabled since we saved the enable
state.
Tomasz Bursztyka [Fri, 23 Sep 2011 11:43:49 +0000 (14:43 +0300)]
tools: Fixed double-free error possibility into iptables-test
Tomasz Bursztyka [Fri, 23 Sep 2011 11:43:48 +0000 (14:43 +0300)]
iptables: Copyright year update
Tomasz Bursztyka [Fri, 23 Sep 2011 11:43:47 +0000 (14:43 +0300)]
iptables: Tiny indentation fix
Tomasz Bursztyka [Fri, 23 Sep 2011 11:43:46 +0000 (14:43 +0300)]
iptables: Adding capability to load necessary modules