3
0
mirror of https://git.kernel.org/pub/scm/network/wireless/iwd.git synced 2024-12-23 06:02:37 +01:00
iwd/src
Antonio Quartulli 8106d82b4e fast_transition: fix crash by parsing RSN IE only if present
When performing a fast transition to another OPEN network the RSN
element won't be there and therefore the bss->rsne is gonna be NULL.

Fix crash by not accessing the rsne member when performing a fast
transition to an AP that doe snot advertise any RSN IE.

Crash caught with gdb:

 src/station.c:station_transition_start() 186, target 34:8f:27:2f:b8:fc

 Program received signal SIGSEGV, Segmentation fault.
 handshake_state_set_authenticator_ie (s=0x555555626eb0, ie=0x0) at src/handshake.c:163
 163		s->authenticator_ie = l_memdup(ie, ie[1] + 2u);
 (gdb) bt
 #0  handshake_state_set_authenticator_ie (s=0x555555626eb0, ie=0x0) at src/handshake.c:163
 #1  0x0000555555561a98 in fast_transition (netdev=0x55555562fbe0, target_bss=0x55555561f4a0,
     over_air=over_air@entry=true, cb=0x55555556d5b0 <station_fast_transition_cb>) at src/netdev.c:3164
 #2  0x0000555555565dfd in netdev_fast_transition (netdev=<optimized out>, target_bss=<optimized out>,
     cb=<optimized out>) at src/netdev.c:3232
 #3  0x000055555556ccbd in station_transition_start (bss=0x55555561f4a0, station=0x555555617da0)
     at src/station.c:1261
 #4  station_roam_scan_notify (err=<optimized out>, bss_list=<optimized out>, userdata=0x555555617da0)
     at src/station.c:1444
 #5  0x0000555555579560 in scan_finished (sc=0x55555562bf80, err=err@entry=0, bss_list=0x55555561bd90,
     sr=0x555555626b30, wiphy=<optimized out>) at src/scan.c:1234
 #6  0x0000555555579620 in get_scan_done (user=0x555555618920) at src/scan.c:1264
 #7  0x00005555555abd23 in destroy_request (data=0x55555561b000) at ell/genl.c:673
 #8  0x00005555555ac129 in process_unicast (nlmsg=0x7fffffffc310, genl=0x55555560b7a0) at ell/genl.c:940
 #9  received_data (io=<optimized out>, user_data=0x55555560b7a0) at ell/genl.c:1039
 #10 0x00005555555a8aa3 in io_callback (fd=<optimized out>, events=1, user_data=0x55555560b840)
     at ell/io.c:126
 #11 0x00005555555a7ccd in l_main_iterate (timeout=<optimized out>) at ell/main.c:473
 #12 0x00005555555a7d9c in l_main_run () at ell/main.c:520
 #13 l_main_run () at ell/main.c:502
 #14 0x00005555555a7fac in l_main_run_with_signal (callback=<optimized out>, user_data=0x0)
    at ell/main.c:642
 #15 0x000055555555e5b8 in main (argc=<optimized out>, argv=<optimized out>) at src/main.c:519
