aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* hostapd: Add comment about '-i' parameter in hostapd.confTim Kourt2016-06-121-0/+2
| | | | Signed-off-by: Tim Kourt <tim.a.kourt@linux.intel.com>
* hostapd: Accept interface names as a command line parameterTim Kourt2016-06-121-4/+67
| | | | | | | | | | | This introduces an optinal command line parameter '-i' to override the value of the 'interface' attribute in hostapd.conf files. This change enables the reuse of the configuration files for the concurrent instances of hostapd. An ability to dynamically assign the interface names simplifies the usages of hostapd service in the automated emulations of the wireless environments. Signed-off-by: Tim Kourt <tim.a.kourt@linux.intel.com>
* hostapd: Fix early init failure pathJouni Malinen2016-06-122-4/+8
| | | | | | | eloop deinit calls could trigger segmentation fault if the early error path is hit before eloop_init() gets called. Signed-off-by: Jouni Malinen <j@w1.fi>
* FST: Make fst_global_deinit() more robustJouni Malinen2016-06-121-0/+6
| | | | | | | | Verify that fst_global_init() has been called before deinitializing the global FST context. This makes it a bit easier to handle failure paths from initialization. Signed-off-by: Jouni Malinen <j@w1.fi>
* tests: Add sniffer check to wpas_mesh_max_peeringJouni Malinen2016-06-121-1/+35
| | | | | | | This verifies that the Accepting Additional Mesh Peerings field is being cleared properly when the maximum peer links count is reached. Signed-off-by: Jouni Malinen <j@w1.fi>
* mesh: Sync max peer links with kernelMasashi Honma2016-06-121-2/+1
| | | | | | | | | Set max peer links to kernel even when wpa_supplicant MPM is used. This sets the correct value for the "Accepting Additional Mesh Peerings bit" in "Mesh Capability field" in "Mesh Configuration element" in the Beacon frame. Signed-off-by: Masashi Honma <masashi.honma@gmail.com>
* tests: Additional coverage in mesh_sae_groups_invalidJouni Malinen2016-06-121-0/+16
| | | | | | | Additional coverage in mesh_rsn_sae_group() with non-zero wpa_s->mesh_rsn->sae_group_index. Signed-off-by: Jouni Malinen <j@w1.fi>
* Update PKCS#11 references in template wpa_supplicant.confDavid Woodhouse2016-06-111-17/+15
| | | | | | | | Ditch the legacy syntax and manual engine mangling and just give an example using simple PKCS#11 URIs that'll work with both GnuTLS and OpenSSL. Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
* OpenSSL: Initialise PKCS#11 engine even if found with ENGINE_by_id()David Woodhouse2016-06-111-3/+9
| | | | | | | | | | | | | | Recent versions of engine_pkcs11 are set up to be autoloaded on demand with ENGINE_by_id() because they don't need explicit configuration. But if we *do* want to explicitly configure them with a PKCS#11 module path, we should still do so. We can't tell whether it was already initialised, but it's harmless to repeat the MODULE_PATH command if it was. Signed-off-by: David Woodhouse <David.Woodhouse@intel.com> Tested-by: Michael Schaller <misch@google.com>
* nl80211: Fix use-after-free in qca_nl80211_get_features()Paul Stewart2016-06-111-2/+7
| | | | | | | | Any data accessible from nla_data() is freed before the send_and_recv_msgs() function returns, therefore we need to allocate space for info.flags ourselves. Signed-off-by: Paul Stewart <pstew@google.com>
* tests: GAS/ANQP query and Address 3 value selectionJouni Malinen2016-06-101-0/+188
| | | | Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
* hostapd Make GAS Address3 field selection behavior configurableJouni Malinen2016-06-104-1/+16
| | | | | | | | | gas_address3=1 can now be used to force hostapd to use the IEEE 802.11 standards compliant Address 3 field value (Wildcard BSSID when not associated) even if the GAS request uses non-compliant address (AP BSSID). Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
* hostapd: Fix Public Action frame TX status processing for wildcard BSSIDJouni Malinen2016-06-101-1/+14
| | | | | | | | | | Previously all TX status events with wildcard BSSID were ignored. This did not allow Public Action frame TX status to be processed with the corrected wildcard BSSID use. Fix this to be allowed. In practice, this affects only test cases since Action frame TX status was not used for anything else. Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
* hostapd: Fix Public Action frame addressing (BSSID field)Jouni Malinen2016-06-103-13/+73
| | | | | | | | | | | | | | | | | | | | | | IEEE Std 802.11-2012, 10.19 (Public Action frame addressing) specifies that the wildcard BSSID value is used in Public Action frames that are transmitted to a STA that is not a member of the same BSS. hostapd used to use the actual BSSID value for all such frames regardless of whether the destination STA is a member of the BSS. Fix this by using the wildcard BSSID in cases the destination STA is not a member of the BSS. Leave group addressed case as-is (i.e., the actual BSSID), since both values are accepted. No such frames are currently used, though. This version is still using the AP BSSID value in the Address 3 field for GAS response frames when replying to a GAS request with AP BSSID instead of Wildcard BSSID. This is left as a workaround to avoid interoperability issues with deployed STA implementations that are still using the non-compliant address and that might be unable to process the standard compliant case. Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
* wpa_supplicant: Make GAS Address3 field selection behavior configurableJouni Malinen2016-06-105-1/+32
| | | | | | | | | | | | | | | | | | | | IEEE Std 802.11-2012, 10.19 (Public Action frame addressing) specifies that the wildcard BSSID value is used in Public Action frames that are transmitted to a STA that is not a member of the same BSS. wpa_supplicant used to use the actual BSSID value for all such frames regardless of whether the destination STA is a member of the BSS. P2P does not follow this rule, so P2P Public Action frame construction must not be changed. However, the cases using GAS/ANQP for non-P2P purposes should follow the standard requirements. Unfortunately, there are deployed AP implementations that do not reply to a GAS request sent using the wildcard BSSID value. The previously used behavior (Address3 = AP BSSID even when not associated) continues to be the default, but the IEEE 802.11 standard compliant addressing behavior can now be configured with gas_address3=1. Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
* tests: Mesh peering management protocol testingJouni Malinen2016-06-051-0/+86
| | | | Signed-off-by: Jouni Malinen <j@w1.fi>
* tests: Secure mesh network and PMKID mismatchJouni Malinen2016-06-051-0/+72
| | | | Signed-off-by: Jouni Malinen <j@w1.fi>
* tests: Secure mesh network and missing MICJouni Malinen2016-06-041-0/+46
| | | | Signed-off-by: Jouni Malinen <j@w1.fi>
* tests: Mesh and failure to derive random nonceJouni Malinen2016-06-041-0/+10
| | | | Signed-off-by: Jouni Malinen <j@w1.fi>
* tests: Secure mesh network and PMKSA caching failing due to OOMJouni Malinen2016-06-041-0/+43
| | | | Signed-off-by: Jouni Malinen <j@w1.fi>
* tests: Mesh scan element parse errorJouni Malinen2016-06-041-0/+17
| | | | Signed-off-by: Jouni Malinen <j@w1.fi>
* tests: Mesh network setup failing due to driver command failureJouni Malinen2016-06-041-0/+23
| | | | Signed-off-by: Jouni Malinen <j@w1.fi>
* nl80211: Add TEST_FAIL() to command generation and set_modeJouni Malinen2016-06-041-0/+5
| | | | | | | This makes it easier to test error paths for failing driver command cases. Signed-off-by: Jouni Malinen <j@w1.fi>
* mesh: Remove extra newline from the end of an error messageJouni Malinen2016-06-041-1/+1
| | | | Signed-off-by: Jouni Malinen <j@w1.fi>
* tests: Mesh and default beacon intervalJouni Malinen2016-06-041-0/+10
| | | | Signed-off-by: Jouni Malinen <j@w1.fi>
* tests: Extend coverage for mesh OOM testingJouni Malinen2016-06-041-8/+28
| | | | Signed-off-by: Jouni Malinen <j@w1.fi>
* tests: Open mesh network on VHT 160 MHz channelJouni Malinen2016-06-041-0/+50
| | | | Signed-off-by: Jouni Malinen <j@w1.fi>
* mesh: Allow 160 MHz channel to be configuredJouni Malinen2016-06-041-0/+10
| | | | | | | | This allows minimal testing with 160 MHz channel with country code ZA that happens to be the only one with a non-DFS 160 MHz frequency. DFS with mesh is not yet supported. Signed-off-by: Jouni Malinen <j@w1.fi>
* nl80211: Update drv->assoc_freq on mesh joinJouni Malinen2016-06-041-1/+1
| | | | | | This is needed to provide the correct frequency in SIGNAL_POLL command. Signed-off-by: Jouni Malinen <j@w1.fi>
* tests: Mesh and invalid frequency configurationJouni Malinen2016-06-041-1/+18
| | | | Signed-off-by: Jouni Malinen <j@w1.fi>
* mesh: Remove unreachable codeJouni Malinen2016-06-041-7/+1
| | | | | | | ssid->frequency cannot be 0 in wpa_supplicant_mesh_init() since wpas_supplicant_join_mesh() rejects such a configuration. Signed-off-by: Jouni Malinen <j@w1.fi>
* tests: Mesh and local failuresJouni Malinen2016-06-031-0/+43
| | | | Signed-off-by: Jouni Malinen <j@w1.fi>
* tests: Mesh and local SAE failuresJouni Malinen2016-06-031-0/+35
| | | | Signed-off-by: Jouni Malinen <j@w1.fi>
* tests: Mesh with invalid SAE group configurationJouni Malinen2016-06-031-0/+33
| | | | Signed-off-by: Jouni Malinen <j@w1.fi>
* nl80211: Use extended capabilities per interface typeKanchanapally, Vidyullatha2016-05-3112-1/+197
| | | | | | | | | | This adds the necessary changes to support extraction and use of the extended capabilities specified per interface type (a recent cfg80211/nl80211 extension). If that information is available, per-interface values will be used to override the global per-radio value. Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
* Sync with mac80211-next.git include/uapi/linux/nl80211.hJouni Malinen2016-05-311-1/+32
| | | | | | This brings in nl80211 definitions as of 2016-05-31. Signed-off-by: Jouni Malinen <j@w1.fi>
* Report connection timeouts in CTRL-EVENT-ASSOC-REJECTJouni Malinen2016-05-303-4/+16
| | | | | | | | | Add a new "timeout" argument to the event message if the nl80211 message indicates that the connection failure is not due to an explicit AP rejection message. This makes it easier for external programs to figure out why the connection failed. Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
* tests: wpa_supplicant secure MESH and SAE group negotiationJouni Malinen2016-05-301-0/+24
| | | | Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
* mesh: Support simple SAE group negotiation caseJouni Malinen2016-05-301-0/+51
| | | | | | | | | | This allows the simplest case of SAE group negotiation to occur by selecting the next available group if the peer STA indicates the previous one was not supported. This is not yet sufficient to cover all cases, e.g., when both STAs need to change their groups, but at least some cases are no covered. Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
* tests: Secure mesh network setup local failureJouni Malinen2016-05-301-1/+16
| | | | Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
* mesh: Fix error path handling for RSN (MGTK init)Jouni Malinen2016-05-301-3/+1
| | | | | | | | | wpa_deinit() got called twice if the random_get_bytes() fails to generate the MGTK. This resulted in double-freeing the rsn->auth pointer. Fix this by allowing mesh_rsn_auth_init() handle freeing for all error cases. Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
* tests: wpa_supplicant mesh scan results and OOMJouni Malinen2016-05-301-0/+25
| | | | Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
* tests: Support P2P group interfaces in hwsim remote testsJonathan Afek2016-05-301-4/+26
| | | | | | | | | Start using the wpa_supplicant remote UDP interface for the control and monitor sockets for P2P group interfaces so that P2P tests would work on real hardware. Also have the group requests and events show in the test log with the hostname and the interface name of the group interface. Signed-off-by: Jonathan Afek <jonathanx.afek@intel.com>
* D-Bus: Remove unused wpas_dbus_signal_p2p_group_started() parameterJouni Malinen2016-05-303-5/+1
| | | | | | The ssid pointer was not used. Signed-off-by: Jouni Malinen <j@w1.fi>
* D-Bus: Indicate whether created group is persistent or notNishant Chaprana2016-05-305-25/+20
| | | | | | | | | This adds an extra parameter in GroupStarted signal to indicate whether the created group is Persistent or not. It is similar to the [PERSISTENT] tag which comes in P2P-GROUP-STARTED over the control interface. Signed-off-by: Nishant Chaprana <n.chaprana@samsung.com>
* tests: wpa_supplicant mesh with dynamic interface addition failingJouni Malinen2016-05-291-0/+12
| | | | Signed-off-by: Jouni Malinen <j@w1.fi>
* mesh: Fix MESH_INTERFACE_ADD error path cleanupJouni Malinen2016-05-291-1/+1
| | | | | | | If wpa_supplicant_add_iface() fails, we need to remove the added netdev, not the existing wpa_s instance. Signed-off-by: Jouni Malinen <j@w1.fi>
* tests: Mesh network setup failing due to OOMJouni Malinen2016-05-291-3/+21
| | | | Signed-off-by: Jouni Malinen <j@w1.fi>
* mesh: Fix error path handling in init OOM casesJouni Malinen2016-05-291-4/+13
| | | | | | | | | hostapd deinit functions were not ready to handle a case where the data structures were not fully initialized. Make these more robust to allow wpa_supplicant mesh implementation to use the current deinit design in OOM error cases without causing NULL pointer dereferences. Signed-off-by: Jouni Malinen <j@w1.fi>
* tests: More coverage in ap_reassociation_to_same_bssJouni Malinen2016-05-281-0/+6
| | | | | | | The extra wait forces the special reattach-scan case to be reached in wpa_supplicant_scan(). Signed-off-by: Jouni Malinen <j@w1.fi>