Commit graph

3846 commits

Author SHA1 Message Date
Jouni Malinen
9a411882bd tests: setband with band combination
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2020-12-11 19:56:14 +02:00
Jouni Malinen
e4c815a77a tests: Update scan_fail to match implementation change
The function name for adding frequency lists changed, so this test case
needs a matching change to avoid failures.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2020-12-11 19:56:14 +02:00
Johannes Berg
d215f42538 tests: HE: Add a test for wifi generation on 2.4 GHz
This was broken in the kernel in mac80211 for a while, until commit
780a8c9efc65 ("mac80211: do not disable HE if HT is missing on 2.4 GHz")
fixed it.

Add a test for wifi generation on 2.4 GHz in addition to the 5 GHz one.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2020-12-04 12:42:17 +02:00
Janusz Dziedzic
3fd22b6ef4 tests: remotehost: Introduce wait_event()
Allow to run local/remote process like:
 - ubus listen
 - logread -f
 - tail -f
 - wpa_cli
 - hostapd_cli
And next wait for specific event(s).

Signed-off-by: Janusz Dziedzic <janusz.dziedzic@gmail.com>
2020-12-04 12:14:35 +02:00
Janusz Dziedzic
11b3af3dad tests: remotehost: Use correct name
While we start thread use:
 - thread_run
 - therad_stop
 - thread_wait

Signed-off-by: Janusz Dziedzic <janusz.dziedzic@gmail.com>
2020-12-04 12:14:09 +02:00
Andrei Otcheretianski
eac2b65635 tests: Skip dpp_enterprise_tcp tests without OpenSSL
Skip these tests if OpenSSL wasn't loaded, instead of crashing.

Signed-off-by: Andrei Otcheretianski <andrei.otcheretianski@intel.com>
2020-12-04 11:54:27 +02:00
Jouni Malinen
348447c486 tests: Determine number of parallel make jobs automatically
Use nproc (if available) instead of the hardcoded 8 parallel make jobs.

Signed-off-by: Jouni Malinen <j@w1.fi>
2020-12-04 11:49:04 +02:00
Jouni Malinen
0dcfdd5e47 tests: Skip test cases properly if tshark is not available
Instead of trying to process empty results, mark the test case as
skipped if tshark is not available.

Signed-off-by: Jouni Malinen <j@w1.fi>
2020-12-04 11:43:45 +02:00
Thomas Pedersen
95cff14c6f tests: Fix p2p_autogo_pref_chan_not_in_regulatory
Sweden now allows channel 149 in the updated wireless-regdb. Choose
Japan for the negative test instead.

Signed-off-by: Thomas Pedersen <thomas@adapt-ip.com>
2020-12-02 17:25:09 +02:00
Jouni Malinen
67d5328b3c tests: DFS and no available channel after radar detection
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2020-12-02 16:49:46 +02:00
Markus Theil
3806ad73e1 tests: DFS test for mesh
Add a test which uses a DFS channel, waits for CAC afterwards successful
mesh join and then triggers a radar event and checks if the mesh comes
up again on the same device.

Signed-off-by: Markus Theil <markus.theil@tu-ilmenau.de>
2020-12-01 00:37:50 +02:00
Jouni Malinen
1759a8e3f3 tests: WPA2-PSK and supplicant receiving unexpected EAPOL-Key frames
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2020-11-23 21:28:36 +02:00
Jouni Malinen
0ea870324e tests: Use helper functions for PSK ext EAPOL-Key processing
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2020-11-23 21:02:03 +02:00
Jouni Malinen
ff7cae3444 tests: ANQP protection indication
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2020-11-23 20:35:00 +02:00
Jouni Malinen
5027f34a33 tests: Fix test description strings for couple of SAE cases
Remove the extraneous closing parenthesis.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2020-11-16 15:51:05 +02:00
Jouni Malinen
f14df9b56a tests: Prepare for control interface message change
Update ap_wpa2_psk_supp_proto_too_long_gtk_in_group_msg to accept
upcoming change in the parsing validation step that catches the issue.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2020-11-03 21:10:01 +02:00
Jouni Malinen
3b89dbaa7d tests: TDLS with SAE
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2020-11-02 17:40:18 +02:00
Jouni Malinen
2d8a7cf3f5 tests: Update dpp_controller_rx_errors to use the assigned TCP port
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2020-10-21 00:31:01 +03:00
Jouni Malinen
ac835ea092 tests: SAE status code handling
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2020-10-20 00:37:01 +03:00
Jouni Malinen
0747432efd Fix spelling of "unexpected" in messages
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2020-10-16 12:45:26 +03:00
Markus Theil
0be9c232a3 tests: Remove wpas_mesh_open_5ghz_coex
This is in preparation for an implementation change that ends up
contradicting the operations enforced in this test case for mesh coex.

