aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Declare wpa_debug_* variables in src/utils/wpa_debug.hJouni Malinen2013-12-3127-73/+4
| | | | | | | | | These were somewhat more hidden to avoid direct use, but there are now numerous places where these are needed and more justification to make the extern int declarations available from wpa_debug.h. In addition, this avoids some warnings from sparse. Signed-hostap: Jouni Malinen <j@w1.fi>
* Declare wpa_drivers in src/drivers/driver.hJouni Malinen2013-12-319-15/+6
| | | | | | This avoids some warnings from sparse. Signed-hostap: Jouni Malinen <j@w1.fi>
* tests: RADIUSJouni Malinen2013-12-312-1/+69
| | | | | | This adds initial set of test cases to increase RADIUS testing coverage. Signed-hostap: Jouni Malinen <j@w1.fi>
* tests: SSID contents and encodingJouni Malinen2013-12-311-2/+6
| | | | Signed-hostap: Jouni Malinen <j@w1.fi>
* tests: Add IEEE 802.1X and dynamic WEP test casesJouni Malinen2013-12-312-0/+70
| | | | Signed-hostap: Jouni Malinen <j@w1.fi>
* Clear EAPOL Logoff state on FLUSH commandJouni Malinen2013-12-311-0/+1
| | | | Signed-hostap: Jouni Malinen <j@w1.fi>
* tests: Verify mixed mode WPA+WPA2 operationJouni Malinen2013-12-311-0/+42
| | | | Signed-hostap: Jouni Malinen <j@w1.fi>
* tests: Verify WMM AC configuration and ACM=1 downgrade VO/VI->BEJouni Malinen2013-12-311-3/+39
| | | | Signed-hostap: Jouni Malinen <j@w1.fi>
* tests: WEXT functionalityJouni Malinen2013-12-311-0/+56
| | | | | | | | | It did not look like open mode association completed with WEXT.. I'm commenting that test case out for now since WPA2-PSK worked. If you care about WEXT, feel free to fix it and submit a patch to remove the "REMOVED_" prefix here.. Signed-hostap: Jouni Malinen <j@w1.fi>
* tests: Increase nl80211 test coverage with monitor/connectJouni Malinen2013-12-313-1/+83
| | | | | | | Add test cases to use connect command instead of auth+assoc commands and AP mode operations using the old monitor interface design. Signed-hostap: Jouni Malinen <j@w1.fi>
* nl80211: Add driver param for forcing monitor and connect APIsJouni Malinen2013-12-311-0/+12
| | | | | | | | use_monitor=1 and force_connect_cmd=1 driver parameters can now be used to force older monitor interface design and the connect API (SME in driver) to increase hwsim testing coverage. Signed-hostap: Jouni Malinen <j@w1.fi>
* tests: Verify cfg80211 P2P Device useJouni Malinen2013-12-311-0/+34
| | | | Signed-hostap: Jouni Malinen <j@w1.fi>
* nl80211: Fix nl_mgmt handling in partial error caseJouni Malinen2013-12-311-13/+14
| | | | | | | | | | | | | If Action frame registration in nl80211_mgmt_subscribe_non_ap() failed for any frame type, the previous implementation skipped nl80211_mgmt_handle_register_eloop() call. This is not desirable since none of the Action frame types could be received and even worse, the following nl80211_destroy_eloop_handle() call for nl_mgmt would likely result in crashing the process due to the ELOOP_SOCKET_INVALID XOR operation. This could be triggered at least in a P2P group interface startup failure case. Signed-hostap: Jouni Malinen <j@w1.fi>
* nl80211: Prefer newer scan result over older during duplicate removalJouni Malinen2013-12-311-3/+5
| | | | | | | | | | | Previously, it was possible for bss_info_handler() to end up dropping a newer scan result entry if there were two entries with the same BSSID and SSID (i.e., only frequency was different) and we were not associated with either. This could happen, e.g., in some P2P use cases where device discovery may happen on different channels. Fix this by checking the age of the scan entries as well to prefer the most recent response. Signed-hostap: Jouni Malinen <j@w1.fi>
* tests: Verify dynamic wpa_supplicant interface addition/removalJouni Malinen2013-12-316-15/+87
| | | | Signed-hostap: Jouni Malinen <j@w1.fi>
* wpaspy: Do not leave socket files behind if connection failsJouni Malinen2013-12-311-1/+6
| | | | | | | Ctrl::__init__ needs to handle socket.connect() exceptions and unlink the client socket file on failures. Signed-hostap: Jouni Malinen <j@w1.fi>
* wpaspy: Fix tracking of attached statusJouni Malinen2013-12-311-1/+7
| | | | | | | The attached variable was initialized and checked, but never updated. Fix that by updating it on successful ATTACH/DETACH command. Signed-hostap: Jouni Malinen <j@w1.fi>
* nl80211: Report set_supp_port failures in debug logJouni Malinen2013-12-311-2/+13
| | | | Signed-hostap: Jouni Malinen <j@w1.fi>
* nl80211: Share a helper function for connect and associate commandsJouni Malinen2013-12-311-130/+77
| | | | | | | Most of the attributes to these commands are identical and there is no need to maintain two copies of the same functionality. Signed-hostap: Jouni Malinen <j@w1.fi>
* Remove unnecessary build #ifdef from definitionsJouni Malinen2013-12-311-2/+0
| | | | | | This type of definition by itself does not change the binary at all. Signed-hostap: Jouni Malinen <j@w1.fi>
* Get rid of duplicated cipher suite and AKM definitionsJouni Malinen2013-12-3112-187/+68
| | | | | | | | | | | | | WPA_CIPHER_* and CIPHER_* are used for the exact same set of cipher suites with the main difference being that the WPA_CIPHER_* version is suitable to be used as a bitfield. Similarly, WPA_KEY_MGMT_* and KEY_MGMT_* have similar design for AKMs. There is no need to maintain two separate copies of the definitions since the bitfield compatible version can be used for both needs. Get rid of the CIPHER_* and KEY_MGMT_* versions to clean up the implementation by getting rid of unnecessary mapping functions. Signed-hostap: Jouni Malinen <j@w1.fi>
* nl80211: Use helper functions for cipher suite mappingJouni Malinen2013-12-311-264/+132
| | | | Signed-hostap: Jouni Malinen <j@w1.fi>
* nl80211: Set control port for NL80211_CMD_COMMANDJouni Malinen2013-12-311-0/+2
| | | | | | | | | NL80211_ATTR_CONTROL_PORT was previously set only for NL80211_CMD_ASSOCIATE, but it should also be set when using NL80211_CMD_COMMAND (driver-based SME) even though none of the current non-mac80211 drivers use this. Signed-hostap: Jouni Malinen <j@w1.fi>
* WPS: Clean up UUID debug printJouni Malinen2013-12-301-7/+9
| | | | Signed-hostap: Jouni Malinen <j@w1.fi>
* nl80211: Clean up regulatory rule debug printsJouni Malinen2013-12-301-32/+20
| | | | | | Combine maximum bandwidth and EIRP into a single debug print. Signed-hostap: Jouni Malinen <j@w1.fi>
* nl80211: Print frame registration match on same debug lineJouni Malinen2013-12-301-4/+5
| | | | | | This makes debug log a bit more readable. Signed-hostap: Jouni Malinen <j@w1.fi>
* Interworking: Allow cred blocks not to be saved to a fileJouni Malinen2013-12-305-0/+18
| | | | | | | | | | | The new cred block parameter 'temporary' can be used to indicate that a cred block is not to be saved to wpa_supplicant configuration file (e.g., "SET_CRED 0 temporary 1"). This is similar to the concept of temporary network blocks and allows cred blocks to be managed outside the wpa_supplicant config file when other parameters are still saved to the file written by wpa_supplicant. Signed-hostap: Jouni Malinen <j@w1.fi>
* tests: Verify PMKSA cachingJouni Malinen2013-12-292-1/+204
| | | | Signed-hostap: Jouni Malinen <j@w1.fi>
* Reset WPA parameters to default values on FLUSH commandJouni Malinen2013-12-291-0/+4
| | | | Signed-hostap: Jouni Malinen <j@w1.fi>
* tests: Point to the main hwsim page instead of directly to buildbotJouni Malinen2013-12-291-1/+1
| | | | | | This page provides more helpful information than the buildbot UI. Signed-hostap: Jouni Malinen <j@w1.fi>
* P2P: Remove WPA_DRIVER_FLAGS_P2P_MGMT optionJouni Malinen2013-12-298-1313/+18
| | | | | | | | | | | | | The option of handling upper layer P2P management operations within the driver/firmware was originally planned to be used with wpa_supplicant, but this has not really happened and there is no clear sign of this being needed in the near term either. This functionality has not been completed and it is certainly not being kept up-to-date or tested. As such, it is best to remove it for now and if this or something similar is needed in the future, it can be brought back once a clear need for it has been demonstrated first. Signed-hostap: Jouni Malinen <j@w1.fi>
* WPS: Use shorter scan interval during pre-provisioning searchJouni Malinen2013-12-291-1/+1
| | | | | | | | Previously, the shorter scan interval was already in use for the connection following the provisioning step, but same optimization can also be used for the pre-provisioning scan. Signed-hostap: Jouni Malinen <j@w1.fi>
* WPS: Replace wpas_wps_in_progress with identical wpas_wps_searchingJouni Malinen2013-12-293-15/+1
| | | | | | | There is no point in maintaining two different functions that do practically the same check of WPS state. Signed-hostap: Jouni Malinen <j@w1.fi>
* tests: Verify hostapd WPS_GET_STATUS commandJouni Malinen2013-12-291-0/+21
| | | | Signed-hostap: Jouni Malinen <j@w1.fi>
* tests: Verify hostapd WPS_CONFIG commandJouni Malinen2013-12-291-0/+11
| | | | Signed-hostap: Jouni Malinen <j@w1.fi>
* tests: Verify WPS information in hostapd STA commandJouni Malinen2013-12-291-0/+4
| | | | Signed-hostap: Jouni Malinen <j@w1.fi>
* tests: Show test counter on the START lineJouni Malinen2013-12-291-2/+5
| | | | | | | This makes it more convenient to figure out how far a test cycle is from live logs. Signed-hostap: Jouni Malinen <j@w1.fi>
* SAE: Fix ECC element y coordinate validation stepJouni Malinen2013-12-291-1/+1
| | | | | | | | prime_len was added to the start pointer twice and because of this, the actual y coordinate was not verified to be valid. This could also result in reading beyond the buffer in some cases. Signed-hostap: Jouni Malinen <j@w1.fi>
* tests: Validate EAP-EKE proposal negotiationJouni Malinen2013-12-291-8/+30
| | | | | | This covers all currently supported algorithms and the case of no match. Signed-hostap: Jouni Malinen <j@w1.fi>
* EAP-EKE: Allow forced algorithm selection to be configuredJouni Malinen2013-12-291-4/+46
| | | | | | | | | | phase1 parameters dhgroup, encr, prf, and mac can now be used to specify which algorithm proposal is selected, e.g., with phase1="dhgroup=3 encr=1 prf=1 mac=1" selecting the mandatory-to-implement case. This is mainly for testing purposes, but can also be used to enforce stronger algorithms to be used. Signed-hostap: Jouni Malinen <j@w1.fi>
* tests: Verify dual-radio WPS operationsJouni Malinen2013-12-291-0/+65
| | | | Signed-hostap: Jouni Malinen <j@w1.fi>
* tests: Use a single channel scan to avoid unnecessary waitJouni Malinen2013-12-291-1/+1
| | | | Signed-hostap: Jouni Malinen <j@w1.fi>
* tests: Verify SAE anti-clogging mechanismJouni Malinen2013-12-292-1/+24
| | | | Signed-hostap: Jouni Malinen <j@w1.fi>
* Remove unused information element parsing dataJouni Malinen2013-12-292-25/+0
| | | | | | | | These information elements are not really used anywhere in hostapd or wpa_supplicant nor is there any plan to use them. As such, there is no need to keep the code here either, so save couple of bytes here. Signed-hostap: Jouni Malinen <j@w1.fi>
* Remove unnecessary EVENT_RX_ACTIONJouni Malinen2013-12-2911-296/+172
| | | | | | | | | | | | This driver event was used separately for some Action frames, but all the driver wrappers converted to this from information that would have been enough to indicate an EVENT_RX_MGMT event. In addition, the received event was then converted back to a full IEEE 802.11 management frame for processing in most cases. This is unnecessary complexity, so get rid of the extra path and use EVENT_RX_MGMT for Action frames as well as other management frame subtypes. Signed-hostap: Jouni Malinen <j@w1.fi>
* Define __maybe_unusedJouni Malinen2013-12-291-0/+8
| | | | | | | | This can be used to silence compiler warnings in cases where #ifdef blocks can leave some variables or functions unused and there is no cleaner way of avoiding the warnings. Signed-hostap: Jouni Malinen <j@w1.fi>
* Do not process Action frames twice in hostapd SME/MLMEJouni Malinen2013-12-293-45/+65
| | | | | | | | | | | | | | | | | Commit 88b32a99d30894b2d6bb391371c442fc117edbab added support for using some Action frame processing in hostapd for drivers that handle most of SME/MLME internally (it added FT, this has since be extended for SA Query and WNM). However, this was added in a way that ended up getting both the hostapd_rx_action() and hostapd_action_rx() called for Action frames. This could result in an attempt to process FT, SA Query, and WNM Action frames twice. There is need for more significant cleanup in Action frame processing in hostapd depending on the driver type, but as a simple step to avoid issues, skip the hostapd_action_rx() call if hostapd_rx_action() processed the frame. Signed-hostap: Jouni Malinen <j@w1.fi>
* Fix whitespace styleJouni Malinen2013-12-292-4/+4
| | | | | | | Commit 88b32a99d30894b2d6bb391371c442fc117edbab added couple of lines with incorrect indentation. Signed-hostap: Jouni Malinen <j@w1.fi>
* tests: Verify wps_ap_pin command behaviorJouni Malinen2013-12-291-0/+36
| | | | Signed-hostap: Jouni Malinen <j@w1.fi>
* WPS: Remove unused send_wpabuf()Jouni Malinen2013-12-292-18/+0
| | | | Signed-hostap: Jouni Malinen <j@w1.fi>