Commit cbb12cfd authored by Lorn Potter's avatar Lorn Potter

Squashed 'connman/' changes from eda292c..075e1bb

075e1bb Release 1.21
8e5b064 device: Security should be provided when scanning for a hidden SSID
9768e63 AUTHORS: Mention Sjoerd's contributions
bdd3f1c gweb: Handle proxies as addresses and hostnames
b601ede .mailmap: Capitalize Zhengguang's name
7b7343b wifi: Remove WiFi.AgentPassphrase from the wifi plugin
d087ff2 network: Remove WiFi.AgentPassphrase from network
fb2d1c5 service: Remove duplicate EAP AgentPassphrase information
2ea3cb6 network: Return error code instead of boolean
68f0816 dnsproxy: Check if socket is valid before using it
6228f41 gsupplicant: Remove useless NULL pointer checks
557f99d tools: Ignore errors about deprecated g_test_trap_fork
8465f78 AUTHORS: Mention Jaehyun's and Zhengguang's contributions
df66c9c bluetooth: Fix failure when enabling Bluez 5.x adapter
3bba8c7 build: Remove gtk-doc infrastructure
08b9ffe gweb: Add checks to validate DNS buffer
91913c4 gsupplicant: A network ssid of length 0 is valid, it's an hidden one
8047f3d Release 1.20
03a7957 AUTHORS: Mention Bastien's, Michael's and Mateusz' contributions
cc63e68 service: Call disconnect notifier when leaving 'ready' or 'online' states.
0e2ee70 bluetooth_legacy: Handle network removal in the middle of enabling
363393c gsupplicant: Fix empty string test
3412d72 gsupplicant: Remove useless NULL pointer check
92472e8 gdhcp: Return proper error values
8ae0c48 session: Warn if nfacct support is missing
11f302a service: Call disconnect notifier only when connected
984b911 service: Update nameservers after IP state check
e174b78 service: Use only nameservers whose IP type is enabled
8df91a1 gsupplicant: Fix invalid memory access when network interface is removed
a05682b gsupplicant: Support function to call any pending callbacks
cd27afe build: Undefine _FORTIFY_SOURCE before redefining it
4e9355a network: Do not access pointer after testing its valitiy
373e56a nat: Free all resources in error case
8f48beb hh2serial-gps: Check error returns when during init()
ed11856 l2tp: Close file descriptors after use
377da67 iptables: Remove dead code
af4419c ipconfig: Remove dead code
155863b gdhcp: Remove dead code
284c964 client: strerror expects positive error codes
1987d61 6to4: Return error code when tunnel_create() fails
9dfd3fc dnsproxy: Check return value of get_req_udp_socket()
080bc05 provider: __connman_error_failed() expects positive error codes
9f245e1 vpn-manager: __connman_error_failed() expects positive error codes
e5cdf25 nfacct: Don't setup nfacct until it's relevant to do so
14cd5fd firewall: Don't do anything with iptables until really necessary
9774fa2 service: Return fallback nameservers when no other available
4a08c3b ntp: Support NTPv3 protocol version
f05ee18 dnsproxy-test: Close socket in error path
e6c7b22 tap-test: Set device name with null termination
f066853 wifi: Do not access unitialized timestamp
e6390f5 ipv4ll: Initialize socket variable
0457297 log: Do not access array out of bounds
17a300a timezone: Null terminate pathname
bd27133 rtnl: Do not access variables out of scope
0390d2b inet: Initialize flags to 0
b99a849 core: Set device name with null termination
cf09d7c inet: Close socket when leaving function early
2f00994 dbus: Initialize uid for error path
b39dfae service: Enable split routing
4da8143 bluetooth-legacy: Do not turn off hci device when ConnMan stops
62f62af bluetooth: Do not turn off hci device when ConnMan stops
496f513 device: Disable had too strict checks which can prevent disconnect
e08c88a dnsproxy: name variable should be initialized
7e2d1ec network: Remove adhoc check as it is not needed
e08e8f5 wifi: Ignore adhoc networks
4905dc1 wifi: Reset device retry count on failure
70388d1 wifi: Remove redundant initialization of zero'd wifi_data
e2703e2 dhcp: Add useful IPv4 ll debug information
32c1abe dhcp: Stop IPv4 ll state machine properly
a710cd3 gdbus: Fix trying to remove already removed sources
a44997b session: Remove policy_probe()
386f340 AUTHORS: Mention Chengyi's and Tysen's contributions
0465d8a iptables: iptables_replace returns the wrong error code
9f4185b ipconfig: Do not remember interface name
bcb7f23 rtnl: Do not remember interface name
8c7e5d0 technology: Do not use interface name when adding interface
168b6d8 technology: Do not use interface name when removing interface
1c81ca7 vpn: Removed unused interface name variable
d06050d rtnl: Set service type to unknown if interface can not be found
da0f632 network: Stop DHCP for a failed network
39b0822 gweb: Fix memory leak in session address
51fb2c8 scripts: Function prototype fixes when function has no parameters
8fc31fe plugins: Function prototype fixes when function has no parameters
5c7a37b vpn: Function prototype fixes when function has no parameters
671c905 tools: Function prototype fixes when function has no parameters
ded0e13 src: Function prototype fixes when function has no parameters
278e0ce dnsproxy: Fix crash because cache is NULL
489127f gdbus: Remove not needed check for NULL DBusPendingCall
575de63 gdbus: Check for NULL DBusPendingCall in g_dbus_send_message_with_reply
4f9d0f6 Release 1.19
af6d530 main.conf: Update FallbackNameservers description
56ca4ac service: Add fallback nameservers to the Nameservers property
10fe61d resolver: Use fallback nameservers when none are otherwise supplied
87919ec config: Set the list separator to be comma
86c6980 wispr: Get the proper proxy address from the result
38b75ab gweb: Properly proceed a request through a proxy when one is set
aaafe0b service: Proxy should be reset when disconnecting
3ddbe85 pacrunner: Let ConnMan autostart PACrunner when doing proxy lookup
eb768d3 session: Remove struct service_entry
4833fcf session: Remove connect reason from struct service_entry
536367c service: Remove state argument from service_iterator_cb()
5edc149 session: Use service state getter
89ae11a service: Add getter for service state
8ecefc4 session: Move service_entry to struct connman_session
6715a43 session: Use a hash table to lookup sessions by service_entry
3de0402 service: Remove service name in service_iterate_cb()
8314cd2 session: Do not cache service name, type or bearer
8bd49d8 service: Run autoconnect on service disconnects
64fd6a0 device: Remove unused reconnect setting functions
7963aad service: Remove reconnect functions
98d2b81 service: Log only on service add and remove from network
a632fc3 service: Reduce logging when appending properties
1b87cd7 device: Do not cleanup already provisioned interfaces
39a68b3 inet: Add function to return interface IPv4 address and netmask
fd9f99e config: Add function to check if IP address is provisioned
0e46b1c TODO: Fix formatting
ee65cb1 TODO: Add VPNC and OpenVPN VPN Agent task
f9e2b0f service: Load and save VPN autoconnect state
49e739a service: Add VPN autoconnect
e85f2f2 service: Update service list sorting
909990b client: Add a no-op input handler
b2199d0 client: Fix unintended Manager monitor messages
3a92f7e vpn: Update error_code() signature change
fb92c17 openconnect: Unset Cookie on login failed
c4a0275 vpn: Add provider struct to error code function
2cce14a service: Check for immutable VPN service properties
f0455e2 provider: Add a provider-specific immutable flag
3d3b374 service: Take ordering into account when comparing connected services
664e9c0 service: Fix VPN and service list order
b80cddd core: Make stats hash table static
eba9a6e service: Simplify return code in connman_service_get_timeservers()
8133c32 dhcp: Store host and domain name in service struct
ba9ec13 service: Set host and domain names when default service changes
94804e1 service: Add functions to set/get a host name per service
aa5b7d3 gdbus/client: Use g_dbus_add_properties_watch to track properties
b2e7c61 gdbus/client: Use g_dbus_add_signal_watch to track signals
5350bac gdbus/client: Use g_dbus_add_service_watch to track services
807509e gdbus/watch: Fix crash when disconnecting from D-Bus
8996db2 gdbus/watch: Fix aborting when removing D-Bus filter
b169ad9 gdbus/watch: Fix crash when g_dbus_remove_watch is called from connect callback
a5238e7 TODO: Mark Session API implementation done
ce9fcdb session: Remove pending functions
0db0d38 service: Remove session reference counting functions
ac73850 session: Remove service reference counting
0d69def doc: Update SessionMode description
34e6ffb manager: Remove implementation around SessionMode
f863575 session: Only add and remove connected services
ebe52c5 service: Add helper function for fetching the name of a service
3ae61c3 session: Remove calls to service connect and disconnect
0a9606e service: Use session information when autoconnecting
fdcda5a session: Update autoconnect with active session service types
3526fbf service: Add function counting number of sessions using a service type
98473aa service: Reorganize service autoconnect function
75ec8d2 service: Simplify autoconnect code
c0a1d90 tools: Update session unit tests
c71bd85 tools: Fix already exists test
4121dbe TODO: Mark multiple agents task done
ba87b99 agent: Make sure there is an agent before asking user
6352c3f vpn: Make sure there is an agent before asking user
c53b88e agent: Add multi agent support
1b986e1 agent: API changes required for multi agent support
b7b0d64 vpn: Unregister agent driver before removing provider
1b0629f service: Unregister agent driver before removing service
bfaa23f agent: Check that message exists before calling dbus
cb25395 agent: Change the name of the agent struct
3ca00a8 gdbus: Fix emitting PropertiesChanged twice
0d86c21 gdbus: Avoid calling dbus_connection_send*
31764f9 gdbus: Add g_dbus_send_message_with_reply
202b74f gdbus: Fix sending ObjectManager/Properties signals out of order
5619eb9 config: Allow omitting gateway from IPv4 and IPv6 setting
7cc0b72 service: Change default service before updating service order
2be7d77 service: Do not change default service if new default is not connected
1ffe8aa service: Re-doing wispr check needs to increment service ref count
b1741a0 service: Clear default service pointer when service is removed
c9d8a0a service: More debug prints when default service is changed
110abe3 ipconfig: Fix possible memory leak in ipconfig loading
55ec085 ipconfig: Make sure IPv4 method is set before saving it
21cace4 vpn-provider: ProtocolFamily is an int32
d40329b ofono: Remove unused variable
4dc3410 bluetooth: Leading whitespace fix
d1665b4 bluetooth: Use dbus_bool_t when accessing a D-Bus boolean
dda5546 dundee: 32bits boolean should be used due to dbus in relevant places
1281e8b vpn: 32bits boolean should be used due to dbus in relevant places
1997f45 ofono: 32bits boolean should be used due to dbus in relevant places
13fe78c service: 32bits boolean should be used due to dbus in relevant places
479c973 technology: 32bits boolean should be used due to dbus in relevant places
cf064e9 Release 1.18
a5d3817 TODO: Update command line client task
33ebe58 service: Debug print caused segfault
377c594 doc: Improve plugin documentation
4215992 log: Replace timebased ratelimit function with one that prints once
1ef0b07 service: Do not clear 802.1x credentials when connecting
167dc80 loopback: Fix spelling of loopback
719dcfb config: Return success after reading ethernet service section
316cfc4 AUTHORS: Mention Luca's and Peter's contributions
92cf003 vpn: Document that values in vpn-config-format.txt do not comprise whitespace
4c66d75 vpn: Use function to trim trailing whitespace
2d61b56 vpn: Add functions trimming trailing whitespace when reading config values
a9c7ad1 doc: Document that values in config-format.txt do not comprise whitespace
eb9da48 config: Use function to trim trailing whitespace when reading config files
a380bb1 config: Add functions trimming trailing whitespace when reading config values
24ed0b2 ipconfig: Accept correct spelling of preferred
db95cff client: Display correct spelling of preferred in connmanctl usage text
b33b5c2 doc: Fix typo of preferred
8d2d14c doc: Fix typos in advanced-configuration.txt
a996d84 client: Fix setting session state to disconnected
0350fc3 wifi: Fix a memory leak when trying to connect a disconnecting network
b872618 rtnl: Print out warning when WEXT newlink messages are seen
95cde6f log: Add rate limiting warn message
8e4b5d7 gsupplicant: Use uint32 instead of string for wep_tx_keyidx
26ada06 client: Add Session configuration support
0b0dfaf client: Add support functions for Session Update message creation
b8c8540 client: Add Session notification printing and Release handling
6150b8a client: Initial session support
ed2d980 client: Add helper function for adding a D-Bus dict
52ec323 client: Add append function to D-Bus method call helper
c43d3a5 main: Use gboolean type in GOptionEntry
115cb9c readme: Document kernel options needed by session
ba4d4ed nfacct: Make sure nfacct is there before accessing it
d482e18 iptables: Alignment fixes
b5d9c25 client: Remove unnecessary printout
2d1f9cd client: Rename command completion callback function
892b803 client: Implement autocompletion for offline mode
5a3c477 client: Fix service and technology completion while monitoring
55f6589 client: Add completion for technologies
0ef9b74 client: Add completion for services
477173f Release 1.17
8378438 tethering: Check failure if NAT cannot be enabled
024c06d inet: Clarify the code by not casting the function pointer
1dc0844 dhcpv6: Timeout timer was not cleared after receiving a reply
eadec4e todo: Mark DHCPv6 DECLINE message support done
e51c91f dhcpv6: Check if we need to do DAD
c7fcf8f dhcpv6: Add DECLINE message support
61be283 dhcpv6: Use different callback than DHCPv4
ebd29dc gdhcp: Add DHCPv6 DECLINE message checks
1da88d5 gdhcp: Add function that adds addresses to IA_NA or IA_TA options
ca32a30 gdhcp: Add function to remove DHCPv6 options that should not be sent to server
508526d dhcpv6: Added duplicate address detection calls
06c892f service: Do not try to save if service is NULL
7351d73 inet: Add function for IPv6 Duplicate Address Detection
fd2c1d4 main: Ensure the end of service type list is set properly
9857cd6 session: Use D-Bus owner to create unique paths for sessions
d146379 session: Error function expects positive values
d811fdb tools: Fix compilation warning on possible uninitialization
65f1ff1 service: Do not send state changed signal if we are already in idle state
6b64387 service: Newline cleanup
38c1662 dhcpv6: Expire time was incorrectly calculated
60ee35f ippool: IP address collision fix
d2b3f4e ippool: Removed inclusion of getopt.h as it is not needed
6185fd6 wifi: Postpone an hidden discovery if a scan is already running
5786830 device: Let the scan function to decide on current status
419c4c7 gsupplicant: Make sure it's possible to scan again when a scan is done
600f186 openvpn: Don't set additional VPN network properties
c96f0cc pptp: Don't set additional VPN network properties
c871ca6 l2tp: Don't set additional VPN network properties
312270a doc: Update Service API doc with provisioned and hidden WiFi
444e084 doc: Change coding style for NULL pointer checks
8e0b538 tools: Fix whitespace issue
aa1e9fb shared: Fix whitespace issue
7cc0e05 core: Fix overlong line
0f418b4 gweb: Fix overlong line
90cdfca gdhcp: Fix overlong line
747f6ca client: Remove unnecessary braches
72f711b client: Fix whitespace issues
6764183 core: Do not compare expression against NULL
313d102 vpn: Do not compare expression against NULL
a0a24ba unit: Do not compare expression against NULL
c879c4f tools: Do not compare expression against NULL
bd99aaa core: Do not compare expression against NULL
bc16b1a scripts: Do not compare expression against NULL
9c779a4 plugins: Do not compare expression against NULL
98cd55e gweb: Do not compare expression against NULL
555a166 gsupplicant: Do not compare expression against NULL
fae59f2 gdhcp: Do not compare expression against NULL
b8311f9 client: Do not compare expression against NULL
37472f1 ofono: Use dbus_bool_t for D-Bus functions
68445cb dnsproxy: Possible socket leak if running out of memory
d6a3a39 bluetooth: Check pointer for null before passing to strcmp()
72fc5cf bluetooth: Address pointer might be null when creating nap
c27e223 client: Avoid possible uninitialized memory access
242bb5a dhcpv6: Check that prefix is in valid range
5a46026 gdhcp: Remove obsolete dhcpv6 support functions
4f3a601 gdhcp: Remove function to set the dhcpv6 expire time
584fecd dhcpv6: Fix rebind when doing prefix delegation
e513e25 dhcpv6: Start solicitation if addresses expired
038c6fd dhcpv6: Fixing the renew and rebind logic
f07141b dhcpv6: REBIND IA option was missing IP addresses
f281d25 dhcpv6: REBIND was sent too late
884babd dhcpv6: Do REBIND after T2
305b607 client: Don't pretty-print hidden WiFi network as '<hidden>'
6fd9e3f service: Always notify pending D-Bus clients of disconnect
862159c doc: Document that unplugging Ethernet will remove the service
e67f44e README: Add info how to create traces with timestamps
8c99c24 dhcp: Add interface index to DHCP debug label
a063238 gdhcp: Use REQUEST_TIMEOUT for renew request
8bf42fc dhcp: Add a separate DHCP client for IPv4LL
6feedae gdhcp: Report no lease found instead of starting IPv4LL
0508254 AUTHORS: Mention Terry's contributions
c562954 gdhcp: Fix byte order for send_discover()
7a2d00e technology: Do not send any rfkill to kernel after receiving one
10ce0a8 technology: Check hardblock when returning from offline mode
7044545 gsupplicant: Only add interface when wpa_supplicant is in ready state
507c98f dhcp: Pass in stdbool type values to the DHCP callback
fd9e5c6 ofono: Fix bool type for D-Bus message
40aa7a2 technology: Fix style issue caused by earlier coccinelle patch
7026821 session-utils: Use g_test_add_vtable directly
d4d6f5d vpnc: Use stdbool defines for true and false
d4fa1ce main: Use stdbool defines for true and false
fbf9f8d config: Use stdbool defines for true and false
543dbfd connection: Use bool type instead of int
d052eb3 TODO: Mark bool cleanup done
86d2592 build: Remove unsued types.h header
15d8db8 vpn: Whitespace cleanup
817053d unit: Whitespace cleanup
c75d61f tools: Whitespace cleanup
8847596 core: Whitespace cleanup
e1eedf1 scripts: Whitespace cleanup
7918142 gsupplicant: Whitespace cleanup
2f4c06d gdhcp: Whitespace cleanup
571fdfd client: Whitespace cleanup
ad7abb5 plugins: Whitespace cleanup
b89fa6d vpn: Convert to stdbool with coccinelle
0f3df75 unit: Convert to stdbool with coccinelle
47e034b tools: Convert to stdbool with coccinelle
a56c9f7 core: Convert to stdbool with coccinelle
bf61588 scripts: Convert to stdbool with coccinelle
304dfa9 plugins: Convert to stdbool with coccinelle
30773ab include: Convert to stdbool with coccinelle
8c2ca22 gweb: Convert to stdbool with coccinelle
165eec0 gsupplicant: Convert to stdbool with coccinelle
11ee4af gdhcp: Convert to stdbool with coccinelle
df2ae22 client: Convert to stdbool with coccinelle
0ca492b core: Included stdbool.h
5d56021 plugins: Included stdbool.h
5b87a18 tools: fix include
5b4bbff gdhcp: Included stdbool.h
1a8e8a3 gweb: Included stdbool.h
e25fc73 vpn: Included stdbool.h
22afaa9 include: Included stdbool.h
a77455e vpn: Use dbus_bool_t with D-Bus functions
14b4bba tools Use dbus_bool_t with D-Bus functions
5d92b1e plugins: Use dbus_bool_t with D-Bus functions
647ecc0 core: Use dbus_bool_t with D-Bus functions
1f63c00 dnsproxy: Use boolean variables correctly
c190e46 session-test: Pass in struct test_fix into tests
adce56f session: Use GLib typedef for callback
1daa424 timeserver: Fix ts_recheck() signature
3cf33b7 readme: USB gadget tethering kernel options added
be294f9 ethernet: Create USB gadget device driver
ad79c1a technology: Return error if no devices can be found for a technology
339f05f technology: Technology must have a name when saving its data
9d1fbfe technology: USB gadget technology type had no name
f020c1e wifi: Make sure we ref the network before using it in callback
677b2d4 session: Do not delete invalid policy routing entry
ae6afc2 build: Build a simpler version of libgdbus-internal
42cf3ab build-sys: Use
70e7b0d doc: Add information how Technologies can be controlled
48dbff3 technology: Follow external rfkill events and act accordingly
c3c35b8 technology: Checking offline mode separately when rfkill device is added
f2a958c technology: Do not activate technology if returning from hardblock while in offline mode
5378ab9 technology: Print information when technogy is switched on
54f0d5c Release 1.16
831028d AUTHORS: Mention Constantin's contributions
8b1f599 inet: Check parameters before trying to clear IP address
46bbe4e wifi: Memory leak when creating a supplicant scan request
8b952da plugin: Remove NEED_THREADS
5bd3965 service: Send state changed signal after downgrading state
ea030b9 nat: Use managed iptables API for MASQUERADE rule
db4dc1a dhcpv6: Update service DNS search domain list
edcb7fa service: Add function to update the DNS search domain list
bb06c47 gdhcp: Domain search list DHCPv6 option is checked
df37290 dhcpv6: Do not send DNS options in CONFIRM message
b3a7700 readme: Add bug reporting information
31005cf build: Remove unused --enable-threads configure switch
ffe6305 wifi: Interface creation callback might arise when it is not ready yet
f62d6d6 nfacct: Use unsigned int for error codes
c7e1574 shared/nfacct: Use unsigned int for error codes
d534dc6 shared/netlink: Use unsigned int for error codes
a727163 shared/util: Move cb_data_new() helpers to util header
f3775eb readme: Clarify how the wpa_supplicant D-Bus autostart behaves
a0786d8 client: Support openconnect Agent API fields
2052499 openconnect: Add support for final VPN server
0a99d79 openconnect: Use VPN string OpenConnect.ServerCert
67df5dc openconnect: Use OpenConnect.ServerCert from the RequestInput reply
45d6b58 openconnect: The --cafile argument is not needed for openconnect
daadd1b openconnect: Drop cookie argument from run_connect()
e4ce120 openconnect: Use oc_private_data instead of request_input_reply
90dffd5 openconnect: Move code earlier in the file
d758a7b openconnect: Request missing openconnect information
70880bb doc: Document openconnect certificate and server options
f101bba dhcpv6: Set addresses after we have checked the status code
d79565c dhcpv6: Set addresses from CONFIRM reply if status is ok
06b4396 dhcpv6: Most of the reply error handling was missing
1f5c57d dhcpv6: Enable checking of reply error codes
aa5413f tethering: Cleanup tethering when connman is shutting down
30c0dbc inet: Remove unused gateway setting functions
10a3beb connection: Use netlink functions to set default gateway
8aae35a tethering: Use the prefix length from ippool instead of hard coded value
f7b865e tethering: Add debug print so we notice restarts
3ddffce nfacct: Do not fail in nfacct_flush_cb() when NFACCT is not supported
17badd6 netlink-test: Use assertion to verify results
a5f3d04 nfacct: netlink uses positive error codes
83bb349 ipv6pd: Change PD status according to uplink IPv6 status
416a2d6 ipv6pd: Check IPv6 support
6b43ca3 ipconfig: Add support function to return ipconfig IPv6 status
1243114 network: Set service disconnect state correctly
3b98cf0 network: Function name was missing a proper prefix
55f5273 tethering: Activate IPv6 prefix delegation support when tethering
905c0e9 ipv6pd: IPv6 prefix delegation implementation logic
55b7b2d dhcpv6: Add prefix delegation release support
50c44d5 dhcpv6: Add prefix delegation renew support
68bc0b7 dhcpv6: Initial IPv6 prefix delegation support
73f1b79 ipconfig: Save and load delegated IPv6 prefixes
24fc3de inet: Add functions to receive ICMPv6 router solicitation messages
4b6daf1 inet: Add function to send ICMPv6 router advertisement message
1744fd5 gdhcp: Print more error information if DHCPv6 message send failed
a25b411 gdhcp: Get server DUID if we do not know it yet
f59d373 gdhcp: Read only sub-option amount of data
c88cd2e gdhcp: IPv6 prefix delegation support
707f011 gdhcp: Pretty print DUID to the debug log
9fe12b7 gdhcp: Ignore server DUID missing error
3051ef6 gdhcp: Print debug information about sent requests
d9a852d inet: Enhance debug print usefullness
9d99f58 inet: Return errors correctly when setting multicast options
932e1b9 inet: Add function to get the link local address attached to an interface
3aa5313 inet: Fix IPCMv6 checksum calculation
6520dc9 doc: Update Session overview
462d368 netlink-test: Use open coded message creation instead of struct
333f863 netlink-test: Fix printf format string for uint64_t
be21997 nfacct: Fix DBG() format string for uint64_t
41f3712 README: Add kernel config options for full Session support
bd8cd2c session: Add routing and accounting iptables rules
45c3bbd session: Add global firewall rules
f48f9b9 session: Add policy routing table
009171b session: Add NFACCT rules per session
cd8a209 session: Flush all NFACCT rules on bootup
36e2dcc session: Store creation related data into a struct
21aa00b nfacct: Add helper function for managing several rules
755217a nfacct: Add __connman_nfacct_flush()
19ca578 netlink-test: Add NFACCT low level test
41c54f5 nfacct: Add NFACCT
fd71731 shared: Add a copy of the nfnetlink_acct.h kernel header
030f578 netlink-test: Add test program for netlink
d25b22c netlink: process_multi() should call handler on done
d765b15 netlink: Port ELL's version of netlink
32baa22 inet: Add function to remove default route from a routing table
a4d3e1b inet: Add function to setup default route to a routing table
cba24db inet: Add functions to setup fwmark to routing table
1d64996 session_policy_local: Don't look up hash tables using NULL key
e8344a9 session_policy_local: Add support for UID/GID only
49671af session_policy_local: Call failed_create() with the real user pointer
aeaeb4b gdbus: Remove proxies when client disconnects
260608b wifi: Memory leak when tethering
9286090 ippool: Memory leak
fbe905a client: Fix passphrase handling
cbc629f client: Implement VPN Agent API RequestInput method call
66dcdec client: Add vpnagent command to register and unregister VPN Agent
1ac8610 client: Implement support for queueing Agent messages
01fe75b client: Add VPN Agent support for Release, Cancel and ReportError
2e43802 client: Create agent data structure and pass it in function callbacks
ba7f46b client: Don't handle Agent messages in monitor code
ab78ab7 client: Fix DBUS_TYPE_UINT16 pretty-printing
475a695 dhcpv6: Send domain list option to server
05a3f47 unit: Multiple collisions with different pools
e51fdfd unit: Test ippool collision differently
35ccdc8 ippool: Clear allocated block pointer at cleanup
5f5910b ippool: Private address check was incorrect
58ec105 service: Send proxy properties when connected or disconnected
b4f0e90 technology: Offlinemode could not be disabled if no technology was powered
4c50210 TODO: Mark GSequence removal done
02d4740 service: Use GList instead of GSequence for service list
afa245f session: Use GList instead of GSequence for service list
9342269 session: Use service iterator instead of match/creation callbacks
2386b67 service: Initialize tech_data
2476ce7 client: Avoid printing extra prompt on RequestInput
db6ec6b client: Read D-Bus string type only if argument is 'Type'
a6aa682 client: Pretty-print D-Bus signed integers
9a048c1 client: Add VPN monitoring support
ab7294a client: Add support for displaying VPN connections
667f355 client: Add VPN connection helper function
5186846 client: Add parameter to specify D-Bus service for method call
032adc9 client: Add missing header file boilerplate
77ade69 dhcpv6: Make sure release message is sent
0515b22 build: Add session policy format document
df1a4cb doc: Document session policy file format
7eca790 session-test: Add tests for session_policy_local
b553c5a session_policy_local: Set session identification method
2ffa1d6 session: Add session identification method to config
9c5cb53 session_policy_local: Retrieve UID/GID from session user
42679c8 session_policy_local: Remove struct create_data
f71ccc8 session_policy_local: Rework policy file handling
f75c792 session_policy_local: Add some more debug information
61ed5e2 session_policy_local: Update session before unref policy
99249a4 session_policy_local: Refactor SELinux context parser
3fb5619 session_policy_local: Do not handle small allocation
d6f82bb session: Do not access stale entry pointers
e329cc8 session: Add session argument to create_service_entry_cb
32a8cf5 TODO: Support other time sources
3b70a3d timeserver: Periodically wake up to recheck timeservers
bac356f iptables: Fix memory leak when invoking xtables_find_match

