Commit graph

1373 commits

Author SHA1 Message Date
Jouni Malinen 8b2600329f tests: Mesh beacon_int parameter
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-21 23:45:29 +02:00
Jouni Malinen 5554fbef46 tests: Make parallel VM start a bit more resource friendly
Wait one second between each kvm start to avoid hitting large number of
processes trying to start in parallel. This allows the VMs to be started
more efficiently for parallel-vm.py runs with large number of VMs.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-21 22:04:54 +02:00
Jouni Malinen b3f4134912 tests: Clear cfg80211 BSS table at the end of scan_hidden
It was possible for the hidden SSID entry to leak into following test
cases and result in failures, e.g., in this sequence:

scan_hidden
scan_reqs_with_non_scan_radio_work
radius_auth_unreachable
wep_open_auth

BSS <BSSID> picked incorrect BSS entry within wpa_supplicant due to the
old zero-length SSID showing up from the earlier hidden SSID case.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-21 21:58:47 +02:00
Jouni Malinen 2ffbf34db0 tests: Optimize test case execution order for multiple VMs
Move test cases with long duration to the beginning as an optimization
to avoid last part of the test execution running a long duration test
case on a single VM while all other VMs have already completed their
work.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-21 18:20:15 +02:00
Jouni Malinen 01c87519a3 tests: Do not mark proxyarp_open failed if ebtables is not available
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-21 17:14:00 +02:00
Jouni Malinen f24489d94f tests: Use new scripts for vm-run.sh codecov
Now there is only one set of commands to maintain. The separate reports
for individual components have not been of much use in the past, so they
are dropped for now.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-21 16:41:59 +02:00
Jouni Malinen cb0555f7be tests: EAP-IKEv2 protocol tests
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-21 16:16:26 +02:00
Jouni Malinen f41f670ea5 tests: ERP with EAP-IKEv2
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-20 23:48:53 +02:00
Jouni Malinen f1381f99e4 tests: Mesh ht_mode options
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-20 21:27:22 +02:00
Jouni Malinen f86868c253 tests: wdev_id in STATUS-DRIVER
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-20 21:18:26 +02:00
Jouni Malinen 542452a93d tests: hostapd behavior with interface in different bridge
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-20 21:01:31 +02:00
Jouni Malinen a42f88f8e7 tests: bg_scan_period parameter configuration
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-20 19:44:40 +02:00
Jouni Malinen 6343f24d35 tests: IBSS cfg80211 workarounds
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-20 19:36:41 +02:00
Jouni Malinen cece9b7df7 tests: Dynamic BSS add operation reusing existing interface
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-20 19:04:18 +02:00
Jouni Malinen 8916857da6 tests: TDLS with VHT
This adds some more coverage, but the TDLS setup is not for VHT due to
missing support in mac80211.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-20 18:44:48 +02:00
Jouni Malinen 4466fe6541 tests: VHT and 40 MHz channel
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-20 18:44:48 +02:00
Jouni Malinen d4d80e9a14 tests: SMPS AP configuration options
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-20 18:44:48 +02:00
Jouni Malinen 598555c7e8 tests: IEEE 802.1X with static WEP
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-20 18:44:48 +02:00
Jouni Malinen 1e7528298a tests: cfg80211 scan-for-auth workaround with WEP keys
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-20 17:28:53 +02:00
Jouni Malinen a5687274e1 tests: cfg80211 scan-for-auth workaround failing
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-20 17:22:18 +02:00
Jouni Malinen b97a7bf672 tests: Large number of BSS add operations with hostapd
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-20 17:13:00 +02:00
Jouni Malinen 863a54093d tests: rfkill block prior to wpa_supplicant start
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-20 16:46:39 +02:00
Jouni Malinen d92da8a23e tests: Radar detection on non-HT and on HT40- channels
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-20 13:50:19 +02:00
Jouni Malinen cac5526390 tests: Report ROAM failure in pmksa_cache_opportunistic_multiple_sta
There is no need to wait for the timeout if the ROAM command itself
failed. This could happen if an earlier test case had left hidden SSIDs
in the cfg80211 BSS table.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-20 13:37:08 +02:00
Jouni Malinen 1264b68355 tests: Clear cfg80211 scan results after wext_hidden
Leaving hidden SSIDs in the cfg80211 BSS table can result in errors in
the following test cases, so use special care to clear all BSS entries
at the end of the wext_hidden test case.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-20 13:36:01 +02:00
Jouni Malinen 5f35a5e27f tests: Add wait_connected() and wait_disconnected() helpers
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-20 13:10:09 +02:00
Jouni Malinen e0cccf26a4 tests: Add --codecov support to parallel-vm.py
This allows code coverage report to be generated must faster with the
help of parallel VMs executing test cases.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-20 01:24:28 +02:00
Jouni Malinen 42ce1a27e0 tests: Connection with large number of scan_ssid=1 network blocks
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-19 23:30:58 +02:00
Jouni Malinen ed930f064c tests: P2P_LISTEN and scan
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-19 23:17:06 +02:00
Jouni Malinen 558ac77c58 tests: setband and scans
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-19 23:08:10 +02:00
Jouni Malinen 7749b1c982 tests: Additional coverage for filter_ssids=1
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-19 20:26:07 +02:00
Jouni Malinen 91cc6f918a tests: AP_SCAN 2 operation
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-19 20:08:58 +02:00
Jouni Malinen 83e80d32f1 tests: SCAN requests while in non-scan radio work
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-12-19 15:23:07 +02:00
Jouni Malinen 7c5c1ba7b4 tests: P2P_LISTEN behavior with offchannel TX
This verifies that offchannel TX (PD in this specific case) does not
stop ongoing long P2P_LISTEN operation.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-12-18 16:41:40 +02:00
Jouni Malinen 89cd4355bb tests: Fix proxyarp_open IPv4-from-bridge
There were couple of typos in the IP addresses and there was no coverage
for the normal unicast ARP response from the bridge (since non-wireless
device does not get proxied by the AP). In addition, it is better to
change the IP address used here to be unique to make the sniffer logs
easier to interpret.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-18 16:41:40 +02:00
Jouni Malinen 6d5332948c tests: Use send_ns() helper for the earlier proxyarp_open NS packets
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-12-18 16:41:40 +02:00
Jouni Malinen 40e4c9c8b0 tests: Add traffic test to proxyarp_open
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-12-18 16:41:40 +02:00
Jouni Malinen 5a3ce80265 tests: ProxyARP behavior with IPv6 frames
This adds transmission of number of NS/NA frames to test ProxyARP
behavior. The actual validation of the AP behavior is still manual,
i.e., a separate inspectation of the capture files is needed.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-12-18 16:41:40 +02:00
Jouni Malinen 19cbe06238 tests: Add ebtables rules for ProxyARP
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-12-18 16:41:40 +02:00
Jouni Malinen a95c6973aa tests: Use non-promiscuous mode and packet-buffered tcpdump capture
This helps in avoiding truncated capture files in the proxyarp_open test
case.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-12-18 16:41:40 +02:00
Jouni Malinen 1d0b5a04e6 tests: Dump monitor messages before hwsim_utils test
This may be needed in some corner cases where broadcast frames with two
associated stations are received by both devices.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-12-18 16:41:40 +02:00
Jouni Malinen db1d66d879 tests: Fix wifi_display_persistent_group event checks
The final invitation case in this test was verified incorrectly. The GO
was already operatign in that case, so there was not supposed to be a
new P2P-GROUP-STARTED message from GO. That happened to be show up in
the pending event messages from the last instance, but that was just by
accident and any additional dump_monitor() operation added here would
cause this test to fail. Fix this by handling the final invitation
separately and verifying that only the client side indicates
P2P-GROUP-STARTED.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-12-18 16:41:40 +02:00
Jouni Malinen c8836a4f03 tests: Allow dump_monitor() to be used without global monitor interface
It is possible for WpaSupplicant instance to be used without the global
control socket, so allow dump_monitor() to handle this case cleanly.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-12-18 16:01:41 +02:00
Jouni Malinen 9d7fdac5b3 tests: Try to clear scan results after regulatory domain changes
It was possible for regulatory domain changes to "leak" into following
test cases in number of cases where the cfg80211 BSS table remained
after regulatory domain had been restored to world roaming. Try to make
this less likely to occur by explicitly clearing BSS table at the end of
test cases that use different regulatory domain. This makes P2P test
cases that verify channel selection based on world roaming rules more
robust.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-15 01:32:01 +02:00
Jouni Malinen 970a23f665 tests: Make flush_scan_cache() more robust
It was possible for BSS entries on the scanned channel (2412 MHz) to be
left behind after flush_scan_cache() call. Use a less likely channel
2417 MHz as the default channel to scan. This will hopefully get rid of
most problematic BSS entries from previous test cases. For example,
ap_hs20_oen followed by ap_hs20_random_mac could fail due to
INTERWORKING_CONNECT seeing non-RSN scan result from the previous test
case.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-15 01:13:03 +02:00
Jouni Malinen d48b64ba6c tests: Use helper function for adding open mesh network
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-14 23:34:43 +02:00
Jouni Malinen 7e3614df5c tests: Mesh with dynamic interface
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-14 23:28:36 +02:00
Jouni Malinen 5881873b86 tests: Make pmksa_cache_opportunistic_connect more robust
Use scan_for_bss() instead of scan(freq) to avoid false positives due to
active scan failing under heavy load.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-14 19:15:48 +02:00
Jouni Malinen acb63c753b tests: SAE with missing password
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-14 17:09:14 +02:00
Jouni Malinen 0e40d7daa4 tests: ERP when server has dropped the keys
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-14 15:47:04 +02:00
Jouni Malinen 777bbe7a3c tests: P2P_PRESENCE_REQ on group interface
This ends up using the special offchannel.c code path where a different
interface is selected for TX. In addition, the P2P-PRESENCE-RESPONSE
event is verified to be delivered on the group interface.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-14 15:47:04 +02:00
Jouni Malinen 11ace2ed1f tests: Mesh and missing SAE password
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-14 15:47:04 +02:00
Jouni Malinen fba65f7240 tests: Mesh BSS data
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-14 12:55:43 +02:00
Jouni Malinen 54cacef5eb tests: Mesh sae_groups configuration
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-14 12:55:40 +02:00
Jouni Malinen e9026725f7 tests: Extra coverage for command line arguments
The results for these are not currently verified, but this allows
--codecov runs to get more coverage for the command line argument
parsers.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-14 12:24:15 +02:00
Jouni Malinen e869f812d3 tests: DEAUTHENTICATE/DISASSCIATE/CHAN_SWITCH error cases
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-14 02:28:03 +02:00
Jouni Malinen 69f9912310 tests: Additional FETCH_OSU and CANCEL_FETCH_OSU coverage
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-14 02:28:03 +02:00
Jouni Malinen ea27f66292 tests: STOP_FETCH_ANQP
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-14 02:28:03 +02:00
Jouni Malinen 1eaeb7fbaa tests: P2P_UNAUTHORIZE to unauthorize a peer
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-14 02:28:03 +02:00
Jouni Malinen 909f13cc52 tests: Move 'SET pmf 0' from reset() to test cases
This avoids one more cleanup step between most test cases by clearing
the default PMF behavior change only in case it was actually modified
during a test.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-14 02:28:03 +02:00
Jouni Malinen be9f156200 tests: Move WPS_ER_STOP from reset() to test cases
This avoids one more cleanup step between most test cases by stopping ER
only in case it was actually used during a test.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-14 02:28:03 +02:00
Jouni Malinen d6b916c9db tests: WPS_ER_PBC error cases
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-14 02:28:03 +02:00
Jouni Malinen 8f8c2fe8b2 tests: WPS ER restart and stop
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-14 02:28:03 +02:00
Jouni Malinen b37dac50a2 tests: wpa_supplicant AP mode and PBC session overlap
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-14 02:28:02 +02:00
Jouni Malinen 6eae42f98f tests: Additional coverage for miscellaneous ctrl_iface commands
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-14 02:28:02 +02:00
Jouni Malinen 70d29ec946 tests: Extend RRM neighbor request testing
This uses a new testing mode in hostapd to allow RRM neighbor request
transmittion to be tested. For the second part of the test case to be
executed, mac80211_hwsim needs to be modified to claim support for the
required RRM capabilities (that change is not yet in Linux kernel).

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-12 21:09:32 +02:00
Jouni Malinen 357edd386f tests: Additional VENDOR_ELEM coverage
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-12 20:12:24 +02:00
Jouni Malinen d655bbc797 tests: DATA_TEST_* error cases
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-12 19:33:54 +02:00
Jouni Malinen b854d3c85d tests: EAPOL_RX failure cases
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-12 19:16:34 +02:00
Jouni Malinen f157078c13 tests: DRIVER_EVENT failure case
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-12 19:08:24 +02:00
Jouni Malinen 3d9848967a tests: Additional MGMT_TX coverage
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-12 19:05:00 +02:00
Jouni Malinen cbdfff0a73 tests: A single BSS with multiple key management options
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-12-12 14:05:43 +02:00
Jouni Malinen 9446f3c253 tests: SCAN error cases
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-12 01:13:35 +02:00
Jouni Malinen 530b519f78 tests: RADIO_WORK error cases
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-12 00:27:06 +02:00
Jouni Malinen 9c1be553c8 tests: Invalid VENDOR command
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-12 00:10:52 +02:00
Jouni Malinen c2bf6d3afc tests: SIGNAL_POLL in 160 and 80+80 MHz channels
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-11 23:37:02 +02:00
Jouni Malinen f8423317b3 tests: WNM_SLEEP error cases
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-11 23:03:10 +02:00
Jouni Malinen 08ba008c62 tests: AUTOSCAN reconfiguration while in SCANNING state
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-11 22:57:36 +02:00
Jouni Malinen 44c41cdf47 tests: Additional HS20_ICON_REQUEST coverage
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-11 16:14:24 +02:00
Jouni Malinen ea215c54d0 tests: Additional coverage for HS20_GET_NAI_HOME_REALM_LIST
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-11 16:12:59 +02:00
Jouni Malinen 5e80b502ee tests: Additiona GAS_REQUEST/GAS_RESPONSE_GET coverage
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-11 15:18:11 +02:00
Jouni Malinen 1ca6d13dac tests: Make wep_open_auth less likely to fail due to old scan entry
Flush cfg80211 cached scan results to avoid getting any non-WEP matches
for the BSS.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-12-11 15:18:11 +02:00
Jouni Malinen ea68ed56b9 tests: Additional ANQP_GET and HS20_ANQP_GET error coverage
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-11 15:18:11 +02:00
Jouni Malinen 7e71fbc169 tests: INTERWORKING_CONNECT with invalid parameter
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-11 15:18:11 +02:00
Jouni Malinen c62438b822 tests: Optimize p2p_persistent test cases
Number of unnecessary scan iterations can removed from these test cases
by specifying a single channel.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-11 15:18:11 +02:00
Jouni Malinen c93b6706d2 tests: Additional P2P_REMOVE_CLIENT coverage
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-11 15:18:11 +02:00
Jouni Malinen 7387532549 tests: Additional coverage for P2P_EXT_LISTEN
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-11 15:18:11 +02:00
Jouni Malinen bf1b59731a tests: Additional P2P_PRESENCE_REQ coverage
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-11 15:18:11 +02:00
Jouni Malinen d9f3bb1ad6 tests: ProxyARP ARP processing
This verifies processing of various ARP messages at an AP that enables
ProxyARP. All the validation steps have not yet been scripted, i.e., the
sniffer traces need manual analysis for full coverage.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-12-11 15:18:11 +02:00
Jouni Malinen 1872c52b8e tests: Additional P2P_SET coverage
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-11 15:18:11 +02:00
Jouni Malinen 25057d9227 tests: P2P cross connection
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-11 15:18:11 +02:00
Jouni Malinen 7b7b201785 tests: Additional P2P_PEER coverage
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-10 00:46:11 +02:00
Jouni Malinen 2fc4749c91 tests: Verify that EAP-FAST PAC and TLS session ticket was used
This provides a regression test that would have caught the recent
issue with tls_openssl.c change breaking EAP-FAST.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-09 23:47:47 +02:00
Jouni Malinen bccbd51a80 tests: Additional P2P_GROUP_ADD coverage
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-09 23:03:27 +02:00
Jouni Malinen 1ede3d2268 tests: Invitation Request retry and duplicated response
This verifies that the corner case of a duplicated, retransmitted
Invitation Response frame ends up being dropped instead of being
processed twice for the case of Invitation Request getting resend with
social channel as an operating channel in case of no common channels
found.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-12-09 16:26:54 +02:00
Jouni Malinen c703a1da70 tests: Additional P2P SD coverage
This adds P2P_SERV_DISC_REQ, P2P_SERVICE_ADD, and P2P_SERVICE_DEL error
cases and P2P_SERVICE_FLUSH and P2P_SERC_DISC_EXTERNAL testing.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-08 21:23:24 +02:00
Jouni Malinen dd15d44884 tests: P2P_GET_PASSPHRASE in P2P Client mode
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-08 21:15:26 +02:00
Jouni Malinen e22335e5db tests: Invalid P2P_INVITE parameters
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-08 21:15:26 +02:00
Jouni Malinen edd1dfb2bd tests: Invalid P2P_REJECT command
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-08 21:15:26 +02:00
Jouni Malinen ca9b78add8 tests: Additional coverage for P2P_PROV_DISC
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-08 21:13:17 +02:00
Jouni Malinen 6da4a0af92 tests: P2P_LISTEN while interface is disabled
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-08 21:13:17 +02:00
Jouni Malinen 450e584f04 tests: Additional P2P_CONNECT coverage
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-08 18:21:48 +02:00
Jouni Malinen 7457c63538 tests: Additional P2P_FIND parameter coverage
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-08 17:56:47 +02:00
Jouni Malinen 5b2f1e2456 tests: Additional BSS and BSS_FLUSH ctrl_iface command coverage
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-08 17:49:39 +02:00
Jouni Malinen 33d0b1579b tests: Optimize WPS tests by avoiding full scan
A single channel scan just before WPS_REG, WPS_PBC, and WPS_PIN commands
can be used to avoid having to run a full scan. This saves significant
amount of time in the WPS test cases.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-08 11:42:07 +02:00
Jouni Malinen 934d5b0403 tests: P2P_GET_PASSPHRASE
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-08 11:42:07 +02:00
Jouni Malinen a5c43328d9 tests: Additional GET_CAPABILITY coverage
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-08 11:42:07 +02:00
Jouni Malinen 80cb463463 tests: SAVE_CONFIG error cases
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-08 11:42:07 +02:00
Jouni Malinen 76b7694177 tests: Multiple networks and cred removal
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-08 11:42:07 +02:00
Jouni Malinen 8c020b0f05 tests: Additional DUP_NETWORK coverage
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-08 11:42:07 +02:00
Jouni Malinen 146374019a tests: Add missing test descriptions
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-08 11:42:06 +02:00
Jouni Malinen 5e2a8ec9e7 tests: wpa_supplicant ctrl_iface mesh command error cases
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-08 11:42:06 +02:00
Jouni Malinen d463c5566f tests: Additional coverage for SCAN_RESULTS and BSS entry flags
This increases wpa_supplicant_ie_txt(), print_bss_info(), and
wpa_supplicant_ctrl_iface_scan_result() testing coverage to include the
previously missing key management options.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-08 11:42:06 +02:00
Jouni Malinen feb795d6d3 tests: wpa_supplicant ctrl_iface BSSID command error case
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-08 11:07:56 +02:00
Jouni Malinen 061c55a232 tests: Check STATUS mode field during P2P group formation
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-08 11:07:56 +02:00
Jouni Malinen 67966089a6 tests: wpa_supplicant ctrl_iface CTRL-RSP-
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-08 11:07:56 +02:00
Jouni Malinen ed685e43ab tests: IBSS_RSN control interface command
This verifies that IBSS_RSN <peer> return OK for the case where a valid
and already connection peer address is given.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-08 11:07:56 +02:00
Jouni Malinen 8e33f9c67f tests: wpa_supplicant WPS_AP_PIN random PIN timeout and error caes
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-08 11:07:56 +02:00
Jouni Malinen 1490eff500 tests: More coverage for WPS NFC error and uncommon cases
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-08 11:07:56 +02:00
Jouni Malinen e946c8e682 tests: Fix a typo in an error message
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-08 11:07:56 +02:00
Jouni Malinen b54f697019 tests: Remove test names from VM command with parallel-vm.py
There is no need to pass the test case names to the VMs when using
parallel-vm.py. Removing those from the command line helps in avoiding
kernel panic if maximum number of kernel parameters limit is hit.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-07 15:33:22 +02:00
Jouni Malinen 2f816c212c tests: Optimize FT test cases
Use single channel scan instead of full scan to save time. In addition,
use EAP-GPSK which takes significantly less CPU that EAP-EKE with
default parameters.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-12-05 17:12:30 +02:00
Jouni Malinen c337d07a1b tests: FT_DS with unknown target
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-12-05 17:05:46 +02:00
Jouni Malinen 7fd5fd03ac tests: TDLS teardown using wildcard address
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-12-05 16:56:14 +02:00
Jouni Malinen e61f90875b tests: Disabling WNM keep-alive and hostapd doing client poll
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-12-05 16:51:21 +02:00
Jouni Malinen 19ef208640 tests: wpa_supplicant ctrl_iface SET operations
This adds more test coverage for wpa_supplicant SET ctrl_iface command.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-12-05 16:29:08 +02:00
Jouni Malinen 556408940e tests: SET disallow_aps in P2P GO mode
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-12-05 16:21:10 +02:00
Jouni Malinen c1e33588b8 tests: Optimize WFD connect_cli() calls
There is no need to run full scan in these test cases, so use single
channel scan to save time.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-12-05 15:47:21 +02:00
Jouni Malinen f8fee78879 tests: WFD_SUBELEM_SET/GET with all parameter
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-12-05 15:47:20 +02:00
Jouni Malinen ceb767d501 tests: More coverage for WMM-AC
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-12-05 14:08:24 +02:00
Jouni Malinen acc9a635c8 tests: EAP Re-authentication Protocol (ERP)
This tests RP EAP-Initiate/Re-auth-Start transmission, ERP key
derivation, and EAP-Initiate/Re-auth + EAP-Finish/Re-auth exchange and
rMSK derivation.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-12-04 12:16:29 +02:00
Jouni Malinen 8201054da6 tests: Huge number of network blocks and LIST_NETWORKS LAST_ID
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-12-02 23:47:34 +02:00
Jouni Malinen c7f35a9e96 tests: Make scan_for_auth more robust
It was apparently possible for this test case not to do what it was
supposed to do, i.e., get nl80211 Authenticate command failing due to
cfg80211 BS entry missing. With the external radio work blocking fixed,
this can be cleaned up by explicitly waiting for the scan event. In
addition, a less used channel can be selected to avoid finding other BSS
entries.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-12-01 20:17:08 +02:00
Jouni Malinen 243dcc4ae4 tests: Add a helper function for clearing scan cache
This makes it more convenient and consistent to clear the cached scan
results from cfg80211 and wpa_supplicant.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-12-01 12:20:53 +02:00
Jouni Malinen 6ef319f4ea tests: AddressSanitizer (ASan) build options
Add example build options that can be used to enable ASan for hwsim test
cases.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-11-30 15:53:11 +02:00
Jouni Malinen faa907389b tests: Stop connection at the end of monitor_iface_unknown_sta
Do not leave the station trying to connect at the end of the test case
since that can have an effect to the following test case. Such sequences
should be tested in test cases that are specifically designed for that
rather than randomly between test cases.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-11-30 15:53:11 +02:00
Jouni Malinen ee27f6737b tests: Increase WEXT coverage
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-11-30 01:05:44 +02:00
Jouni Malinen dc4c3dc4a2 tests: Simplify Michael MIC test file writing
Since run-tests.py is now required to run as root, there is no need to
use the somewhat awkward "sudo tee" construction; instead, just write
directly to the file.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-11-30 01:05:39 +02:00
Jouni Malinen ae13ad6413 tests: Make go_neg_with_bss_on_disallowed_chan more robust
Clear scan results to avoid PBC overlap issues caused by earlier test
cases. For example, go_neg_with_bss_connected followed by
go_neg_with_bss_on_disallowed_chan resulted in failure before this
change.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-11-29 15:22:43 +02:00
Jouni Malinen 8969bad521 tests: Monitor interface with hostapd
This increases testing coverage for nl80211 AP mode with monitor
interface.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-11-29 13:33:50 +02:00
Jouni Malinen 73a2f82887 tests: Increase retry limit and timeout for wpas_mesh_open_no_auto
This test case was failing every now and then due to dev1
(no_auto_peer=1) not receiving the new-peer-candidate event in time
before dev0 has already stopped retries on mesh peering open message.
This sounds somewhat expected with the default 4 * 40 ms = 160 ms
retries and 1000 TU beacon interval. Use maximum timeout 16 * 255 ms =
4080 ms to make this test case less likely to fail.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-28 23:02:30 +02:00
Jouni Malinen d9fee38658 tests: P2P invitation resend on no-common-channels
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-28 23:02:30 +02:00
Jouni Malinen cff6eed75b tests: Re-enable wext_open
driver_wext.c is again able to configure open network, so re-enable the
test case for it.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-28 23:02:30 +02:00
Johannes Berg b67cdbc162 tests: Allow wext in configuration
Both the wpa_supplicant and kernel configuration need wext to
run the wext testcase, enable those in the default/example
configurations.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2014-11-28 23:02:29 +02:00
Jouni Malinen ee3f9f3837 tests: Optimize autogo test cases by removing unnecessary scans
Keep full channel scans in autogo for test coverage, but use single
channel scan in all other autogo* test cases to remove unnecessary
waiting that does not add any test coverage. This removes more than one
minute from the total test execution time.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-28 23:02:29 +02:00
Jouni Malinen 5a631ad2c2 tests: Optimize ap_open_unexpected_assoc_event
Replace fixed sleep with waiting for a disconnection event. In addition,
remove unnecessary use of sudo.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-28 23:02:29 +02:00
Jouni Malinen 2005cb87e5 tests: Hide unnecessary wlantest_cli output
Unnecessary and confusing "OK" output from wlantest_cli got sent to
stdout.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-28 23:02:29 +02:00
Jouni Malinen e4d7b5134e tests: Move hessid and access_network_type reset to test case
This removes unnecessary reset() steps from between every test case.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-28 23:02:29 +02:00
Jouni Malinen 47dcb1186f tests: Move external_sim reset to test cases that change this
This removes unnecessary reset() step from between every test case.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-28 23:02:29 +02:00
Jouni Malinen a0559aa5ba tests: Make go_neg_forced_freq_diff_than_bss_freq more robust
It was possible for this test case to fail due to PBC overlap that was
detected based on previous test case having used PBC. Make that false
positive less likely to happen by explicitly clearing the scan cache on
the device.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-28 23:02:29 +02:00
Jouni Malinen 6ea5e19898 tests: Fix p2p_channel_random_social_with_op_class_change cleanup
p2p_oper_reg_class and p2p_oper_channel need to be restored to 0, not an
arbitrary 2.4 GHz channel to avoid issues for following test cases. For
example, p2p_channel_random_social_with_op_class_change followed by
p2p_autogo_pref_chan_not_in_regulatory ended up with the latter test
case failing.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-28 23:02:29 +02:00
Jouni Malinen 4b57af2aaa tests: Remove duplicated connectivity test from mesh
hwsim_utils.test_connectivity() is already bidirectional test, so there
is no need to run it twice with the devices swapped for the second
iteration.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-28 23:02:29 +02:00
Jouni Malinen 882f894831 tests: Make hidden SSID test cases more robust
Clear wpa_supplicant and cfg80211 scan results at the end of hidden SSID
test cases to avoid potential issues for following test cases. For
example, ap_hs20_session_info could fail if executed immediately after
ssid_hidden due to the AP configuration change from open to RSN was not
noticed.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-28 23:02:29 +02:00
Jouni Malinen a712282bc1 tests: proxyarp with DHCP snooping
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-28 23:02:29 +02:00
Jouni Malinen 356a497d39 tests: ProxyARP with DGAF disabled and multicast-to-unicast conversion
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-28 22:41:26 +02:00
Jouni Malinen 67aeee118a tests: Convert proxyarp tests to use DATA_TEST_FRAME
This is more robust and extensible than configuring IPv6 addresses on
the interfaces and trying to use ping6 or some other external tools to
generate suitable IPv6 frames.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-28 20:00:14 +02:00
Jouni Malinen 54fe526ac4 tests: Make p2p_messages tests more robust under load
The 50 ms wait time for Action frame response was not sufficient when
the tests are run under heavy load (e.g., multiple VMs in parallel).

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-27 21:44:01 +02:00
Jouni Malinen 0e02a557d3 tests: Make p2p_msg_invitation_req_to_go more robust
Wait for GO to start before sending invitation frames in the protocol
test. Without this, it was possible to hit the 5 second timeout on
management frame RX under load.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-27 21:22:31 +02:00
Jouni Malinen 4d7cc3961f tests: Make go_neg_with_bss_connected more robust
It was possible for this test case to fail due to PBC overlap that was
detected based on previous test case having used PBC. Make that false
positive less likely to happen by explicitly clearing the scan cache on
the devices.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-27 21:06:18 +02:00
Jouni Malinen 3c086180c1 tests: Make ap_wps_reg_config_tkip failure log more helpful
The "Not fully connected" report did not clearly identify what went
wrong, so make this more verbose in hope of being able to determine what
happened should this test case fail again.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-27 20:33:35 +02:00
Jouni Malinen 9ed53f5edf tests: Increase WPS connection timeout to make tests more robust
It was possible to hit the 10 second timeout in some test cases under
heavy load (e.g., with large number of VMs running tests in parallel).
These timeouts are not really indicating any real error, so make them
less likely to show up in reports by increasing the connection timeout
to 30 seconds.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-27 20:30:07 +02:00
Johannes Berg 6bb9d861f9 tests: Ignore status responses without =
There are valid status (and possibly status-driver) responses
that don't have a name=value format, ignore those in the test
framework parser.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2014-11-27 20:15:51 +02:00
Jouni Malinen 9363f5e065 tests: Optimize run-tests.py --prefill-tests startup time
It took significant part of the startup latency to prefill the database
with test cases due to the SQL COMMIT operation between each added row.
Move COMMIT to outside the loop to speed startup significantly.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-27 20:08:15 +02:00
Jouni Malinen 499c5e9dc6 tests: Follow test sequence from run-tests.py command line
It can be useful to specify an exact order of test cases and also to
allow the same test case to be run multiple times when the list of tests
is provided on the command line.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-27 19:48:41 +02:00
Johannes Berg 7ee6ec7aec tests: Create new radios for MCC tests
For tests that require a radio with multi-channel concurrency,
create a new one on the fly that does have more than 1 channel.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2014-11-27 18:25:25 +02:00
Johannes Berg 788dc17f8c tests: Use tshark -Y instead of tshark -R
Newer versions of tshark don't like the -R (read filter) argument
for filtering and just show a deprecation warning. Use -Y (display
filter) instead, which hopefully also works on older versions.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2014-11-27 18:24:26 +02:00
Jouni Malinen 1131a1c8d2 tests: Replace last remaining hwsim_test uses with DATA_TEST
External tool is not needed anymore to run the data connectivity tests
since hostapd test mode now allows the possible bridge or VLAN interface
to be specified.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-27 14:09:07 +02:00
Jouni Malinen 5f7b07de91 tests: ProxyARP
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-26 01:37:54 +02:00
Jouni Malinen 17ffdf3951 tests: Clear sae_groups to default value in forgotten cases
It was possible for some of the SAE test cases (e.g., ap_ft_sae) to fail
if they were run after the sae_groups test case that left the SAE group
configuration to a value that is not enabled by default. Fix this by
clearing sae_groups setting in the couple of test cases that were not
yet doing this.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-11-25 15:19:19 +02:00
Jouni Malinen 7c8f5ea6a0 tests: WPA2-PSK with RADIUS for passphrase
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-11-25 01:28:34 +02:00
Jouni Malinen df4733dff9 tests: WNM BSS TM Req with non-global operating class table
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-11-24 10:58:33 +02:00
Jouni Malinen 986ed3a9ca tests: NEIGHBOR_REP_REQUEST failure cases
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-11-22 21:49:45 +02:00
Jouni Malinen 13f8d51e2d tests: BSS Transition Management
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-11-22 20:17:47 +02:00
Jouni Malinen 73360424d9 tests: Fix a typo in function name
except_ack() was supposed to be verifying that the frame was ACK'ed,
i.e., it was really supposed to be called expect_ack().

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-11-22 18:40:03 +02:00
Jouni Malinen ab4ee34306 tests: Fix wnm_bss_tm_req status code expectation
The implementation of WNM BSS transition management was extended to be
able to return a reject status code based on whether a matching entry is
found. The test case wnm_bss_tm_req was trying to enforce a different
status code to be used here based on old implementation.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-11-22 18:40:03 +02:00
Jouni Malinen 64d04af5cc tests: Authenticator processing for various EAPOL-Key key info values
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-22 00:49:25 +02:00
Jouni Malinen a52fd1c338 tests: WPA EAPOL 4-way handshake protocol testing
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-22 00:34:20 +02:00
Jouni Malinen 53b9bedb7a tests: WPA2 EAPOL-Key with incorrect type
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-22 00:16:41 +02:00
Jouni Malinen 821490f55f tests: Authenticator 4-way handshake protocol testing
This implements minimal RSN 4-way handshake Supplicant in Python and
uses that to test hostapd Authenticator implementation in various
possible protocol sequencies.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-21 20:50:41 +02:00
Jason Mobarak f54b926baa tests: Mesh HT mode
Change the mesh tests to check for the presence of HT in the scan
results.