Signed-off-by: Markus Theil <markus.theil@tu-ilmenau.de>
2020-10-14 12:44:15 +03:00
Masashi Honma
267d619798 tests: Fix mesh_open_vht_160 false negative by using common finalizer
mesh_open_vht_160 might fail with this message:

---------------
wlan0: Country code not reset back to 00: is ZA
wlan0: Country code cleared back to 00
---------------

This patch fixes the issue.

Signed-off-by: Masashi Honma <masashi.honma@gmail.com>
2020-10-12 11:18:53 +03:00
Masashi Honma
fd59cc8924 tests: Fix wpas_mesh_open_vht_80p80 false negative by using common finalizer
wpas_mesh_open_vht_80p80 might fail with this message:

---------------
wlan0: Country code not reset back to 00: is US
wlan0: Country code cleared back to 00
---------------

This patch fixes the issue.

Signed-off-by: Masashi Honma <masashi.honma@gmail.com>
2020-10-12 11:18:46 +03:00
Masashi Honma
54830a2445 tests: Fix wpas_mesh_open_vht20 false negative by using common finalizer
wpas_mesh_open_vht20 might fails with this message:

---------------
wlan0: Country code not reset back to 00: is US
wlan0: Country code cleared back to 00
---------------

This patch fixes the issue.

Signed-off-by: Masashi Honma <masashi.honma@gmail.com>
2020-10-12 11:18:39 +03:00
Masashi Honma
91de752d17 tests: Fix wpas_mesh_open_vht40 false negative by using common finalizer
wpas_mesh_open_vht40 might fail with this message:

---------------
wlan0: Country code not reset back to 00: is US
wlan0: Country code cleared back to 00
---------------

This patch fixes the issue.

Signed-off-by: Masashi Honma <masashi.honma@gmail.com>
2020-10-12 11:18:32 +03:00
Masashi Honma
5eea042220 tests: Fix wpas_mesh_open_ht40 false negative by using common finalizer
wpas_mesh_open_ht40 might fail with this message:

---------------
wlan0: Country code not reset back to 00: is US
wlan0: Country code cleared back to 00
---------------

This patch fixes the issue.

Signed-off-by: Masashi Honma <masashi.honma@gmail.com>
2020-10-12 11:18:25 +03:00
Masashi Honma
0bea288fbe tests: Fix wpas_mesh_open_5ghz false negative by using common finalizer
wpas_mesh_open_5ghz might fail with this message:

---------------
wlan0: Country code not reset back to 00: is US
wlan0: Country code cleared back to 00
---------------

This patch fixes the issue.

Signed-off-by: Masashi Honma <masashi.honma@gmail.com>
2020-10-12 11:18:15 +03:00
Masashi Honma
ee03056a62 tests: Fix mesh_secure_ocv_mix_legacy false negative by using common finalizer
mesh_secure_ocv_mix_legacy might fail with this message:

---------------
wlan0: Country code not reset back to 00: is AZ
wlan0: Country code cleared back to 00
---------------

This patch fixes the issue.

Signed-off-by: Masashi Honma <masashi.honma@gmail.com>
2020-10-12 11:17:52 +03:00
Johannes Berg
5c7a048e45 tests: build.sh: Avoid copying .config if identical
If the .config file is already identical, avoid copying it even if -f
was specified; this improves build time if nothing has changed.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2020-10-11 19:42:52 +03:00
Johannes Berg
e7c11ad249 tests: build.sh: Remove 'make clean' steps
Since the build artifacts are now landing in distinct directories, we
don't need to 'make clean' and save some rebuild time.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2020-10-11 19:41:41 +03:00
Brian Norris
07aac648a1 tests: dbus: Add test for RemoveAllNetworks while connected
This likely passes today (at least without ASAN), but without the next
commit, it trips up a use-after-free bug, which ASAN can catch.

So consider this a regression test.