2019-08-28 14:35:06 -05:00
..
adhoc.c eapol: Remove eapol_sm_set_protocol_version 2019-07-15 21:45:58 -05:00
agent.c agent: Add new request types 2018-04-19 11:49:41 -05:00
agent.h agent: Add new request types 2018-04-19 11:49:41 -05:00
anqp.c anqp: move ANQP parsers into anqputil 2019-07-15 14:53:44 -05:00
anqp.h anqp: move ANQP parsers into anqputil 2019-07-15 14:53:44 -05:00
anqputil.c anqp: move ANQP parsers into anqputil 2019-07-15 14:53:44 -05:00
anqputil.h anqp: move ANQP parsers into anqputil 2019-07-15 14:53:44 -05:00
ap.c eapol: Remove eapol_sm_set_protocol_version 2019-07-15 21:45:58 -05:00
auth-proto.h auth-proto: introduce auth-proto concept 2019-05-03 13:53:50 -05:00
backtrace.c build: only enable backtrace(3) in maintainer mode 2018-11-26 14:32:04 -06:00
backtrace.h build: only enable backtrace(3) in maintainer mode 2018-11-26 14:32:04 -06:00
blacklist.c blacklist: Convert to use IWD_MODULE 2019-05-22 09:58:04 -05:00
blacklist.h blacklist: Convert to use IWD_MODULE 2019-05-22 09:58:04 -05:00
common.c ie: add IE_RSN_AKM_SUITE_OSEN 2019-06-07 16:15:07 -05:00
common.h scan: Move scan_get_security to common.c 2018-05-24 19:22:16 -05:00
crypto.c crypto: update FT derivation functions to use sha384 2019-05-22 16:14:14 -05:00
crypto.h crypto: add OSEN AKM 2019-06-07 14:22:33 -05:00
dbus.c dbus: Add p2p iftypes in dbus_iftype_to_string 2019-04-11 11:01:09 -05:00
dbus.h main: Don't init nl80211 until dbus name is owned 2018-09-11 20:06:00 -05:00
device.c scan: Switch all uses of ifindex to wdev_id 2019-07-08 11:53:00 -05:00
device.h station: Move remaining connect/re-connect/roam logic 2018-09-04 23:57:14 -05:00
eap-aka.c eap-aka: derive Session-ID for ERP 2019-04-22 16:31:14 -05:00
eap-gtc.c build: Add support for including fallbacks for missing defines 2019-04-03 18:34:22 +02:00
eap-md5.c build: Add support for including fallbacks for missing defines 2019-04-03 18:34:22 +02:00
eap-mschapv2.c eap: export session ID as key materials 2019-04-10 16:55:29 -05:00
eap-mschapv2.h eap-mschapv2: Drop mschapv2_nt_password_hash, use mschap_nt_password_hash 2019-03-19 11:34:23 -05:00
eap-peap.c eap: export session ID as key materials 2019-04-10 16:55:29 -05:00
eap-private.h eap: export session ID as key materials 2019-04-10 16:55:29 -05:00
eap-pwd.c eap-pwd: check if server point/scalar is valid 2019-04-11 10:19:38 -05:00
eap-sim.c eap-sim: derive session-ID for ERP 2019-04-22 16:31:19 -05:00
eap-tls-common.c eap-tls: Add ServerDomainMask config option 2019-08-23 09:30:24 -05:00
eap-tls-common.h eap-tls-common: Make databuf private 2018-12-11 17:09:51 -06:00
eap-tls.c eap-tls: add new EAP method for Anonymous TLS 2019-06-06 13:29:11 -05:00
eap-ttls.c eap: export session ID as key materials 2019-04-10 16:55:29 -05:00
eap-wsc.c eap-wsc: fix valgrind warning 2019-08-27 20:58:01 -05:00
eap-wsc.h eap-wsc: Send credential obtained events 2016-09-13 13:32:47 -05:00
eap.c eap: Make global variable static 2019-08-15 19:39:27 +02:00
eap.h eap: add eap_get_identity 2019-04-10 16:57:07 -05:00
eapol.c eapol: Propagate noencrypt and use it 2019-08-27 20:50:07 -05:00
eapol.h eapol: Propagate noencrypt and use it 2019-08-27 20:50:07 -05:00
eapolutil.c eapol: allow 16, 24 and 32 byte MIC lengths 2019-01-17 15:20:28 -06:00
eapolutil.h eapolutil: Add 2010 EAP protocol version 2019-07-15 21:24:05 -05:00
erp.c erp: Convert to using IWD_MODULE 2019-05-19 13:07:13 -05:00
erp.h erp: Convert to using IWD_MODULE 2019-05-19 13:07:13 -05:00
fils.c fils: Fix endianness issues 2019-05-23 16:59:14 -05:00
fils.h fils: netdev: update to use auth_proto concepts 2019-05-03 14:37:11 -05:00
ft.c ft: Fix endianness issues 2019-05-23 16:59:34 -05:00
ft.h ft: netdev: station: support FT-over-DS 2019-05-09 13:38:34 -05:00
genbuiltin make: plugin system for build 2017-11-28 13:20:33 -06:00
handshake.c handshake: Add handshake_state_set_protocol_version 2019-07-15 21:45:12 -05:00
handshake.h handshake: Add handshake_state_set_protocol_version 2019-07-15 21:45:12 -05:00
hotspot.c hotspot: use known_network_update 2019-08-28 11:41:16 -05:00
hotspot.h network: remove hotspot specific settings loading 2019-08-19 13:58:27 -05:00
ie.c ie: add parser/builder for hotspot indication element 2019-07-24 00:13:27 -05:00
ie.h ie: add parser/builder for hotspot indication element 2019-07-24 00:13:27 -05:00
iwd-dbus.conf tools: Add configure option and D-Bus policy file for hwsim utility 2018-09-14 15:24:15 +02:00
iwd.h module: Introduce a basic module dependency framework 2019-08-07 16:33:19 -05:00
iwd.service.in build: Fix issue with incorrect ReadWritePaths in unit files 2019-08-03 09:52:28 +02:00
knownnetworks.c knownnetworks: refactor to expose known_network_update 2019-08-28 11:40:14 -05:00
knownnetworks.h knownnetworks: refactor to expose known_network_update 2019-08-28 11:40:14 -05:00
main.c module: Introduce a basic module dependency framework 2019-08-07 16:33:19 -05:00
manager.c manager: Fix build 2019-08-21 12:29:22 -05:00
missing.h build: Add support for including fallbacks for missing defines 2019-04-03 18:34:22 +02:00
module.c treewide: Make global variables static 2019-08-15 15:06:59 -05:00
mpdu.c mpdu: Validate action frame minimum length 2019-07-08 13:42:22 -05:00
mpdu.h mpdu: add auth algorithms for FILS 2019-04-05 12:07:37 -05:00
mschaputil.c Revert "mschaputil: use util_get_username" 2019-04-18 10:46:56 -05:00
mschaputil.h mschaputil: Move generator of the hash of the pwd hash 2019-01-10 17:09:10 -06:00
net.connman.iwd.service net.connman.iwd.service: Change SystemdService name to iwd.service 2018-08-09 10:45:16 -05:00
netconfig.c netconfig: Uninstall addresses on interface removal 2019-08-19 13:23:44 -05:00
netconfig.h netconfig: Introduce netconfig module 2019-06-26 10:25:57 -05:00
netdev.c fast_transition: fix crash by parsing RSN IE only if present 2019-08-28 14:35:06 -05:00
netdev.h netdev: Allow to send extra vendor IEs when connecting 2019-07-12 16:13:01 -05:00
network.c network: fix issue with WSC not connecting 2019-08-28 13:06:40 -05:00
network.h network: remove all hotspot related getter/setters 2019-08-19 13:59:01 -05:00
nl80211cmd.c nl80211cmd: Add additional commands 2019-08-15 15:06:59 -05:00
nl80211cmd.h nl80211cmd: Introduce new utility 2019-07-15 14:06:26 -05:00
nl80211util.c nl80211util: move CMD_FRAME builder into nl80211util 2019-06-26 22:52:56 -05:00
nl80211util.h nl80211util: move CMD_FRAME builder into nl80211util 2019-06-26 22:52:56 -05:00
owe.c owe: Fix endianness issues 2019-05-23 16:58:59 -05:00
owe.h owe: netdev: update to use auth_proto concepts 2019-05-03 14:37:11 -05:00
p2putil.c p2putil: Builders for P2P action frames 2019-07-08 22:08:36 -05:00
p2putil.h p2putil: Builders for P2P action frames 2019-07-08 22:08:36 -05:00
pkcs8.conf build: Provide modules-load.d for loading pkcs8_key_parser module 2019-01-23 18:22:11 +01:00
plugin.c build: Add missing HAVE_CONFIG_H guards and include config.h 2019-04-04 14:02:38 +02:00
plugin.h plugins: module to load ell plugins 2017-11-28 13:30:06 -06:00
resolve.c resolve: Add a missing l_free 2019-08-07 11:13:10 -05:00
resolve.h resolve: Introduce resolve module 2019-07-02 19:09:57 -05:00
rfkill.c treewide: Use L_TFR macro 2019-05-24 11:52:40 -05:00
rfkill.h Add rfkill enable/disable and watch support 2016-07-07 13:21:08 -05:00
rtnlutil.c rtnlutil: fix compiler error 2019-07-31 12:39:41 -05:00
rtnlutil.h rtnlutil: Add connected and gateway route API 2019-07-31 03:49:35 -05:00
sae.c sae: check minimum anti-clogging token size 2019-07-18 23:34:03 -05:00
sae.h sae: netdev: update to use auth_proto concepts 2019-05-03 14:42:38 -05:00
scan.c scan: only set Interworking if capable 2019-08-21 17:34:43 -05:00
scan.h scan: station: parse HS20 version in scan results 2019-07-24 00:22:46 -05:00
simauth.c simauth: Convert to use IWD_MODULE 2019-05-22 10:20:08 -05:00
simauth.h main: Simplify sim_auth_init 2018-07-17 19:12:48 -05:00
simutil.c build: Add missing HAVE_CONFIG_H guards and include config.h 2019-04-04 14:02:38 +02:00
simutil.h eap: Separate private bits into eap-private.h 2018-06-14 20:01:19 -05:00
station.c station: allow autoconnect to hotspot networks 2019-08-28 11:27:09 -05:00
station.h station: introduce station_network_foreach 2019-08-19 12:40:18 -05:00
storage.c storage: util: remove unused APIs 2019-08-21 14:16:08 -05:00
storage.h storage: util: remove unused APIs 2019-08-21 14:16:08 -05:00
util.c storage: util: remove unused APIs 2019-08-21 14:16:08 -05:00
util.h util: add util_set_bit 2019-08-21 17:24:16 -05:00
watchlist.c watchlist: Use full include path local includes 2018-10-26 21:33:01 +02:00
watchlist.h watchlist: fix stale watchlist item processing 2018-09-19 14:17:26 -05:00
wiphy.c wiphy: Setup RM Enabled Capabilities in wiphy 2019-08-23 08:55:54 -05:00
wiphy.h wiphy: Setup RM Enabled Capabilities in wiphy 2019-08-23 08:55:54 -05:00
wsc.c wsc: fix station lookup by ifindex 2019-08-02 02:23:05 -05:00
wscutil.c wscutil: Add wsc_build_p2p_attrs 2019-07-08 13:46:53 -05:00
wscutil.h wscutil: Add wsc_build_p2p_attrs 2019-07-08 13:46:53 -05:00