[original implementation by Chun-Yeow Yeoh <yeohchunyeow@gmail.com>]
[some fixes by Masashi Honma <masashi.honma@gmail.com>]
Signed-off-by: Ashok Nagarajan <ashok.dragon@gmail.com>
Signed-off-by: Javier Cardona <javier@cozybit.com>
Signed-off-by: Jason Mobarak <x@jason.mobarak.name>
2014-11-20 17:01:43 +02:00
Javier Lopez 68157c0674 tests: Add test_wpas_mesh test cases
This wpa_supplicant tests include basic tests for:

- Mesh scan
- Mesh group add/remove
- Mesh peer connected/disconnected
- Add/Set/Remove to test mesh mode network
- Open mesh connectivity test
- Secure mesh connectivity test
- no_auto_peer

Signed-off-by: Jason Mobarak <x@jason.mobarak.name>
[no_auto_peer test by: Javier Cardona <javier@cozybit.com>
Signed-off-by: Javier Lopez <jlopex@gmail.com>
2014-11-20 16:31:12 +02:00
Jouni Malinen f6d1c5d9f8 tests: Fix regression in START line total count
The previous changes to enable stdin control broke the previous case of
showing the total number of test cases in the START lines. Fix that by
using a separate variable for the total number of test casess instead of
using length of the list of remaining test cases.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-11-19 22:02:08 +02:00
Jouni Malinen 41aa4bd739 tests: WEP Shared Key index change without deauth
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-19 17:57:49 +02:00
Jouni Malinen 168d4b097c tests: WEP with non-zero key index
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-19 17:37:54 +02:00
Jouni Malinen 3e473674f7 tests: P2P_FIND continuing after GO Negotiation failure
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-19 16:59:11 +02:00
Jouni Malinen 077f13c3e1 tests: Move parallel-vm.py test control to the host
This allows all VMs to be used at the end of a test sequence by
assigning test cases to VMs based on which VM is available for a new
test case rather than splitting the full task at the beginning and
potentially getting stuck with the last VM running long test cases for
significantly longer than another VM that gets shorter duration tests
assigned to it.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-11-19 15:20:53 +02:00
Jouni Malinen 0d7456e9fd tests: Add run-tests.py -i to control execution from stdin
The new -i command line argument can be used to control test case
execution from stdin to run-tests.py and vm-run.sh. This can be used,
e.g., to run multiple repeated test sequences in a virtual machine
without havign to restart the VM between each iteration.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-11-19 15:20:53 +02:00
Jouni Malinen cb8cb33e55 tests: Allow run-tests.py to be run from the vm directory
Some of the paths in run-tests.py are hardcoded and could not handle
tests/hwsim/vm as the working directory. Modify the design enough to
allow ../run-tests.py -L to be used from the vm directory.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-11-19 15:20:53 +02:00
Jouni Malinen 5e3c0b02a7 tests: Make run-tests.py process test case selection arguments
This allows a list of matching test cases to be produced without having
to run the test cases. Previously, -L output included all defined test
cases regardless of what else was included on the command line.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-11-19 15:20:52 +02:00
Jouni Malinen 44ac019c96 tests: Report kernel panic clearly in parallel-vm.py
Previously, it was possible for a kernel panic to be missed since the
only sign of it in stdout was reduced number of passed test cases.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-11-16 22:34:54 +02:00
Jouni Malinen 7e6942253c tests: Use a single timestamp in all vm-run.sh instances
This avoids possible mismatches in directory and log file timestamps if
the UNIX timestamp (seconds) changes during the startup sequence.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-11-16 22:24:18 +02:00
Eliad Peller 7613345814 tests: Add wpa_supplicant WMM-AC test
Add basic wpa_supplicant tests for WMM-AC TSPEC addition/deletion.

Signed-off-by: Eliad Peller <eliadx.peller@intel.com>
2014-11-16 21:40:57 +02:00
Jouni Malinen b652daca84 tests: Suite B
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-11-16 17:09:11 +02:00
Jouni Malinen eec0cc8da2 tests: Clear ignore_old_scan_res setting
This parameter was used in some of the NFC test cases to make scanning
more robust in case of changing AP configuration. However, the parameter
was not cleared anywhere, so it could have been left in use for other
test cases as well. To get more consistent behavior, clear the value
back to its default between test cases.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-11-15 12:56:02 +02:00
Jouni Malinen 9128f520c3 tests: PMF required with SHA1-based AKM
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-11-14 20:56:43 +02:00
Jouni Malinen 2a6cce3842 tests: DFS with chanlist
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-11-01 19:56:44 +02:00
Ilan Peer 006a1c4d3b tests: Make vm-run.sh arguments non-positional
This was currently breaking parallel-run.*, as it was passing
--split num/num parameters (intended for rnu-tests.py)
to vm-run.sh which broke the --codecov and --timewrap options.

Signed-off-by: Ilan Peer <ilan.peer@intel.com>
2014-11-01 17:55:23 +02:00
Ilan Peer 40c57fa88f tests: Update vm README
Update the code coverage documentation to also specify the
source base directory for the code coverage generation.

Signed-off-by: Ilan Peer <ilan.peer@intel.com>
2014-11-01 17:08:29 +02:00
Ilan Peer 6e04f41168 tests: Add usage() to run-all.sh
The -h or --help command line arguments can now be used to request usage
information for run-all.sh.

Signed-off-by: Ilan Peer <ilan.peer@intel.com>
2014-11-01 17:08:29 +02:00
Ilan Peer 5d60296ea7 tests: Add option to build before running all tests
Add an option --build to run-all.sh to build before starting to run all
the tests. In addition, add an option --codecov to extract the code
coverage data at the end of the run.

Signed-off-by: Ilan Peer <ilan.peer@intel.com>
2014-11-01 17:08:29 +02:00
Ilan Peer a7fe868dae tests: Make run-all.sh arguments non-positional
Signed-off-by: Ilan Peer <ilan.peer@intel.com>
2014-11-01 17:08:29 +02:00
Jouni Malinen 96a6c4c098 tests: Concurrent station mode scan and p2p_find with P2P Device
This verifies that station mode interface SCAN command gets executed if
P2P Device instance is running p2p_find.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-10-31 00:50:01 +02:00
Jouni Malinen 70892f697f tests: P2P_STOP_FIND/P2P_FLUSH to ignore new results
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-10-31 00:50:01 +02:00
Jouni Malinen 0ee41e866c tests: GO Negotiation and timeout while waiting for peer
grpform_cred_ready_timeout2 is similar to the grpform_cred_ready_timeout
test case with the difference being in initiating a P2P_FIND operation
during the wait.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-10-29 12:52:51 +02:00
Jouni Malinen 4fb26cee95 tests: Remove ap_ht40_csa and ap_ht40_csa3 workarounds
The issue in mac80211 was identified and proposed fix is now available,
so remove the workaround here and start reporting failures from
unexpected disconnection during CSA.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-28 14:01:16 +02:00
Jouni Malinen 5e29a90079 tests: Scan result update changing last_scan_res and connect_work
This verifies that last_scan_res and connect work pointers to BSS
entries get updated when scan result update ends up removing or
reallocating a BSS entry.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-10-28 00:43:58 +02:00
Jouni Malinen 1531402ee4 tests: WPS with ap_scan=2
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-10-27 20:19:45 +02:00
Jouni Malinen 72a8e30b96 tests: Allow GCMP to be added into ap_wps_mixed_cred network profile
This is needed in preparation for WPS AES being mapped to enabling both
CCMP and GCMP if the driver supports both ciphers.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-10-27 16:52:10 +02:00
Ilan Peer 3bfa5f10a9 tests: Add support for reading modules list from a file
The new run-tests.py argument "-l <file>" can now be used to specify the
test modules using a text file.

Signed-off-by: Ilan Peer <ilan.peer@intel.com>
2014-10-26 23:27:26 +02:00
Ilan Peer 6492a9cada tests: Add usage() to build.sh
Signed-off-by: Ilan Peer <ilan.peer@intel.com>
2014-10-26 19:21:04 +02:00
Ilan Peer 2593aadb3b tests: Add an option to force copy config files
"./build.sh --force-config" can be used to force copying configuration
files before building. This will overwrite any changes in .config files.

Signed-off-by: Ilan Peer <ilan.peer@intel.com>
2014-10-26 19:19:39 +02:00
Ilan Peer 102c2bf461 tests: Add an option to build with code coverage
"./build.sh --codecov" can now be used to request CONFIG_CODE_COVERAGE=y
to be added to hostapd and wpa_supplicant .config files.

Signed-off-by: Ilan Peer <ilan.peer@intel.com>
2014-10-26 19:18:34 +02:00
Jouni Malinen 412d764727 tests: cfg80211 connect command for WEP connection
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-26 17:01:37 +02:00
Jouni Malinen 8619c33420 tests: External bridge control for hostapd interface
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-26 11:29:16 +02:00
Jouni Malinen cded555f06 tests: hostapd rfkill
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-26 10:53:37 +02:00
Jouni Malinen ac69c33297 tests: Print failure exeception if logger output goes to file
This makes it more convenient to determine failure reasons during test
case development and VM testing.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-26 10:39:32 +02:00
Jouni Malinen 9d3d2dbdcb tests: IP address in STATUS
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-26 10:21:48 +02:00
Jouni Malinen 85b60adddd tests: Make ap_ht40_csa and ap_ht40_csa3 less likely to fail
It looks like cfg80211 can trigger disconnection even without disabling
HT, so the same issue may be hit with both of the channel switches in
these test cases.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-25 23:19:48 +03:00
Jouni Malinen 42a4ba2865 tests: Group formation wait for peer with driver increasing ROC duration
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-25 21:46:39 +03:00
Jouni Malinen 99e5f0e616 tests: Channel switch with HT40
ap_ht40_csa and ap_ht40_csa3 seem to show a cfg80211/mac80211 issue
where a CSA from HT40+ to HT40- channel results in HT getting disabled
due to cfg80211_chandef_compatible() check on c1->width == c2->width
claiming that the new channel is not compatible. For now, comment out
the FAIL case for these known issues to avoid constant failure for cases
that are not wpa_supplicant/hostapd issues. Once the kernel side design
has been reviewed, these error cases can be enabled here.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-25 12:09:02 +03:00
Jouni Malinen d4792c0cb7 tests: Channel switch with VHT80
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-25 11:29:28 +03:00
Jouni Malinen bd5a7691bf tests: Radar detection on HT40 channel
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-25 10:52:06 +03:00
Jouni Malinen fbb79f94eb tests: Allow time for go_neg_pbc() GO Neg Resp to go out
It was possible for the not-pre-authorized GO Negotiation case to end up
starting new GO Negotiation before the GO Negotiation Response frame
with status=1 was transmitted. While this works for group formation, it
could reduce test coverage for the common case where that response is
received. At a small sleep to make it less likely for this unexpected
sequence to happen during testing.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-10-23 16:33:25 +03:00
Johannes Berg 1e3c7e82b5 tests: Disable support_p2p_device by default
When loading the hwsim module, disable support_p2p_device by default.
This will also become the default in the kernel, but until then it
makes sure it's not turned on by default.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2014-10-22 10:53:52 +03:00
Johannes Berg 5a8d165cd8 tests: Use dynamic radio for P2P_DEVICE tests
Use dynamic radios for P2P_DEVICE tests to be able to test
support when the default in hwsim is to not support it.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2014-10-22 10:53:45 +03:00
Jouni Malinen 9b2c227216 tests: Run run-tests.py as root from run-all.sh
This will be needed to be able to control dynamic mac80211_hwsim
operations like adding and removing a phy. In the past, it has been
possible to start the main programs as root and then use non-root
account for run-tests.py. However, there is already a large number of
cases within the test scripts where sudo is needed. Moving that
requirement to execution of run-tests.py allows those to be simplified
as well.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-22 10:50:57 +03:00
Jouni Malinen 81ea400d37 tests: P2P SD with GO
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-10-21 23:32:17 +03:00
Jouni Malinen 4181c3964d tests: BSS Load updates
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-10-21 23:32:11 +03:00
Johannes Berg 8a5cc2fe38 tests: Introduce hwsim radio context manager
The new HWSimRadio context manager allows the following
syntax to create (and appropriately destroy) a new radio:

  with HWSimRadio([...]) as (radio_id, iface_name):
    [...]

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2014-10-21 17:35:20 +03:00
Johannes Berg 91d7a9a1c5 tests: Allow creating radio with p2p-device support
For testing P2P-Device support properly, allow dynamically
creating radios with support for it in hwsim.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2014-10-21 17:35:20 +03:00
Jouni Malinen eb92d389a8 tests: Remove wlan5-related interfaces based on list
Instead of hardcoding reset_devs() to remove wlan5, remove all wlan*
interfaces renaming in the wpa_supplicant process to support the case of
dynamically added hwsim phy.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-20 12:52:25 +03:00
Jouni Malinen 5f797376f2 tests: Make RELOG command use global control interface
This allows RELOG to be used even if a wpa_supplicant process does not
have any interfaces configured.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-20 12:52:25 +03:00
Jouni Malinen ce9c8c4097 tests: Use internal DATA_TEST_* functionality instead of hwsim_test
This replaces use of the external hwsim_test tool for most data
connectivity test cases. Only the cases where a special interface
(bridge/VLAN) is used are still executed through hwsim_test.

The internal DATA_TEST_* functionality makes it easier to extend the
connectivity test cases through an external device with real WLAN
hardware instead of the hwsim test setup. In addition, the error reports
from this code can be made more informative.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-19 22:27:37 +03:00
Jouni Malinen 4823566ca7 tests: Add WpaSupplicant.wait_group_event()
This can be used to wait for events from a P2P group interface.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-19 22:27:37 +03:00
Jouni Malinen f6420942cb tests: Add own_addr() for both Hostapd and WpaSupplicant classes
This makes it easier to use instances of control interfaces in common
code without having to separately address hostapd and wpa_supplicant
behavior differences.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-19 22:27:37 +03:00
Jouni Malinen a8375c94c0 tests: Pass wpas/hapd instance to test_connectivity()
This makes it easier to replace data connectivity testing to use
something else than local hwsim_test binary on the controller device.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-19 17:54:49 +03:00
Luciano Coelho 5d7746b589 tests: Add test cases for AP channel switch announcement
Signed-hostap: Luciano Coelho <luciano.coelho@intel.com>

Skip CSA tests if the driver doesn't support this in AP mode.

Signed-hostap: Andrei Otcheretianski <andrei.otcheretianski@intel.com>
2014-10-19 16:04:31 +03:00
Jouni Malinen a709c5e29f Add a test vector for AES-SIV
This verifies that the AES-SIV implementation results matches RFC 5297
test vector A.1.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-19 12:43:40 +03:00
Jouni Malinen 71c41d45af tests: Provide more details of parallel testing with curses UI
This extends parallel-vm.py to show more details about testing progress
from each VM.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-19 11:19:49 +03:00
Jouni Malinen 9c2d2378ba tests: P2P re-invocation with p2p_add_cli_chan=1
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-18 17:00:57 +03:00
Toby Gray fd1776536b tests: Removing a P2P group via the group control interface
This adds a test which attempts to use the control interface for the
P2P group to remove the P2P group.

Signed-off-by: Toby Gray <toby.gray@realvnc.com>
2014-10-18 16:22:25 +03:00
Jouni Malinen 19d3a6e364 tests: SAE PMKSA caching
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-18 13:03:17 +03:00
Jouni Malinen 414236b5db tests: RADIUS accounting with PMKSA caching
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-18 10:20:07 +03:00
Jouni Malinen a87e123a96 tests: Add Python-version of parallel-vm.sh
This is a more advanced version of the simple parallel-vm.sh script.
Status of each VM is printed out during the test and results are
provided in more convenient format in the end.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-12 21:49:36 +03:00
Jouni Malinen 3f08d1cde8 tests: WPS PBC triggered based on hostapd event
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-12 17:58:04 +03:00
Jouni Malinen 6503deb9ac tests: Wi-Fi Display element updates and P2P-DEVICE-FOUND
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-12 16:46:24 +03:00
Jouni Malinen 0a5787162a tests: Make ap_hs20_fetch_osu more robust under heavy load
Use scan_for_bss() instead of scan() to avoid errors if the active scan
fails, e.g., due to heavy load under parallel-vm.sh test run.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-12 12:38:18 +03:00
Jouni Malinen 89f20842f6 tests: OpenSSL cipherlist configuration
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-12 11:59:04 +03:00
Jouni Malinen b43ac5d5ab tests: P2P group formation with WSC_Done missing
This verifies that GO is able to complete group formation even if the
P2P Client does not send WSC_Done message (or that message is dropped
for any reason) in case the P2P Client completes 4-way handshake
successfully.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-10-10 18:40:57 +03:00
Jouni Malinen cf0b9c86c5 tests: 4-way exchange using external EAPOL I/O
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-10-10 18:40:57 +03:00
Jouni Malinen 64502039c0 tests: Make ap_hs20_session_info more robust
It looks like mac80211 scan-while-associated can now take over 10
seconds with the current wireless-regdb rules for world roaming due to
number of additional DFS channel having been enabled for passive
scanning. This resulted in ap_hs20_session_info failing due to the wait
for the scan result event timing out. That is not really a real failure,
so increase the timeout to avoid reporting this incorrectly.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-10 00:37:07 +03:00
Jouni Malinen 74ed673f33 tests: VHT 80+80 MHz
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-10-09 14:27:23 +03:00
Jouni Malinen bc86d8c158 tests: Fix DFS radar-during-CAC test case
This uses mac80211_hwsim dfs_simulate_radar to get the real kernel side
CAC operation executed and aborted due to radar detection. This allows
another channel to be selected properly through another CAC run.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-10-09 02:10:34 +03:00
Jouni Malinen 831cb7af96 tests: Extend DFS testing to include channel switch
Simulate a radar detection event to verify that hostapd switches
channels properly and the station follows the AP to the new channel.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-10-09 01:23:21 +03:00
Jouni Malinen c634d320ef tests: Re-enable DFS connection check
It looks like association with DFS works fine with the current kernel
version, so re-enable this part of the DFS test cases.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-10-08 18:27:12 +03:00
Jouni Malinen 6259fd814b tests: VHT with 160 MHz channel width
Since this requires a recent CRDA version and updated wireless-regdb, do
not report failures yet (i.e., indicate that the test case was skipped
if AP startup fails).

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-10-08 18:18:39 +03:00
Jouni Malinen b1f4015cf5 test-aes: Allow NIST key wrap test vectors to be verified
This allows the aes_wrap() and aes_unwrap() implementation to be
verified against KW_{AE,AD}_{128,192,256}.txt test vectors from
http://csrc.nist.gov/groups/STM/cavp/documents/mac/kwtestvectors.zip

For example:
./test-aes NIST-KW-AE kwtestvectors/KW_AE_128.txt
./test-aes NIST-KW-AE kwtestvectors/KW_AE_192.txt
./test-aes NIST-KW-AE kwtestvectors/KW_AE_256.txt
./test-aes NIST-KW-AD kwtestvectors/KW_AD_128.txt
./test-aes NIST-KW-AD kwtestvectors/KW_AD_192.txt
./test-aes NIST-KW-AD kwtestvectors/KW_AD_256.txt

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-07 14:57:10 +03:00
Jouni Malinen eefec1e40b AES: Extend key wrap design to support longer AES keys
This adds kek_len argument to aes_wrap() and aes_unwrap() functions and
allows AES to be initialized with 192 and 256 bit KEK in addition to
the previously supported 128 bit KEK.

The test vectors in test-aes.c are extended to cover all the test
vectors from RFC 3394.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-07 14:57:06 +03:00
Jouni Malinen b9dee18ffe tests: VENDOR_ELEM_REMOVE of the second IE
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-07 00:43:50 +03:00
Jouni Malinen 5b7aeddcd7 tests: OKC with multiple stations
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-04 23:01:08 +03:00
Jouni Malinen 35a7646bb1 tests: PMKSA cache with multiple stations
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-04 23:01:08 +03:00
Jouni Malinen 2cde175a93 tests: PMKSA cache entry timeout based on Session-Timeout
This verifies that hostapd uses Session-Timeout value from Access-Accept
as the lifetime for the PMKSA cache entries and expires entries both
while the station is disconnected and during an association.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-04 23:01:08 +03:00
Jouni Malinen 8e1fc78e1f tests: PMKSA caching disabled on AP
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-04 23:01:08 +03:00
Jouni Malinen 393869c551 tests: External MAC address change
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-04 16:41:33 +03:00
Jouni Malinen c4a8c173b8 Revert "tests: Skip ap_wpa2_tdls_concurrent_init on failure"
This reverts commit bf700cc3d2. The
concurrent initialization test case is now expected to work again with
the STA entry added early enough to avoid the recently added mac80211
validation step failure.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-10-03 11:53:38 +03:00
Arik Nemtsov 77835ae9dd tests: Verify TDLS responder teardown in encrypted network
Older mac80211 implementations did not set the link identifier
appropriately, resulting in an incorrect teardown packet being sent the
peer. wpa_supplicant adds the FTE containing the MIC field calculated
using the correct link-identifier. This causes a MIC failure on the
other side and the teardown is discarded. Verify this case is fixed by
newer kernel and wpa_supplicant code.

Signed-off-by: Arik Nemtsov <arikx.nemtsov@intel.com>
2014-10-03 11:53:31 +03:00
Jouni Malinen b5db69197a tests: Random MAC addresses while maintaining OUI
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-09-30 00:40:23 +03:00
Jouni Malinen c1d1b6998d tests: Update server and user certificates
The previous versions expired, so need to re-sign these to fix number of
the EAP test cases.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-09-30 00:40:23 +03:00
Jouni Malinen d1fc5736cc tests: FDB entry addition/removal
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-09-29 14:03:15 +03:00
Jouni Malinen 7c33a65671 tests: P2P_PROV_DISC auto
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-09-28 18:56:06 +03:00
Jouni Malinen 746327ca86 tests: P2P service discovery no protocol/match cases
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-09-28 18:44:24 +03:00
Jouni Malinen 06f94fd0e1 tests: Increase P2P persistent group with per-STA PSK coverage
Remove and re-start the persistent group manually to increase test
coverage to include the case of re-configuring the PSK list entries from
a stored persistent group.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-09-28 18:09:53 +03:00
Jouni Malinen 4a7d73d161 tests: Make ap_hs20_random_mac_addr more robust
If the previuous test case used a non-RSN AP and that was left in
cfg80211 scan results, it was possible for ap_hs20_random_mac_addr to
pick that old AP from the previous test and reject to connect through
Hotspot 2.0 mechanisms. Work around this test issue by requesting new
set of scan result at the beginning of the test.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-09-28 17:51:09 +03:00
Jouni Malinen e5a79e3f93 tests: WPS while connected
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-09-28 11:03:48 +03:00
Jouni Malinen 816e3df972 tests: Random MAC address use
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-09-27 20:07:55 +03:00
Jouni Malinen 321c7f6034 tests: Make ap_wps_er_add_enrollee more robust under load
The scan for WPS-AUTH validation may miss a Probe Response frame if the
hostapd process gets blocked under load, e.g., when testing with
parallel-vm.sh.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-09-27 16:17:17 +03:00
Jouni Malinen 377babb205 tests: Fix autogo_bridge to clear autoscan setting
Previously, periodic autoscan could have been left running and that
could result in the following test cases failing in some cases.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-09-27 16:12:41 +03:00
Jouni Malinen 852cb016d2 tests: Make ap_hs20 test cases more robust
Some of the test cases where using INTERWORKING_SELECT internally
without using scan_for_bss like the helper functions did. Add explicit
scan_for_bss calls to make the test cases less likely to fail due to
missing BSSes in scan results. This could cause false failure reports
when runnign under heavy load with parallel-vm.sh.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-09-27 16:12:41 +03:00
Jouni Malinen bbf20ca265 tests: Use TYPE=ONLY scan for scan_for_bss
This avoids unexpected connection attempts in cases a matching network
is enabled and there is no existing connection (e.g., when testing with
ENABLE_NETWORK no-connect option).

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-09-27 16:12:41 +03:00
Jouni Malinen bf700cc3d2 tests: Skip ap_wpa2_tdls_concurrent_init on failure
A mac80211 TDLS validation change ended up breaking test functionality
that was needed for this test case. Instead of reporting this known
issue as a FAIL every time, mark the test as SKIP since the issues is
known and there are no plans of "fixing" it.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-09-27 11:30:56 +03:00
Jouni Malinen 36e7fbce34 tests: PMKSA_FLUSH
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-09-27 10:50:19 +03:00
Jouni Malinen a567aae4a1 tests: Roaming policy change with the bssid parameter
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-09-11 15:59:42 +03:00
Jouni Malinen d885a0ba7c tests: P2P GO netdev in a bridge
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-09-01 16:27:27 +03:00
Jouni Malinen a0fd2ae643 tests: WPS mixed-WPA/WPA2 credential merging
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-08-29 20:25:18 +03:00
Jouni Malinen d6df0d7e62 tests: Verify that sec_dev_type gets reported for P2P peer
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-08-27 16:22:53 +03:00
Jouni Malinen 4b15c3f256 tests: P2P GO channel preference and regulatory rule mismatch
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-08-26 17:57:26 +03:00
Jouni Malinen 9a5cfd7007 tests: No EAP fast session resumption between network blocks
Verify that EAP fast session resumption is skipped if the connection
uses a different network configuration than the last EAP connection.

Signed-off-by: Jouni Malinen <j@w1.fi>
2014-07-26 20:23:08 +03:00
Jouni Malinen 1f41a20c92 tests: P2P vendor specific extensions
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-07-08 15:57:30 +03:00
Jouni Malinen f1a36a53a5 tests: update_identifier in network block
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-07-02 15:51:20 +03:00
Jouni Malinen 8094a0077a tests: Fix wpas_ctrl_country to match the fixed event data
This test case for enforcing the incorrect init=DRIVER instead of
init=CORE for the event due to bug in the event message.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-07-02 13:34:34 +03:00
Jouni Malinen e8e571d7ce tests: SCAN scan_id
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-07-02 12:52:08 +03:00
Jouni Malinen 31424fa732 tests: P2P passphrase length configuration
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-06-22 00:17:18 +03:00
Jouni Malinen 6c080dfab2 tests: EAP-SIM/AKA/AKA' protocol tests
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-06-21 20:34:25 +03:00
Jouni Malinen 72cbc6847b tests: EAP-SIM external_sim error cases
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-06-21 19:43:11 +03:00
Jouni Malinen d8e02214ea tests: EAP-AKA external_sim error cases
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-06-21 11:30:57 +03:00
Jouni Malinen 32747a3eee tests: EAP-SIM/AKA invalid Milenage key configuration
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-06-20 10:59:08 +03:00
Jouni Malinen e4719179cb tests: SA Query rate limiting on burst of unprotected Deauth
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-06-19 20:59:46 +03:00
Jouni Malinen e0534ecf90 tests: EAP-PSK protocol test cases
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-06-18 00:13:56 +03:00
Jouni Malinen 7eb33a8f99 tests: Make concurrent_grpform_while_connecting2 more robust
It was possible for this test case to fail due to PBC overlap that was
detected based on previous test case having used PBC. Make that false
positive less likely to happen by explicitly clearing the scan cache on
dev[1].

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
2014-06-16 17:07:25 +03:00
Jouni Malinen 2eae05f780 tests: EAP protocol test cases
Signed-off-by: Jouni Malinen <j@w1.fi>
2014-06-15 19:01:59 +03:00