Signed-off-by: Brian Norris <briannorris@chromium.org>
2020-10-10 20:36:18 +03:00
Brian Norris
4b0bf0ec6e tests: run-tests: Do not use sudo if already root
Among other things, sudo can disrupt environment variables that a caller
provides.

Signed-off-by: Brian Norris <briannorris@chromium.org>
2020-10-10 20:33:00 +03:00
Brian Norris
4dbba548ae tests: Skip busctl tests when not available
Signed-off-by: Brian Norris <briannorris@chromium.org>
2020-10-10 20:31:43 +03:00
Jouni Malinen
48aebcc31b tests: D-Bus Roam
Signed-off-by: Jouni Malinen <j@w1.fi>
2020-10-10 20:15:34 +03:00
Jouni Malinen
5653301409 tests: Prepare ap_blacklist_all for implementation change
The blacklist design will be modified in the following commits and that
would result in this validation step based on the older implementation
starting to fail. Remove this check to avoid such testing failures.

Signed-off-by: Jouni Malinen <j@w1.fi>
2020-10-10 18:34:59 +03:00
Jouni Malinen
fb0c693d5f tests: bgscan parameter update
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2020-10-09 16:50:36 +03:00
Jouni Malinen
b2a1424659 tests: Empty network profile parameters will be valid
Remove this part of the dbus_network test case since it would be causing
failures after wpa_supplicant is modified to accept empty strings
through D-Bus.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2020-10-09 16:50:36 +03:00
Janusz Dziedzic
c203897a88 tests: remote: Allow passing of parameters with monitor interface
This is mainly for standalone monitor in case we know and would like to
setup specific monitor configuration.

-m monitor:<chan>,<bw>, <cf1>, <cf2>:...

For example:
-m monitor:1,40,3,0
-m e4300:1,40,3,0:11,40,9,0

This also supports monitor with multiple interfaces (one pcap).

Signed-off-by: Janusz Dziedzic <janusz.dziedzic@gmail.com>
2020-10-09 11:21:05 +03:00
Janusz Dziedzic
14d28a655a tests: remotehost add execute_stop()
Before we have to kill an application we start in the thread - in most
cases using killall and sometimes kill other applicantions, e.g., tcpdump,
iper, iperf3, tshark.

With this patch we are able to stop/kill a single application/thread
instead, based on the pid file.

Signed-off-by: Janusz Dziedzic <janusz.dziedzic@gmail.com>
2020-10-09 11:15:42 +03:00
Janusz Dziedzic
fed855d5dd tests: remote host stderr workaround
In case we are using ssh MUX (which speed up a lot test execution) with
remotehost we could hit cases where ssh will hang up. This depends on
different ssh versions and remotehost implementation.

stderr as a tmpfile fixes this problem.

Signed-off-by: Janusz Dziedzic <janusz.dziedzic@gmail.com>
2020-10-09 11:13:48 +03:00
Jouni Malinen
e7b27637a5 tests: P2P with 6 GHz disabled
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2020-10-08 23:29:50 +03:00
Jouni Malinen
fd9fe8bc12 tests: OCV and missing PMF or OCI
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2020-10-08 23:07:43 +03:00
Jouni Malinen
fe27c464fd tests: DPP-CHIRP-RX reception
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2020-10-07 21:31:46 +03:00
Jouni Malinen
d049aeb0c6 tests: DPP with hostapd as configurator requiring fragmentation
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2020-10-06 23:37:17 +03:00
Jouni Malinen
de250a1984 tests: WPA2-PSK AP with PMF association comeback (WPS)
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2020-10-06 22:46:26 +03:00
Jouni Malinen
ce637df76c tests: P2P autonomous GO and interface being removed
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2020-10-01 15:48:05 +03:00
Jouni Malinen
440a5e235b tests: DPP PFS fallback with SAE enabled
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2020-09-23 23:09:32 +03:00
Jouni Malinen
db599dbe99 tests: SAE-PK with invalid password on AP
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2020-09-11 15:53:56 +03:00
Jouni Malinen
0f84a56219 tests: More explicit TLS version enabling in version tests
This is needed to allow the test cases to work on systems using
secpolicy=2 default (e.g., Ubuntu 20.04).

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2020-09-08 19:32:36 +03:00
Jouni Malinen
255e29fcae tests: DPP Controller in hostapd
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
2020-08-25 16:11:43 +03:00