Commit graph

3040 commits

Author SHA1 Message Date
Jouni Malinen
cd803b6ccd tests: Clear regulatory Beacon hints more robustly in TDLS test cases
The ap_open_tdls_vht* test cases could leave some pending regulatory
Beacon hints waiting to be cleared during the following test case. This
would result in a failure if the following test case expected specific
regdom event behavior. For example, this caused "ap_open_tdls_vht160
dbus_country" sequence to result in failure in dbus_country. Fix this by
using more robust sequence in clearing regdom state at the end of the
TDLS test cases that have the AP advertising a country code.

Signed-off-by: Jouni Malinen <j@w1.fi>
2018-12-29 17:02:54 +02:00
Jouni Malinen
90eb910ef5 tests: MKA MIB information
Signed-off-by: Jouni Malinen <j@w1.fi>
2018-12-29 16:52:56 +02:00
Jouni Malinen
a2acadf605 tests: MACsec PSK with bridge interface
Signed-off-by: Jouni Malinen <j@w1.fi>
2018-12-29 12:26:52 +02:00
Jouni Malinen
0d09bd0832 tests: Use more robust way to determine MKA is done for MACsec testing
Signed-off-by: Jouni Malinen <j@w1.fi>
2018-12-29 12:18:41 +02:00
Jouni Malinen
344929a9ca tests: MACsec PSK local failures in CP state machine
Signed-off-by: Jouni Malinen <j@w1.fi>
2018-12-27 16:03:46 +02:00
Jouni Malinen
ead573d8a2 tests: MACsec
Add some coverage for MACsec with the macsec_linux driver interface in
wpa_supplicant.

Signed-off-by: Jouni Malinen <j@w1.fi>
2018-12-27 00:42:04 +02:00
Jouni Malinen
93701b4afe tests: Allow TX/RX data test to use different frame length
This is needed for MACsec test cases with a bit shorter MTU.

Signed-off-by: Jouni Malinen <j@w1.fi>
2018-12-24 23:56:25 +02:00
Jouni Malinen
e7b141906b tests: Do not override connectivity test address if no driver info
Not all driver interfaces provide driver status information with the
local address, so skip the override step if the field is not available.
This is needed, e.g., with macsec_linux.

Signed-off-by: Jouni Malinen <j@w1.fi>
2018-12-24 20:31:47 +02:00
Jouni Malinen
345d8b5e91 tests: AP mode and D-Bus StationAdded/StationRemoved signals
Signed-off-by: Jouni Malinen <j@w1.fi>
2018-12-23 17:25:11 +02:00
Johannes Berg
7afbbcd2ed tests: Validate that AP doesn't reflect station frames
Add a new test to check that the AP won't send frames to the client if
it tries to talk to itself.

Note that this fails until the relevant mac80211 patch is merged.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2018-12-23 17:25:11 +02:00
Jouni Malinen
95cd50a1ed tests: Fix AP wait in ap_require_ht and ap_require_ht_limited_rates
These test cases seemed to have copy-paste errors where
wait_enabled=False was forgotten even though there was no additional
steps checking the AP mode startup results. This did not break the
tests, but could have resulted in slowing them down if the STAs did not
find the AP in the first scan.

