Commit message (Collapse)AuthorAgeFilesLines
* NFC: Add no waiting and no multiple operations options for scriptsJouni Malinen2013-04-271-16/+47
| | | | | | | | The nfcpy script used to be run in a way that left them running for multiple operations. This is not desired for some use cases, so provide options to request only a single operation to be performed. Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
* tests: Add a test case for AP auto configuration on config token buildJouni Malinen2013-04-271-0/+20
| | | | Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
* WPS: Fix AP auto configuration on config token generationJouni Malinen2013-04-271-0/+26
| | | | Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
* NFC: Increase wpa_cli command buffer sizeJouni Malinen2013-04-271-1/+1
| | | | | | | NFC connection handover messages may be longer than 100 octets, so increase wpa_cli buffer size to allow longer messages to be reported. Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
* WPS NFC: Allow Device Password ID override for selected registrarJouni Malinen2013-04-273-14/+20
| | | | | | | When a specific out-of-band Device Password is enabled, it can be useful to be able to advertise that in the selected registrar information. Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
* WPS: Use generic MAC Address attribute builderJouni Malinen2013-04-274-24/+14
| | | | Signed-hostap: Jouni Malinen <j@w1.fi>
* tests: Use ignore_old_scan_res with some more WPS testsJouni Malinen2013-04-271-0/+2
| | | | | | | | The scan results from old test cases showing different SSID on the AP can result in false failures, so avoid those by ignoring old scan results from cfg80211. Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
* P2P: Clean up channel--frequency conversion functionsJouni Malinen2013-04-277-108/+50
| | | | | | | | | All P2P use cases are required to use the global operating table and there is no need to need to try to maintain some backwards compatibility with country code -specific values. Clean up the implementation by removing the unnecessary country parameter. Signed-hostap: Jouni Malinen <j@w1.fi>
* Use a common frequency to channel conversion functionJouni Malinen2013-04-275-76/+42
| | | | Signed-hostap: Jouni Malinen <j@w1.fi>
* FT: Reset FT flag upon STA deauthenticationDeepthi Gowri2013-04-263-0/+13
| | | | | | | | Reset ft_completed if STA receives deauthentication between FT reassoc success and the subsequent initial mobility authentication and association. Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
* tests: Generate a tarball of test results if a test failsJouni Malinen2013-04-262-1/+12
| | | | | | | This makes it easier to collect failure data from test servers for further analysis. Signed-hostap: Jouni Malinen <j@w1.fi>
* P2P: Set P2P_DEV_PEER_WAITING_RESPONSE from TX status callbackJouni Malinen2013-04-262-4/+9
| | | | | | | | | | | | | | | | | Commit fb8984fd6f4b49d9178dd87a880dd7add514b7d1 added a mechanism to skip the Listen state when the peer is expected to be waiting for us to initiate a new GO Negotiation. However, this flag was set when building the GO Negotiation Response frame with status 1 regardless of whether we managed to send that frame or peer receive it. This could result in GO Negotiation failures in cases where the peer did not receive the response and Listen channels of the devices were different. Fix this by setting the flag only after TX status indicating success has been received. This fixes frequent failures shown for the test_grpform_pbc hwsim test case. Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
* tests: Capture hwsim0 packet dump during test runJouni Malinen2013-04-262-0/+3
| | | | Signed-hostap: Jouni Malinen <j@w1.fi>
* EAP peer: Add check before calling getSessionId methodShijie Zhang2013-04-261-3/+5
| | | | | | | | | We should not call getSessionID method if it's not provided. This fixes a regression from commit 950c5630768285e460aa336c78a18162fb3e0434 where EAP methods that did not implement getSessionId resulted in NULL pointer dereference when deriving the key. Signed-off-by: Shijie Zhang <shijiez@qca.qualcomm.com>
* Disable network temporarily on repeated connection failuresJouni Malinen2013-04-251-0/+6
| | | | | | | | | | Previously, only explicit indications of authentication failures were used to disable a network block temporarily. Extend this to use multiple failed connection attempts as a sign of a possible authentication or authorization failure to reduce the frequency of connection attempts with a network that does not seem to allow connection. Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
* nl80211: Drop frame events that are for foreign addressJouni Malinen2013-04-231-4/+24
| | | | | | | This avoids duplicate processing of events when multiple BSSes are configured. Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
* nl80211: Reduce debug on Probe Request framesJouni Malinen2013-04-232-5/+8
| | | | Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
* P2P: Fix after_scan_tx processing during ongoing operationsJouni Malinen2013-04-232-2/+16
| | | | | | | | | | | | When Action frame TX is postponed until a pending p2p_scan completes, there may be additional operations that need to be continued after the postponed Action frame TX operation completes. Fix this by starting pending operation (if any) from TX status event for after_scan_tx frames. This fixes common errors seen with the test_discovery hwsim test case. Signed-hostap: Jouni Malinen <j@w1.fi>
* RSN: Update preauth scan results only based on new scan resultsJouni Malinen2013-04-231-7/+12
| | | | | | | | | The fast-connect optimization to skip a new scan did not update how the RSN preauthentication callback is used. There is no point in trying to add preauthentication candidates from cases where scan was skipped, so skip this call, too, in such cases. Signed-hostap: Jouni Malinen <j@w1.fi>
* Move wpa_s freeing into wpa_supplicant_deinit_iface()Jouni Malinen2013-04-231-3/+2
| | | | | | | | All wpa_supplicant_deinit_iface() callers ended up freeing wpa_s immediately after this call. Move os_free(wpa_s) into the deinit function to share the same call and make the deinit sequence clearer. Signed-hostap: Jouni Malinen <j@w1.fi>
* dbus_new: Add EAP logon/logoffPaul Stewart2013-04-235-1/+63
| | | | | | | | | Add "EAPLogoff" and "EAPLogon" interface DBus commands which parallel the "logoff" and "logon" wpa_ctrl commands which terminate and restart EAP authentication. Slightly enhance the "logon" case by expiring any running "startWhile" timer. Signed-hostap: Paul Stewart <pstew@chromium.org>
* hostapd: Add some testing optionsJohannes Berg2013-04-238-0/+104
| | | | | | | | | | In order to test clients in scenarios where APs may (randomly) drop certain management frames, introduce some testing options into the hostapd configuration that can make it ignore certain frames. For now, these are probe requests, authentication and (re)association frames. Signed-hostap: Johannes Berg <johannes.berg@intel.com>
* wpa_supplicant: Add option -I for additional config fileDmitry Shmidt2013-04-2310-13/+55
| | | | | | | | This option can be used only for global parameters that are not going to be changed from settings. Signed-off-by: Dmitry Shmidt <dimitrysh@google.com> Signed-off-by: Iliyan Malchev <malchev@google.com>
* nl80211: Fix nla_nest_start conversionJohannes Berg2013-04-231-1/+1
| | | | | | | | | | | Dmitry reported that the kernel could no longer parse the scheduled scan attributes correctly after my patch to use nla_nest_start/nla_nest_end. The reason is that the wrong attribute is closed I accidentally made it close the full scan config instead of just the SSID match set. Reported-by: Dmitry Shmidt <dimitrysh@google.com> Signed-hostap: Johannes Berg <johannes.berg@intel.com>
* wpa_supplicant: Add get_capability freqBruno Randolf2013-04-232-1/+58
| | | | | | | | | | | | | Add "get_capability freq" command to print a more verbose list of channels and frequencies in MHz. The tag "NO_IBSS" is added, if IBSS mode is not allowed on a channel. This allows userspace programs to get the frequencies and limitations associated with each channel. This extends the information already provided in "get_capability channels" but a new interface is chosen because of backwards compatibility considerations. Signed-hostap: Bruno Randolf <br1@einfach.org>
* Provide TLS alerts to CLI/UI over control interfaceChris Hessing2013-04-232-0/+5
| | | | | | | Harmonize EAP status events over control interface to provide same functionality as existing D-Bus callback. Signed-hostap: Chris Hessing <chris.hessing@cloudpath.net>
* P2P: Increase GTK rekeying period to 24 hoursJouni Malinen2013-04-231-0/+10
| | | | | | | Strong ciphers do not need frequent rekeying, so increase the default GTK rekeying period to 24 hours. Signed-hostap: Jouni Malinen <j@w1.fi>
* wlantest: Fix CCMP-256 cipherJouni Malinen2013-04-051-2/+2
| | | | | | | TK was incorrectly truncated in a way that resulted in CCMP (128-bit key) encryption being used in practice. Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
* TDLS: Fix key configuration with current mac80211Jouni Malinen2013-04-031-16/+52
| | | | | | | | | | | | | A kernel commit ("mac80211: fix FT roaming") started validating that the STA entry is marked associated when adding a key. While this is needed to fix some FT use cases with hardware crypto, it has a side effect of breaking TDLS key configuration. Work around this by trying to re-configure the key for the direct link after the STA entry has been set with all information. In addition, try to tear down the link if anything goes wrong in key configuration (if both attempts fail) or enabling the link in the driver. Signed-hostap: Jouni Malinen <j@w1.fi>
* WPS NFC: Allow configuration token to be built from network blockJouni Malinen2013-04-017-48/+127
| | | | | | | "WPS_NFC_CONFIG_TOKEN <WPS/NDEF> <network id>" can now be used to build an NFC configuration token from a locally configured network. Signed-hostap: Jouni Malinen <j@w1.fi>
* WPS ER: Allow Enrollee to be specified with MAC addressJouni Malinen2013-04-014-14/+42
| | | | | | | wps_er_pbc and wps_er_pin can now be used with both the UUID and MAC Address of the Enrollee. Signed-hostap: Jouni Malinen <j@w1.fi>
* WPS ER: Document additional NFC command for ER operationsJouni Malinen2013-04-011-6/+19
| | | | Signed-hostap: Jouni Malinen <j@w1.fi>
* WPS ER: Allow AP to be specified with BSSIDJouni Malinen2013-04-014-43/+82
| | | | | | | This extends the WPS ER commands that previously accepted only UUID as an identifier for an AP to use either UUID or BSSID for this. Signed-hostap: Jouni Malinen <j@w1.fi>
* tests: Add test cases for NFC+WPSJouni Malinen2013-04-011-0/+152
| | | | Signed-hostap: Jouni Malinen <j@w1.fi>
* WPS: Fix use of pre-configured DH keys with multiple operationsJouni Malinen2013-04-011-5/+2
| | | | | | | | | | | wps_build_public_key() takes the dh_ctx into use and another attempt to use the same DH keys fails with wps->dh_ctx being set to NULL. Avoid this by using the DH parameters only if dh_ctx is valid. This fixes cases where a use of local pre-configured DH keys followed by an operating using peer DH keys would faild due to unexpected attempt to use local keys again. Signed-hostap: Jouni Malinen <j@w1.fi>
* WPS: Be more careful with pre-configured DH parametersJouni Malinen2013-04-012-2/+26
| | | | | | | Make the implementation more robust against error cases with pre-configured DH parameters. Signed-hostap: Jouni Malinen <j@w1.fi>
* hostapd: Show more helpful message for -g and -G errorsJouni Malinen2013-04-011-2/+6
| | | | Signed-hostap: Jouni Malinen <j@w1.fi>
* Interworking: Try to use same BSS entry for storing GAS resultsJouni Malinen2013-04-012-3/+21
| | | | | | | | | | | | There may be cases where multiple BSS entries for a single BSSID are in the table. This is mostly in automated test cases due to the AP configuration changes, but something similar could potentially happen as a corner case in more realistic networks, too, e.g., when an AP changes its operating channel. Make network selection more robust by trying to find the exact BSS entry instead of any BSS entry with a matching BSSID when storing GAS/ANQP response. Signed-hostap: Jouni Malinen <j@w1.fi>
* tests: Use Wlantest class in test_autogo_tdlsJouni Malinen2013-04-011-23/+13
| | | | Signed-hostap: Jouni Malinen <j@w1.fi>
* tests: Add a test case for Hotspot 2.0 network selectionJouni Malinen2013-03-313-3/+130
| | | | Signed-hostap: Jouni Malinen <j@w1.fi>
* tests: Stop wpa_supplicant before hostapdJouni Malinen2013-03-311-2/+2
| | | | | | | | | | Stopping the AP first was not ideal for the test cases since it could result in wpa_supplicant trying to connect back and start a scan at the end of a test case and cause problems for the following test case that tried to scan in the beginning while the previously started scan was still in progress. Signed-hostap: Jouni Malinen <j@w1.fi>
* Optimize Extended Capabilities element to be of minimal lengthJouni Malinen2013-03-312-2/+16
| | | | | | Leave out zero octets from the end of the element. Signed-hostap: Jouni Malinen <j@w1.fi>
* hostapd/wpa_s: Use driver's extended capabilitiesJohannes Berg2013-03-318-56/+158
| | | | | | | | Some extended capabilities (I'm currently interested in "Operating Mode Notification" for VHT) are implemented by the kernel driver and exported in nl80211. Use these in hostapd/wpa_supplicant. Signed-hostap: Johannes Berg <johannes.berg@intel.com>
* tests: Use FLUSH command to clear wpa_supplicant stateJouni Malinen2013-03-313-16/+3
| | | | Signed-hostap: Jouni Malinen <j@w1.fi>
* Add ctrl_iface command FLUSH for clearing wpa_supplicant stateJouni Malinen2013-03-312-4/+68
| | | | | | | This is mainly for testing purposes where it is convenient to have an easy way of getting wpa_supplicant state cleared between test cases. Signed-hostap: Jouni Malinen <j@w1.fi>
* WPS: Skip rescanning after provisioning if AP was configuredMasashi Honma2013-03-313-4/+28
| | | | | | | | | If WPS provisioning step is completed with an AP that is in WPS configured state, we can skip a second scan after the provisioning step since the AP is unlikely to change its configuration in such a case. This can speed up WPS connection a bit by removing an unneeded scan. Signed-hostap: Masashi Honma <masashi.honma@gmail.com>
* tests: Ignore old scan results in couple more WPS test casesJouni Malinen2013-03-311-0/+4
| | | | | | | These have shown failures due to obsolete scan results from previous test cases being present. Signed-hostap: Jouni Malinen <j@w1.fi>
* tests: Use a more compact summary of test resultsJouni Malinen2013-03-311-2/+4
| | | | | | | | Do not print the potentially long list of passed test cases. In case of failure(s), make sure the failed test list is the last item in the report. Signed-hostap: Jouni Malinen <j@w1.fi>
* tests: Fix BSS table flushing and old result ignoring for WPS testsJouni Malinen2013-03-312-5/+10
| | | | | | | | | | | The WPS tests are more prone to fail if scan results from the previous test cases are allowed to remain in the wpa_supplicant BSS table during the consecutive test since the test setup uses the same BSSID for the test APs that change their configuration. Avoid these mostly bogus issues by enforcing wpa_supplicant to drop and ignore old scan results during the WPS test cases. Signed-hostap: Jouni Malinen <j@w1.fi>
* Add ignore_old_scan_res configuration parameterJouni Malinen2013-03-318-13/+67
| | | | | | | | | | | This can be used to configure wpa_supplicant to ignore old scan results from the driver cache in cases where such results were not updated after the scan trigger from wpa_supplicant. This can be useful in some cases where the driver may cache information for a significant time and the AP configuration is changing. Many such cases are for testing scripts, but this could potentially be useful for some WPS use cases, too. Signed-hostap: Jouni Malinen <j@w1.fi>