git-subtree-dir: connman
git-subtree-split: 075e1bbdda5b2ba2bba6fc75e458684365e5c6e9
parent 570d90f8
* Connection Manager
* Copyright (C) 2013 Intel Corporation. All rights reserved.
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* GNU General Public License for more details.
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
#include <config.h>
#include <stdio.h>
#include <string.h>
#include <glib.h>
#include "vpnconnections.h"
static void print_connection(char *path, DBusMessageIter *iter)
char *name = "";
char state = ' ';
char *str;
char *property;
DBusMessageIter entry, val;
while (dbus_message_iter_get_arg_type(iter) != DBUS_TYPE_INVALID) {
dbus_message_iter_recurse(iter, &entry);
dbus_message_iter_get_basic(&entry, &property);
if (strcmp(property, "Name") == 0) {
dbus_message_iter_recurse(&entry, &val);
dbus_message_iter_get_basic(&val, &name);
} else if (strcmp(property, "State") == 0) {
dbus_message_iter_recurse(&entry, &val);
dbus_message_iter_get_basic(&val, &str);
if (str) {
if (strcmp(str, "ready") == 0)
state = 'R';
else if (strcmp(str, "configuration") == 0)
state = 'C';
else if (strcmp(str, "failure") == 0)
state = 'F';
str = strrchr(path, '/');
if (str)
str = path;
fprintf(stdout, " %c %-20s %s", state, name, str);
void __connmanctl_vpnconnections_list(DBusMessageIter *iter)
DBusMessageIter array, entry, dict;
char *path = NULL;
if (dbus_message_iter_get_arg_type(iter) != DBUS_TYPE_ARRAY)
dbus_message_iter_recurse(iter, &array);
while (dbus_message_iter_get_arg_type(&array) == DBUS_TYPE_STRUCT) {
dbus_message_iter_recurse(&array, &entry);
if (dbus_message_iter_get_arg_type(&entry)
dbus_message_iter_get_basic(&entry, &path);
if (dbus_message_iter_get_arg_type(&entry)
dbus_message_iter_recurse(&entry, &dict);
print_connection(path, &dict);
if (dbus_message_iter_has_next(&array))
fprintf(stdout, "\n");
fprintf(stdout, "\n");
......@@ -2,11 +2,12 @@
* Connection Manager
* Copyright (C) 2007-2012 Intel Corporation. All rights reserved.
* Copyright (C) 2013 Intel Corporation. All rights reserved.
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 as
* published by the Free Software Foundation.
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
......@@ -19,25 +20,19 @@
#include <dbus/dbus.h>
#ifdef __cplusplus
extern "C" {
#ifndef FALSE
#define FALSE (0)
#ifndef TRUE
#define TRUE (!FALSE)
typedef int connman_bool_t;
void __connmanctl_vpnconnections_list(DBusMessageIter *iter);
#ifdef __cplusplus
#endif /* __CONNMAN_TYPES_H */
......@@ -55,6 +55,7 @@ tools/stats-tool
......@@ -66,10 +67,6 @@ doc/connman.*
......@@ -2,3 +2,4 @@ Luiz Augusto von Dentz <> <>
Leena Gunda <> <>
Flávio Ceolin <> <>
Daniel Wagner <> <>
Zhang Zhengguang <> <>
......@@ -52,3 +52,15 @@ Ceara Chewning <>
Johannes Berg <>
Justin Maggard <>
Yann E. Morin <>
Constantin Musca <>
Terry Simons <>
Luciano Coelho <>
Peter Meerwald <>
Chengyi Zhao <>
Tysen Moore <>
Bastien Nocera <>
Michael Ikey Doherty <>
Mateusz Potrola <>
Jaehyun Kim <>
Zhang Zhengguang <>
Sjoerd Simons <>
ver 1.21:
Fix issue with WiFi networks and zero SSID length.
Fix issue with security details for hidden WiFi networks.
Fix issue with handling IPv6 proxy address resolving.
Fix issue with enabling Bluetooth controllers.
ver 1.20:
Fix issue with invalid cache of DNS proxy support.
Fix issue with stopping DHCP for failed connections.
Fix issue with not stopping IPv4 Link-Local state machine.
Fix issue with service type handling for unknown interfaces.
Fix issue with using interface names instead of indexes.
Fix issue with resetting network retry counter on failure.
Fix issue with using nameservers when its type is not enabled.
Fix issue with fallback nameservers not being used.
Add support for NTP version 3 protocol.
ver 1.19:
Fix issue with not correctly storing IPv4 method.
Fix issue with changing the default service too early.
Fix issue with service reference count and WISPr checks.
Fix issue with service auto-connect handling and ordering.
Fix issue with host and domain names when service changes.
Fix issue with proxy result and WISPr handling.
Fix issue with proxy reset when disconnecting.
Fix issue with handling fallback nameservers.
Add support for multiple agents.
ver 1.18:
Fix issue with alignment calculation for iptables.
Fix issue with WEP key index parameter handling.
Fix issue with handling of 802.1x credentials.
Fix issue with command line parameter parsing.
Add support for completion handling in client tool.
ver 1.17:
Fix issue with handling consecutive WiFi scanning.
Fix issue with WiFi handling and RFKILL soft block.
Fix issue with handling external RFKILL events.
Fix issue with handling USB gadget devices.
Fix issue with network reference handling.
Fix issue with byte order and DHCP discover options.
Fix issue with DHCP retry handling during IPv4-LL.
Fix issue with DHCPv6 rebind handling.
Add support for DHCPv6 decline message handling.
Add support for DHCPv6 duplicate address detection.
ver 1.16:
Fix issue with missing signals during connection changes.
Fix issue with missing notification of proxy properties.
Fix issue with missing DHCPv6 domain list option.
Fix issue with missing DHCPv6 release message.
Fix issue with missing DHCPv6 error handling.
Fix issue with wrong IPCMv6 checksum calculation.
Fix issue with wrong service disconnect state.
Fix issue with failure to enable offline mode.
Add support for Netfilter Accounting (NFACCT).
Add support for IPv6 prefix delegation handling.
ver 1.15:
Fix issue with missing cleanup for IPv4-LL handling.
Fix issue with missing property update for domain names.
......@@ -107,38 +107,3 @@ can get very complex. The first detail inside "{ ... }" is the interface
name (without its service name prefix). The second detail inside "[ ... ]"
is the object path. And after that it is followed by a key and value of
the property that changed.
Generating source code documentation
The source code is annotated using the gtk-doc style documentation. This
allows an easy way of generating API documentation. The "bootstrap-configure"
script will use the "--enable-gtk-doc" configure to enable the generation of
the documentation.
To make the gtk-doc process work, the gtk-doc tools need to be installed.
Every distribution should provide a package for this, but the naming of the
package might be different:
# apt-get install gtk-doc-tools
# apt-get install gtk-doc-utils
# yum install gtk-doc
In case "bootstrap-configure" is not used, the manual steps for generating
the documentation files are like this:
Configuring the repository
# ./configure --enable-gtk-doc
Generate the documentation
# cd doc && make
View documentation
# firefox doc/html/index.html
AM_MAKEFLAGS = --no-print-directory
includedir = @includedir@/connman
include_HEADERS = include/types.h include/log.h include/plugin.h \
include_HEADERS = include/log.h include/plugin.h \
include/notifier.h include/service.h \
include/resolver.h include/ipconfig.h \
include/device.h include/network.h include/inet.h \
......@@ -23,7 +25,10 @@ local_headers = $(foreach file,$(include_HEADERS) $(nodist_include_HEADERS) \
$(noinst_HEADERS), include/connman/$(notdir $(file)))
gdbus_sources = gdbus/gdbus.h gdbus/mainloop.c gdbus/watch.c \
noinst_LTLIBRARIES += gdbus/
gdbus_libgdbus_internal_la_SOURCES = gdbus/gdbus.h \
gdbus/mainloop.c gdbus/watch.c \
gdbus/object.c gdbus/client.c gdbus/polkit.c
gdhcp_sources = gdhcp/gdhcp.h gdhcp/common.h gdhcp/common.c gdhcp/client.c \
......@@ -37,6 +42,11 @@ else
gweb_sources += gweb/giognutls.h gweb/gionotls.c
shared_sources = src/shared/util.h src/shared/util.c \
src/shared/netlink.h src/shared/netlink.c \
src/shared/nfacct.h src/shared/nfacct.c \
......@@ -81,8 +91,8 @@ MANUAL_PAGES =
sbin_PROGRAMS = src/connmand
src_connmand_SOURCES = $(gdbus_sources) $(gdhcp_sources) $(gweb_sources) \
$(builtin_sources) src/connman.ver \
src_connmand_SOURCES = $(gdhcp_sources) $(gweb_sources) \
$(builtin_sources) $(shared_sources) src/connman.ver \
src/main.c src/connman.h src/log.c \
src/error.c src/plugin.c src/task.c \
src/device.c src/network.c src/connection.c \
......@@ -97,10 +107,11 @@ src_connmand_SOURCES = $(gdbus_sources) $(gdhcp_sources) $(gweb_sources) \
src/session.c src/tethering.c src/wpad.c src/wispr.c \
src/stats.c src/iptables.c src/dnsproxy.c src/6to4.c \
src/ippool.c src/bridge.c src/nat.c src/ipaddress.c \
src/inotify.c src/firewall.c
src/inotify.c src/firewall.c src/nfacct.c src/ipv6pd.c
src_connmand_LDADD = $(builtin_libadd) @GLIB_LIBS@ @DBUS_LIBS@ \
@XTABLES_LIBS@ @GNUTLS_LIBS@ -lresolv -ldl -lrt
src_connmand_LDADD = gdbus/ $(builtin_libadd) \
-lresolv -ldl -lrt
src_connmand_LDFLAGS = -Wl,--export-dynamic \
......@@ -117,7 +128,7 @@ builtin_vpn_cflags =
sbin_PROGRAMS += vpn/connman-vpnd
vpn_connman_vpnd_SOURCES = $(gdbus_sources) $(builtin_vpn_sources) \
vpn_connman_vpnd_SOURCES = $(builtin_vpn_sources) \
$(gweb_sources) vpn/vpn.ver vpn/main.c vpn/vpn.h \
src/log.c src/error.c src/plugin.c src/task.c \
vpn/vpn-manager.c vpn/vpn-provider.c \
......@@ -127,8 +138,9 @@ vpn_connman_vpnd_SOURCES = $(gdbus_sources) $(builtin_vpn_sources) \
vpn/vpn-agent.c vpn/vpn-agent.h src/inotify.c \
vpn_connman_vpnd_LDADD = $(builtin_vpn_libadd) @GLIB_LIBS@ @DBUS_LIBS@ \
@GNUTLS_LIBS@ -lresolv -ldl
vpn_connman_vpnd_LDADD = gdbus/ $(builtin_vpn_libadd) \
-lresolv -ldl
vpn_connman_vpnd_LDFLAGS = -Wl,--export-dynamic \
......@@ -228,15 +240,16 @@ noinst_PROGRAMS += client/connmanctl
noinst_MANUAL_PAGES = doc/connmanctl.1
client_connmanctl_SOURCES = $(gdbus_sources) \
client/dbus_helpers.h client/dbus_helpers.c \
client_connmanctl_SOURCES = client/dbus_helpers.h client/dbus_helpers.c \
client/services.h client/services.c \
client/commands.h client/commands.c \
client/input.h client/input.c \
client/agent.h client/agent.c \
client/vpnconnections.h client/vpnconnections.c \
client_connmanctl_LDADD = @DBUS_LIBS@ @GLIB_LIBS@ -lreadline -ldl
client_connmanctl_LDADD = gdbus/ @DBUS_LIBS@ @GLIB_LIBS@ \
-lreadline -ldl
noinst_PROGRAMS += unit/test-pbkdf2-sha1 unit/test-prf-sha1 unit/test-ippool
......@@ -249,9 +262,9 @@ unit_test_prf_sha1_SOURCES = unit/test-prf-sha1.c \
src/shared/sha1.h src/shared/sha1.c
unit_test_prf_sha1_LDADD = @GLIB_LIBS@
unit_test_ippool_SOURCES = $(gdbus_sources) src/log.c src/dbus.c \
src/ippool.c unit/test-ippool.c
unit_test_ippool_LDADD = @GLIB_LIBS@ @DBUS_LIBS@ -ldl
unit_test_ippool_SOURCES = src/log.c src/dbus.c src/ippool.c unit/test-ippool.c
unit_test_ippool_LDADD = gdbus/ \
TESTS = unit/test-pbkdf2-sha1 unit/test-prf-sha1 unit/test-ippool
......@@ -270,12 +283,13 @@ noinst_PROGRAMS += tools/supplicant-test \
tools/iptables-test tools/tap-test tools/wpad-test \
tools/stats-tool tools/private-network-test \
tools/session-test tools/iptables-unit \
tools/dnsproxy-test tools/netlink-test
tools_supplicant_test_SOURCES = $(gdbus_sources) tools/supplicant-test.c \
tools_supplicant_test_SOURCES = tools/supplicant-test.c \
tools/supplicant-dbus.h tools/supplicant-dbus.c \
tools/supplicant.h tools/supplicant.c
tools_supplicant_test_LDADD = @GLIB_LIBS@ @DBUS_LIBS@
tools_supplicant_test_LDADD = gdbus/ \
tools_web_test_SOURCES = $(gweb_sources) tools/web-test.c
tools_web_test_LDADD = @GLIB_LIBS@ @GNUTLS_LIBS@ -lresolv
......@@ -294,8 +308,8 @@ tools_dhcp_test_LDADD = @GLIB_LIBS@
tools_dhcp_server_test_SOURCES = $(gdhcp_sources) tools/dhcp-server-test.c
tools_dhcp_server_test_LDADD = @GLIB_LIBS@
tools_dbus_test_SOURCES = $(gdbus_sources) tools/dbus-test.c
tools_dbus_test_LDADD = @GLIB_LIBS@ @DBUS_LIBS@
tools_dbus_test_SOURCES = tools/dbus-test.c
tools_dbus_test_LDADD = gdbus/ @GLIB_LIBS@ @DBUS_LIBS@
tools_polkit_test_LDADD = @DBUS_LIBS@
......@@ -304,20 +318,25 @@ tools_iptables_test_LDADD = @GLIB_LIBS@ @XTABLES_LIBS@ -ldl
tools_private_network_test_LDADD = @GLIB_LIBS@ @DBUS_LIBS@
tools_session_test_SOURCES = $(gdbus_sources) src/log.c src/dbus.c \
tools_session_test_SOURCES = src/log.c src/dbus.c \
tools/session-test.c tools/session-utils.c tools/manager-api.c \
tools/session-api.c tools/session-test.h
tools_session_test_LDADD = @GLIB_LIBS@ @DBUS_LIBS@ -ldl
tools_session_test_LDADD = gdbus/ \
tools_iptables_unit_SOURCES = $(gdbus_sources) src/log.c \
tools_iptables_unit_SOURCES = src/log.c \
src/iptables.c src/firewall.c src/nat.c tools/iptables-unit.c
tools_iptables_unit_LDADD = @GLIB_LIBS@ @DBUS_LIBS@ @XTABLES_LIBS@ -ldl
tools_iptables_unit_LDADD = gdbus/ \
tools_dnsproxy_test_SOURCES = tools/dnsproxy-test.c
tools_dnsproxy_test_LDADD = @GLIB_LIBS@
tools_netlink_test_SOURCES =$(shared_sources) tools/netlink-test.c
tools_netlink_test_LDADD = @GLIB_LIBS@
test_scripts = test/get-state test/list-services \
......@@ -353,7 +372,8 @@ EXTRA_DIST += doc/overview-api.txt doc/behavior-api.txt \
doc/session-overview.txt doc/backtrace.txt \
doc/advanced-configuration.txt \
doc/vpn-connection-api.txt \
doc/vpn-manager-api.txt doc/vpn-overview.txt
doc/vpn-manager-api.txt doc/vpn-overview.txt \
EXTRA_DIST += src/main.conf
......@@ -365,8 +385,7 @@ pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = connman.pc
DISTCHECK_CONFIGURE_FLAGS = --disable-gtk-doc \
--disable-datafiles \
DISTCHECK_CONFIGURE_FLAGS = --disable-datafiles \
--enable-hh2serial-gps \
--enable-openconnect \
--enable-openvpn \
......@@ -246,6 +246,12 @@ Following environment variables can be used:
CONNMAN_WEB_DEBUG=1 src/connmand -n
If timing conditions are relevant then it is recommended command to
get log traces as follows:
connmand -d 2>&1 | ts '[%H:%M:%.S]' | tee connman.log
The 'ts' program is normaly avialable in the moreutils package.
Kernel configuration
......@@ -263,6 +269,22 @@ CONFIG_NETFILTER
For routing and statistic support in Sessions, the following options
need to be enabled as modules (m) or builtin (y):
In order to support USB gadget tethering, the following kernel configuration
options need to be enabled:
wpa_supplicant configuration
......@@ -290,6 +312,12 @@ disconnected.
It is recommended to use wpa_supplicant 1.x or later.
If wpa_supplicant is configured to D-Bus autostart, then ConnMan will
trigger the autostart of wpa_supplicant. However please keep in mind
that this trigger only happens once. If wpa_supplicant stops or crashes,
ConnMan does not periodically try to autostart it. It is up to systemd or
similar service management tool to autostart it.
......@@ -324,3 +352,5 @@ Mailing list:
For additional information about the project visit ConnMan web site:
You can report bugs at
......@@ -12,21 +12,6 @@ Background
- Session API implementation
Priority: High
Complexity: C4
Owner: Daniel Wagner <>
Owner: Patrik Flykt <>
The session API should provide a connection abstraction in order to
prioritize applications network accesses, prevent or allow network
and bearer roaming, or provide applications with a way to request
for periodic network connections. On-demand connections will be
implemented through this API as well.
- Personal firewall
Priority: Low
......@@ -55,36 +40,14 @@ Core
and get rid of the unnecessary ones.
- Support for multiple agents
Priority: Medium
Complexity: C2
Allow to register multiple agents. Each unique system bus name owner
however is only allowed to register one agent.
The selection of which agents is used should be matched by bus name
owner if possible or first come first serve. A graceful fallback to
the next agent should be also used in case of malfunctional agents.
- Remove --nobacktrace option
Priority: Medium
Complexity: C1
When: 2.0
Remove the --nobacktrace option or change it to --backtrace depending on the
level of systemd integration or other factors.
- Clean up type definitions
Priority: Medium
Complexity: C1
When: 2.0
Go through variable types and use the following:
* bool from <stdbool.h> instead of connman_bool_t and gboolean, in the
latter case in those places it makes sense
Remove the --nobacktrace option or change it to --backtrace depending on
the level of systemd integration or other factors.
- Clean up data structure usage
......@@ -92,8 +55,7 @@ Core
Priority: Medium
Complexity: C4
Use hash tables, queues and lists in the code. Replace GSequences with
simpler structures. At the same time do a check on the currently used
Use hash tables, queues and lists in the code. Check on the currently used
data structures and see if something can be simplified.
......@@ -107,11 +69,13 @@ Core
and oFono in general.
- DHCPv6 DECLINE message support
- Support other time sources than NTP
Priority: Medium
Complexity: C2
Support other time sources like cellular, GPS in addition to NTP.
......@@ -199,17 +163,25 @@ VPN
code and only allow "PPPD." prefix for PPP options.
- Update VPNC and OpenVPN with Agent support
Priority: Medium
Complexity: C2
Update VPNC and OpenVPN with VPN Agent support to request possible user
ids and passphrases.
- Add Session mode, VPN and Clock API support to connmanctl command line tool
- Add Clock API and MoveBefore/MoveAfter support to connmanctl
Priority: Low
Complexity: C2
The connmanctl command line tool should support Session mode and VPN
Agent with a set of suitable commands used in both interactive and
non-interactive mode. Also add support for Clock API.
The connmanctl command line tool should support Clock API and Service API
User Interface
......@@ -12,7 +12,7 @@ AC_DEFUN([AC_PROG_CC_PIE], [
if (test "${CFLAGS}" = ""); then
if (test "$USE_MAINTAINER_MODE" = "yes"); then
CFLAGS+=" -Werror -Wextra"
......@@ -25,37 +25,3 @@ AC_DEFUN([COMPILER_FLAGS], [