Signed-off-by: Jouni Malinen <j@w1.fi>
2018-12-23 17:25:11 +02:00
Jouni Malinen
15b7cc5199 tests: HT STBC overrides
Signed-off-by: Jouni Malinen <j@w1.fi>
2018-12-23 17:25:11 +02:00
Sergey Matyukevich
721d8558bc tests: Allow overriding HT STBC capabilities
Signed-off-by: Sergey Matyukevich <sergey.matyukevich.os@quantenna.com>
2018-12-23 17:25:11 +02:00
Jouni Malinen
43d174b8e2 tests: Automatic channel selection, HT scan, and DFS
Signed-off-by: Jouni Malinen <j@w1.fi>
2018-12-23 17:25:11 +02:00
Jouni Malinen
b586054f95 tests: Work around cfg80211 reg.c intersection (country 98) issues
The Linux kernel commit 113f3aaa81bd ("cfg80211: Prevent regulatory
restore during STA disconnect in concurrent interfaces") broke the
regulatory clearing attempt in many test cases since
cfg80211_is_all_idle() is now returning false due to the AP interface
being up and that results in the Country IE -based regulatory
information not getting cleared back to defaults.

Work around this by stopping the AP interface first so that when the
station interface receives the disconnection, there are no other active
interfaces in the system. In addition, wait for REGDOM event for the
Country IE hint after association to avoid disconnection before the
regulatory events have been fully processed.

Signed-off-by: Jouni Malinen <j@w1.fi>
2018-12-23 17:25:11 +02:00
Jouni Malinen
99bc57d0d1 tests: Fix mbo_supp_oper_classes after cfg80211 change
The Linux kernel commit 113f3aaa81bd ("cfg80211: Prevent regulatory
restore during STA disconnect in concurrent interfaces") broke the
regulatory clearing attempt in this test case since
cfg80211_is_all_idle() is now returning false due to the AP interface
being up and that results in the Country IE -based regulatory
information not getting cleared back to defaults.

Work around this by stopping the AP interface first so that when the
station interface receives the disconnection, there are no other active
interfaces in the system. In addition, wait for REGDOM event for the
Country IE hint after association to avoid disconnection before the
regulatory events have been fully processed.

Signed-off-by: Jouni Malinen <j@w1.fi>
2018-12-22 16:13:14 +02:00
Jouni Malinen
2cef6f6e89 tests: Enable dynamic debug from cfg80211/mac80211
These debug logs were lost due to CONFIG_DYNAMIC_DEBUG=y.

Signed-off-by: Jouni Malinen <j@w1.fi>
2018-12-22 00:18:33 +02:00
Jouni Malinen
afd38c9fdc tests: hostapd.vlan with bridge ifname
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2018-12-21 12:02:57 +02:00
Jouni Malinen
9552a7364f tests: DPP_CONFIGURATOR_SIGN without double space
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2018-12-21 12:02:57 +02:00
Jouni Malinen
3a259f073a tests: Be more careful in clearing REGDOM state
cfg80211 regulatory code gets into pretty inconvenient state if it needs
to intersect regulatory domain information from multiple regulations
(country=98). The existing mechanisms in the hwsim test cases are not
able to clear that up for the following test case and this can result in
large number of failures.

It looks like country=98 case is hit frequently in WNM test cases where
a station associates with an AP that advertises a specific country code
and that station is then asked to disconnect before the REGDOM events
have been received. Avoid this by waiting for the REGDOM events for the
init=COUNTRY_IE case before disconnecting.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2018-12-21 00:55:31 +02:00
Jouni Malinen
432c0972ad tests: Connect attempt with transmitting/nontransmitting BSS
This adds some minimal testing for Multi-BSS connection attempts. The
part for nontransmitted BSS is limited since hostapd/mac80211 does not
yet have sufficient support for Multi-BSS in AP mode.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2018-12-20 21:44:33 +02:00
Peng Xu
8d176ae689 tests: Additional Multiple BSSID IE parsing tests
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2018-12-20 21:41:40 +02:00
Jouni Malinen
586826d4f5 tests: Multiple BSSID element in scan results
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2018-12-20 21:41:34 +02:00
Jouni Malinen
7488e0ade6 tests: Multi-AP association
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2018-12-20 12:43:43 +02:00
Mathy Vanhoef
3006241e43 tests: OCI validation in WNM-Sleep Exit frames (OCV)
Signed-off-by: Mathy Vanhoef <Mathy.Vanhoef@cs.kuleuven.be>
2018-12-17 15:50:12 +02:00
Mathy Vanhoef
0059625b77 tests: OCI validation in the AMPE handshake (OCV)
Signed-off-by: Mathy Vanhoef <Mathy.Vanhoef@cs.kuleuven.be>
2018-12-17 15:50:12 +02:00
Mathy Vanhoef
a187bf0161 tests: OCI validation in the FILS handshake (OCV)
Signed-off-by: Mathy Vanhoef <Mathy.Vanhoef@cs.kuleuven.be>
2018-12-17 15:50:12 +02:00
Mathy Vanhoef
870906d5cc tests: OCI validation in SA Query frames (OCV)
Signed-off-by: Mathy Vanhoef <Mathy.Vanhoef@cs.kuleuven.be>
2018-12-17 15:50:12 +02:00
Mathy Vanhoef
e63d8837dd tests: OCI validation in the FT handshake (OCV)
Signed-off-by: Mathy Vanhoef <Mathy.Vanhoef@cs.kuleuven.be>
2018-12-17 15:42:23 +02:00
Mathy Vanhoef
6734ba0c00 tests: OCI validation in the 4-way and group key handshakes (OCV)
Perform detailed tests with OCV enabled, for both the 4-way and group
key handshakes. These tests include establishing a working connection
with OCV enabled, assuring that a STA without OCV enabled can still
connect to a STA with OCV enabled (and vice versa), verifying that
invalid OCI elements get silently ignored, verifying that missing OCI
elements are reported, and so on.

Signed-off-by: Mathy Vanhoef <Mathy.Vanhoef@cs.kuleuven.be>
2018-12-17 15:42:23 +02:00
Mathy Vanhoef
3797b55cfc tests: Enable OCV in the testing builds
Signed-off-by: Mathy Vanhoef <Mathy.Vanhoef@cs.kuleuven.be>
2018-12-17 15:42:23 +02:00
Jouni Malinen
4992582187 tests: Hotspot 2.0 AAA server behavior for SIM provisioning
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2018-12-15 18:01:38 +02:00
Jouni Malinen
30810f5d97 tests: wpa_supplicant config file writing and key_mgmt values
Signed-off-by: Jouni Malinen <j@w1.fi>
2018-12-08 16:27:26 +02:00
Jouni Malinen
3a80672e22 tests: Remove parallel-vm.sh
parallel-vm.py has obsoleted this a long time ago and there is no need
to maintain two scripts for doing more or less the same thing.

Signed-off-by: Jouni Malinen <j@w1.fi>
2018-12-08 15:35:47 +02:00
Jouni Malinen
e4ce86f98b tests: Add dfs_etsi to the long_tests list
Signed-off-by: Jouni Malinen <j@w1.fi>
2018-12-08 15:33:31 +02:00
Jouni Malinen
842c29c173 tests: Hotspot 2.0 connection attempt without PMF
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2018-12-08 14:06:58 +02:00
Jouni Malinen
c8f7a83c65 tests: Fix ap_hs20_deauth_req_without_pmf
Now that hostapd starts mandating PMF for Hotspot 2.0 Release 2
association, this test case needs some more tweaks to work. Hardcode
Hotspot 2.0 Release 1 to be used and disable PMF explicitly.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2018-12-08 14:06:58 +02:00
Jouni Malinen
647c0ed679 tests: Fix ap_hs20_ft with PMF enabled
The Beacon loss event was not reported anymore, so remove that as an
unnecessary step in the test case. In addition, check the key_mgmt
values explicitly.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2018-12-08 14:06:58 +02:00
Jouni Malinen
f40f8860d2 tests: Enable PMF in ap_hs20_unexpected configuration
This is needed to meet the Hotspot 2.0 Release 2 requirement for the
third station that is actually using RSN.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2018-12-08 14:06:58 +02:00
Jouni Malinen
ea57b0bcfe tests: Enable PMF in ap_hs20_external_selection network profile
This is required for Hotspot 2.0 Release 2.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2018-12-08 14:06:58 +02:00
Jouni Malinen
dfd1b69de2 tests: Hotspot 2.0 release number indication
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2018-12-08 14:06:58 +02:00
Jouni Malinen
7436cd366e tests: Update Hotspot 2.0 release number expectation to 3
Match the implementation change to fix the test cases that verified a
specific Hotspot 2.0 release number indication.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2018-12-08 14:06:58 +02:00
Jouni Malinen
4b1ae27974 tests: Connect to WPS AP with NFC connection handover (local failure)
This is a regression test case for a potential NULL pointer
dereferencing fixed in the previous commit.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2018-12-04 20:55:20 +02:00
Jouni Malinen
e49a7199d5 tests: Opportunistic Wireless Encryption association rejection handling
Signed-off-by: Jouni Malinen <j@w1.fi>
2018-12-02 20:42:09 +02:00
Jouni Malinen
d0cd2d1ab2 tests: DPP network addition failure
Signed-off-by: Jouni Malinen <j@w1.fi>
2018-12-02 18:40:06 +02:00
Jouni Malinen
fe7c91f822 tests: DPP and continue listen state
Signed-off-by: Jouni Malinen <j@w1.fi>
2018-12-02 18:40:06 +02:00
Jouni Malinen
88c08a29a2 tests: DPP_BOOTSTRAP_GEN/REMOVE/GET_URI/INFO error cases
Signed-off-by: Jouni Malinen <j@w1.fi>
2018-12-02 18:40:06 +02:00
Jouni Malinen
d0e88871a7 tests: DPP and unknown configurator id
Signed-off-by: Jouni Malinen <j@w1.fi>
2018-12-02 18:40:06 +02:00
Jouni Malinen
24c4200d2e tests: DPP and PKEX with local failure in processing Commit Reveal Req
Signed-off-by: Jouni Malinen <j@w1.fi>
2018-12-02 18:40:06 +02:00
Jouni Malinen
a7758916c6 tests: DPP and PKEX with local failure in processing Exchange Resp
Signed-off-by: Jouni Malinen <j@w1.fi>
2018-12-02 12:44:13 +02:00