summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2021-09-14Add support of bpfsubmit/tizen/20210915.152151submit/tizen/20210915.122117accepted/tizen/unified/20210916.005908Jaehyun Kim11-4/+6899
Change-Id: Iaa5566a1be143ede38832cdd8639111fc26b4586 Signed-off-by: Jaehyun Kim <jeik01.kim@samsung.com>
2021-09-09Enable Downgrade dbus method.Niraj Kumar Goit1-2/+3
When offline is detected in device, downgrade service state to ready and start online check in connman. Change-Id: Ic5abf9050c51b853ee36fa8067b221c3e9c63eec Signed-off-by: Niraj Kumar Goit <niraj.g@samsung.com>
2021-09-08Fix resource leaksubmit/tizen/20210909.045500submit/tizen/20210908.150016accepted/tizen/unified/20210915.025055Jaehyun Kim1-0/+2
Change-Id: Ic3c9199d0dac7e614743043cdeb5ad1616eb1aa1 Signed-off-by: Jaehyun Kim <jeik01.kim@samsung.com>
2021-09-08Merge "Fix build failure when tizen-maintain-online feature is enabled" into ↵Jaehyun Kim1-13/+6
tizen
2021-09-08Fix Crash in connman-vpnd in reboot scenario when config file is presentNiraj Kumar Goit1-0/+4
Change-Id: I3cfccf9f53bfbd92974e1dbba65a6952f21f6c19 Signed-off-by: Niraj Kumar Goit <niraj.g@samsung.com>
2021-09-08Merge "wireguard: Add routes for allowedIPs" into tizenJaehyun Kim1-0/+205
2021-09-08Merge "wireguard: Save plugin related settings in config file" into tizenJaehyun Kim1-0/+104
2021-09-08Merge "vpn: Make domain parameter optional" into tizenJaehyun Kim3-9/+13
2021-09-08Merge "Enable Wireguard VPN Plugin" into tizenJaehyun Kim1-1/+1
2021-09-08Merge "wireguard: Copy interfance names obeying lengths rules" into tizenJaehyun Kim1-1/+1
2021-09-08Merge "vpn: Export vpn_ipconfig_foreach as linker symbol" into tizenJaehyun Kim4-4/+4
2021-09-08Merge "wireguard: Fix struct sockaddr usage" into tizenJaehyun Kim1-22/+25
2021-09-08Merge "wireguard: Regular reresolve endpoint address" into tizenJaehyun Kim1-7/+80
2021-09-08wireguard: Add routes for allowedIPsNishant Chaprana1-0/+205
Change-Id: Iad4c994dc7e40589f17db7c1b590cf7673b21bc0 Signed-off-by: Nishant Chaprana <n.chaprana@samsung.com>
2021-09-06Fix build failure when tizen-maintain-online feature is enabledNishant Chaprana1-13/+6
Below are the build fail logs when tizen-maintain-online feature is enabled in spec file. ====================================================================================== [ 37s] src/service.c: At top level: [ 37s] src/service.c:9432:17: error: redefinition of 'redo_wispr_ipv4' [ 37s] 9432 | static gboolean redo_wispr_ipv4(gpointer user_data) [ 37s] | ^~~~~~~~~~~~~~~ [ 37s] src/service.c:9413:17: note: previous definition of 'redo_wispr_ipv4' was here [ 37s] 9413 | static gboolean redo_wispr_ipv4(gpointer user_data) [ 37s] | ^~~~~~~~~~~~~~~ [ 37s] src/service.c: In function 'service_connect': ===================================================================================== Change-Id: I1516358e55bba73af6383a8f7c8cc29c74f736fc Signed-off-by: Nishant Chaprana <n.chaprana@samsung.com>
2021-09-02Fix referencing incorrect bssid_listJaehyun Kim1-1/+2
Change-Id: Ie8cc971deb699250f9d6fbbbb1d37ed4ecf3fbf1 Signed-off-by: Jaehyun Kim <jeik01.kim@samsung.com>
2021-09-02Fix NULL pointer dereferenceJaehyun Kim1-1/+2
Thread 1 (LWP 13957): >0 count_assoc_reject (key=0x0, value=0x0, user_data=0xbe0a3928) at src/service.c:843 --> connman (rpm) >1 0xb6654674 in g_hash_table_foreach (hash_table=0x533200, func=0x4700ad <count_assoc_reject>, user_data=user_data@entry=0xbe0a3928) at ../glib/ghash.c:2056 --> libglib (rpm) >2 0x0047bf9a in update_assoc_reject (service=0x4fb2a0, service=0x4fb2a0) at src/service.c:857 --> connman (rpm) >3 __connman_service_update_from_network (network=network@entry=0x50d6a0) at src/service.c:11004 --> connman (rpm) >4 0x0046a9f4 in connman_network_set_group (network=network@entry=0x50d6a0, group=group@entry=0x560ff8 "") at src/network.c:1587 --> connman (rpm) >5 0x0044f12c in network_added (supplicant_network=0x51d430) at plugins/wifi.c:5031 --> connman (rpm) >6 0x004516ba in callback_network_added (network=<optimized out>) at gsupplicant/supplicant.c:828 --> connman (rpm) >7 scan_network_update (iter=<optimized out>, user_data=0x4f0380) at gsupplicant/supplicant.c:3790 --> connman (rpm) Change-Id: I2f6e86c492dbc621b1c9f48506e8a89326568664 Signed-off-by: Jaehyun Kim <jeik01.kim@samsung.com>
2021-08-18Use SNR and estimated throughput for BSS scoringJaehyun Kim1-5/+40
Change-Id: Ie80ad47361166cd3b22a430111dda5c91791dca2 Signed-off-by: Jaehyun Kim <jeik01.kim@samsung.com>
2021-08-04wireguard: Save plugin related settings in config fileNishant Chaprana1-0/+104
Change-Id: I76d12fa347d1211958463ccf38a043a0c6272ece Signed-off-by: Nishant Chaprana <n.chaprana@samsung.com>
2021-07-19Added a dbus property 'TimeUpdated'submit/tizen/20210723.060030accepted/tizen/unified/20210726.135508Jaehyun Kim3-0/+24
A property has been added to indicate whether the time has been updated by NTP. Change-Id: I86b8a0c2df377168f98656618efd82bb7da91800 Signed-off-by: Jaehyun Kim <jeik01.kim@samsung.com>
2021-07-15vpn: Make domain parameter optionalNishant Chaprana3-9/+13
There is no technical requirement to provide the domain name. Thus, make the domain paremeter optional. Reported by Christian Hewitt Upstream Patch: https://git.kernel.org/pub/scm/network/connman/connman.git/patch/?id=82699007fa89e26206771047d8cbb7c160fd2990 Change-Id: Iac21532e3e310d67c633874a95566413beb4b3a4 Signed-off-by: Nishant Chaprana <n.chaprana@samsung.com>
2021-07-13Enable Wireguard VPN PluginNishant Chaprana1-1/+1
Change-Id: Ic1edd8f5ea13e965ecd57499b51b8652604f5f71 Signed-off-by: Nishant Chaprana <n.chaprana@samsung.com>
2021-07-13wireguard: Copy interfance names obeying lengths rulesDaniel Wagner1-1/+1
gcc points out the destination buffer has the same size the specified bound for the string. warning: ‘__builtin_strncpy’ specified bound 16 equals destination size [-Wstringop-truncation] Let's make sure we do not overflow the buffer (should not happen as the names are provide by the kernel and hence should fit). Change-Id: I1e8818f0820ffb32083e14cb88e4919fd8b12798 Signed-off-by: Nishant Chaprana <n.chaprana@samsung.com>
2021-07-13vpn: Export vpn_ipconfig_foreach as linker symbolDaniel Wagner4-4/+4
Commit 95b25140bec7 ("vpn: Add WireGuard support") introduced a plugin dependency to __vpn_ipconfig_foreach. Because the linker does not export the prefixed functions, we need to rename it to vpn_ipconfig_foreach in order to export the linker symbol. Change-Id: I105159739dece4a675fa074ef304c6fd4d7b88bf Signed-off-by: Nishant Chaprana <n.chaprana@samsung.com>
2021-07-13wireguard: Fix struct sockaddr usageDaniel Wagner1-22/+25
wg_dns_reresolve_cb() tries to read 16 bytes from the addr variable in case of IPv6 but struct sockaddr has size of 8 bytes. Introduce a helper struct containing IPv4 and IPv6 sockaddr as superset of all IP based sockaddr. This helper struct is identically to the 'union endpoint' in wireguard.h. But we don't want to touch this header file as it is 100% copy from the upstream WireGuard project. Fixes: 90592f7a5835 ("wireguard: Regular reresolve endpoint address") Change-Id: I2b262e61e52c795ab0cab4b206bd25df8ae57738 Signed-off-by: Nishant Chaprana <n.chaprana@samsung.com>
2021-07-13wireguard: Regular reresolve endpoint addressDaniel Wagner1-7/+80
In case the WireGuard endpoint is hosted on a dynamic IP address, the endpoint might change during runtime. Reresolve the endpoint on a regular basis and update the WireGuard device when it IP address has changed. Reported by Christian Hewitt Change-Id: Ice3b554a064585fb03ae8a7a89baccbe53e8576b Signed-off-by: Nishant Chaprana <n.chaprana@samsung.com>
2021-07-05Use the last updated MAC address before turning on wifisubmit/tizen/20210706.115004accepted/tizen/unified/20210708.131505Jaehyun Kim3-26/+5
MAC randomization does not work properly when there are multiple wifi interfaces or in some devices that do not create a .mac.info file. So, to solve this problem, a permanent MAC address that is set before wifi up is used. If a permanent MAC address is in built-in physical device, it's hardly get it at an initial creation. So, if there is a MAC address updated from netlink before wifi is on, it is used. * MAC randomization works only when wifi is turned on. Change-Id: Ia7a9ad0affaa6deca974199100a56e7378b6c195 Signed-off-by: Jaehyun Kim <jeik01.kim@samsung.com>
2021-06-10Fix memory leaks and dereference without null checksubmit/tizen/20210615.081101accepted/tizen/unified/20210616.132525Jaehyun Kim4-0/+18
Change-Id: I7accd1386302c26e5bdfa8aee224fe60defc50af Signed-off-by: Jaehyun Kim <jeik01.kim@samsung.com>
2021-06-10Check the reply of SignalPoll method correctlyJaehyun Kim2-2/+7
Change-Id: Id48cb699743e62484fac775c7348c34f1e80ac8f Signed-off-by: Jaehyun Kim <jeik01.kim@samsung.com>
2021-05-28Added dbus method 'GetConnectedService'submit/tizen/20210528.085525accepted/tizen/unified/20210601.135338Jaehyun Kim4-3/+49
CAPI is fetching the full list of services and looking for the service that is connected, but this is an inefficient way, so a dbus method to provide that information is added in connman. Change-Id: I825682b3a1c01de3926145df499321ef161c4af7 Signed-off-by: Jaehyun Kim <jeik01.kim@samsung.com>
2021-05-18Remove wrong rules from connman dbus confNishant Chaprana1-3/+0
MacPolicy, PreassocMacPolicy and RandomMacLifetime are properties of technology interface and method rules cannot be applied for them. Change-Id: I5dd381d1fac44f23f62f5cf1a1b9cccf859ffec8 Signed-off-by: Nishant Chaprana <n.chaprana@samsung.com>
2021-05-18Add TIZEN_EXT macro to Tizen specific codeNishant Chaprana1-1/+2
Change-Id: I322c8866eee025d868593a5110186fe581b3d939 Signed-off-by: Nishant Chaprana <n.chaprana@samsung.com>
2021-05-18Added support to get country-code.Niraj Kumar Goit1-0/+4
Change-Id: I880450f406c48490f5952452f0e586ca4d0d3c9e Signed-off-by: Niraj Kumar Goit <niraj.g@samsung.com>
2021-05-12Added support to set country-code.Niraj Kumar Goit1-0/+7
Change-Id: I6919f3ca4a794eeee7d75a3824c0fc3a22031d06 Signed-off-by: Niraj Kumar Goit <niraj.g@samsung.com>
2021-05-07Modified to handle WPA3/WPA2 mixed mode as WPA3-SAEsubmit/tizen/20210513.084419submit/tizen/20210512.013459Jaehyun Kim1-2/+4
Change-Id: Ib9d5240a4673f08f65dd13db3eb59bbb1b4da80d Signed-off-by: Jaehyun Kim <jeik01.kim@samsung.com>
2021-04-29Send Mac policy parameters in CreateInterface dbus call.submit/tizen/20210503.112345accepted/tizen/unified/20210506.103545Nishant Chaprana6-20/+36
This patch will send mac policy parameters in CreateInteraface dbus call and will make 3 dbus calls to set mac policy parameters when interface is already created in wpa_supplicant. Change-Id: Icd7ce43d1b67fe5211ab15d2ab20fd47038907f1 Signed-off-by: Nishant Chaprana <n.chaprana@samsung.com>
2021-04-27Fix Wi-Fi activation issue in TM1submit/tizen/20210427.065300Nishant Chaprana1-2/+2
Increased timeout to 10 seconds in case of device activation This is required because the Mac Randomizaiton parameters need to be set by dbus calls, to retains previous boot settings. The timeout value is already less because wifi_manager_activate() API has 120 seconds timeout to turn on the device, however current timeout emits failure callback post 4 seconds, when -EINPROGRESS is returned from device plugin. Change-Id: I92041dbd9898f1f6b0a59f895bcd06fb5f6e1e91 Signed-off-by: Nishant Chaprana <n.chaprana@samsung.com>
2021-04-21Fix autoconnect issue at reboot in TW3submit/tizen/20210421.161229Nishant Chaprana4-3/+107
Change-Id: I7104f40a29f5e45cd2b6ba0391f36d7c37bfa0a2 Signed-off-by: Nishant Chaprana <n.chaprana@samsung.com>
2021-04-21Add setter/getter for handling MAC randomization policyNishant Chaprana8-1/+726
Change-Id: I978ab95f02d04574efc7c3455b71f72841956c36 Signed-off-by: Nishant Chaprana <n.chaprana@samsung.com>
2021-03-31Fix NULL pointer dereferenceNishant Chaprana1-0/+3
Core was generated by `/usr/bin/connmand -n --nobacktrace --noplugin vpn'. Program terminated with signal SIGSEGV, Segmentation fault. >0 connman_device_get_last_connected_ident (device=0x0) at src/device.c:842 842 return device->last_connected_ident; (gdb) bt >0 connman_device_get_last_connected_ident (device=0x0) at src/device.c:842 >1 0x0098ec70 in calculate_score_last_connected (service=0x1ef9eb8) at src/service.c:7900 >2 calculate_score (service=0x1ef9eb8) at src/service.c:7994 >3 calculate_score (service=0x1ef9eb8) at src/service.c:7977 >4 0x0098eed8 in service_compare (a=0x1ef9eb8, b=0x1f010a0) at src/service.c:8138 Change-Id: I7e412f68f71472e28669941b9346ba73281ccd39 Signed-off-by: Nishant Chaprana <n.chaprana@samsung.com>
2021-03-31Use dbus_free for deallocation, when allocated with dbus_malloc0Nishant Chaprana1-1/+1
Change-Id: I003118f70353bf949f050a6e863c9152be8b6e8e Signed-off-by: Nishant Chaprana <n.chaprana@samsung.com>
2021-02-24Merge "Error checking in passphrase decryption method." into tizensubmit/tizen/20210224.083420accepted/tizen/unified/20210225.130544Jaehyun Kim2-1/+9
2021-02-24Merge "Fix svace 'UNREACHABLE_CODE.NO_PATH' warnings" into tizenJaehyun Kim2-2/+4
2021-02-10Fix svace 'UNREACHABLE_CODE.NO_PATH' warningsNishant Chaprana2-2/+4
Change-Id: Ibefe7a09903f2d05e7aa12e9262f820d4e7feb71 Signed-off-by: Nishant Chaprana <n.chaprana@samsung.com>
2021-02-03Change systemd-devel package namesubmit/tizen/20210217.025918accepted/tizen/unified/20210217.120449INSUN PYO2-3/+3
Change-Id: I0c553dd40bda63b08846e66bbcdd9955d882ef41
2021-01-27Error checking in passphrase decryption method.Niraj Kumar Goit2-1/+9
If Dbus fails to append argument in dbus-message, do not call a dbus method to decrypt passphrase. Change-Id: Ic3b63ea9e6827ca1bf3753d750026119ec1bfd1a Signed-off-by: Niraj Kumar Goit <niraj.g@samsung.com>
2021-01-27merge tag upstream/1.38submit/tizen/20210127.105449accepted/tizen/unified/20210129.002142Seonah Moon0-0/+0
Change-Id: Ic98cd483e7e21143bb1102a781643c06ce9f628d
2021-01-25On device reboot enable wpa-supplicant for EAPoL.submit/tizen/20210126.062930Niraj Kumar Goit4-36/+155
In case of device reboot enable wpa-supplicant for eapol connection if last connection was EAP over ethernet. Change-Id: Ia264accac74ecffdba6c2b116807e45f675ef3db Signed-off-by: Niraj Kumar Goit <niraj.g@samsung.com>
2021-01-25Added Dbus method 'IsEapolEnabled'.Niraj Kumar Goit2-1/+24
This patch fixes EAPoL enabled status on device reboot scenario. Change-Id: Ib9fcbed659996eae42c6a30e7ee5f584aeaa19d2 Signed-off-by: Niraj Kumar Goit <niraj.g@samsung.com>
2021-01-25Merge "Imported Upstream connman version 1.38" into tizenJaehyun Kim140-2127/+8086