]> git.ipfire.org Git - thirdparty/hostap.git/log
thirdparty/hostap.git
5 years agobsd: Fix a typo in error message
Ryo ONODERA [Sat, 13 Apr 2019 00:50:56 +0000 (09:50 +0900)] 
bsd: Fix a typo in error message

When SIOCG80211 failed, show error message with SIOCG80211
instead of SIOCS80211.

Signed-off-by: Ryo ONODERA <ryo@tetera.org>
5 years agotests: Fix trace-cmd recording with python3
Johannes Berg [Fri, 12 Apr 2019 11:20:19 +0000 (13:20 +0200)] 
tests: Fix trace-cmd recording with python3

The change to python3 broke trace-cmd recording, two
strings need to be bytes instead. Fix that.

Also add a flush() that seems to be needed now.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
5 years agoRemove unnecessary copying of SSID and BSSID for external_auth
Jouni Malinen [Fri, 12 Apr 2019 17:38:08 +0000 (20:38 +0300)] 
Remove unnecessary copying of SSID and BSSID for external_auth

The external authentication command and event does not need to copy the
BSSID/SSID values into struct external_auth since those values are used
before returning from the call. Simplify this by using const u8 * to
external data instead of the array with a copy of the external data.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agohostapd: Support external authentication offload in AP mode
Srinivas Dasari [Mon, 18 Mar 2019 09:34:04 +0000 (15:04 +0530)] 
hostapd: Support external authentication offload in AP mode

Extend commit 5ff39c1380d9 ("SAE: Support external authentication
offload for driver-SME cases") to support external authentication
with drivers that implement AP SME by notifying the status of
SAE authentication to the driver after SAE handshake as the
driver acts as a pass through for the SAE Authentication frames.

Signed-off-by: Srinivas Dasari <dasaris@codeaurora.org>
5 years agonl80211: External authentication in driver-based AP SME mode
Srinivas Dasari [Mon, 25 Feb 2019 12:22:05 +0000 (17:52 +0530)] 
nl80211: External authentication in driver-based AP SME mode

This extends driver interface to nl80211 by introducing the following
changes,
1. Register for Authenication frames in driver-based AP SME mode.
2. Advertise NL80211_ATTR_EXTERNAL_AUTH_SUPPORT in set_ap when
   offloaded SAE authentication is supported.
3. Extend the NL80211_CMD_EXTERNAL_AUTH interface to also send PMKID
   so that the drivers can respond to the PMKSA cached connection
   attempts from the stations avoiding the need to contact user space
   for all PMKID-based connections.
4. Send external auth status to driver only if it is a driver based
   SME solution.

Signed-off-by: Srinivas Dasari <dasaris@codeaurora.org>
5 years agoReset beacon_set_done on disabling interface
nakul kachhwaha [Wed, 3 Apr 2019 07:02:59 +0000 (12:32 +0530)] 
Reset beacon_set_done on disabling interface

beacon_set_done did not get reset to zero on disabling interface using
DISABLE control interface command and the subsequent ENABLE command will
caused configuration of Beacon/Probe Response/Association Response frame
IEs twice. The unnecessary two step configuration can be avoided by
resetting beacon_set_done on DISABLE so that ENABLE can bring up the
interface in a single step with fully updated IEs.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoEAP-pwd: Get rid of unnecessary allocation of temporary buffer
Jouni Malinen [Fri, 5 Apr 2019 09:45:16 +0000 (12:45 +0300)] 
EAP-pwd: Get rid of unnecessary allocation of temporary buffer

Binary presentations of element and scalar can be written directly to
the allocated commit message buffer instead of having to first write
them into temporary buffers just to copy them to the actual message
buffer.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoEAP-pwd: Enforce 1 < rand,mask < r and rand+mask mod r > 1
Jouni Malinen [Fri, 5 Apr 2019 09:37:21 +0000 (12:37 +0300)] 
EAP-pwd: Enforce 1 < rand,mask < r and rand+mask mod r > 1

RFC 5931 has these conditions as MUST requirements, so better follow
them explicitly even if the rand,mask == 0 or rand+mask == 0 or 1 cases
are very unlikely to occur in practice while generating random values
locally.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agotests: EAP-pwd protocol tests for invalid EAP-pwd-Commit
Jouni Malinen [Tue, 2 Apr 2019 19:12:53 +0000 (22:12 +0300)] 
tests: EAP-pwd protocol tests for invalid EAP-pwd-Commit

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agotests: SAE commit invalid scalar/element
Jouni Malinen [Tue, 2 Apr 2019 10:36:58 +0000 (13:36 +0300)] 
tests: SAE commit invalid scalar/element

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agotests: SAE and confirm after invalid commit
Jouni Malinen [Wed, 6 Mar 2019 01:02:21 +0000 (03:02 +0200)] 
tests: SAE and confirm after invalid commit

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agotests: Module tests for const_time_*() functions
Jouni Malinen [Fri, 1 Mar 2019 11:24:48 +0000 (13:24 +0200)] 
tests: Module tests for const_time_*() functions

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoEAP-pwd: Check element x,y coordinates explicitly
Jouni Malinen [Thu, 4 Apr 2019 23:12:50 +0000 (02:12 +0300)] 
EAP-pwd: Check element x,y coordinates explicitly

This adds an explicit check for 0 < x,y < prime based on RFC 5931,
2.8.5.2.2 requirement. The earlier checks might have covered this
implicitly, but it is safer to avoid any dependency on implicit checks
and specific crypto library behavior. (CVE-2019-9498 and CVE-2019-9499)

Furthermore, this moves the EAP-pwd element and scalar parsing and
validation steps into shared helper functions so that there is no need
to maintain two separate copies of this common functionality between the
server and peer implementations.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoEAP-pwd client: Verify received scalar and element
Mathy Vanhoef [Sun, 31 Mar 2019 15:43:44 +0000 (17:43 +0200)] 
EAP-pwd client: Verify received scalar and element

When processing an EAP-pwd Commit frame, the server's scalar and element
(elliptic curve point) were not validated. This allowed an adversary to
bypass authentication, and act as a rogue Access Point (AP) if the
crypto implementation did not verify the validity of the EC point.

Fix this vulnerability by assuring the received scalar lies within the
valid range, and by checking that the received element is not the point
at infinity and lies on the elliptic curve being used. (CVE-2019-9499)

The vulnerability is only exploitable if OpenSSL version 1.0.2 or lower
is used, or if LibreSSL or wolfssl is used. Newer versions of OpenSSL
(and also BoringSSL) implicitly validate the elliptic curve point in
EC_POINT_set_affine_coordinates_GFp(), preventing the attack.

Signed-off-by: Mathy Vanhoef <mathy.vanhoef@nyu.edu>
5 years agoEAP-pwd server: Detect reflection attacks
Mathy Vanhoef [Sun, 31 Mar 2019 15:26:01 +0000 (17:26 +0200)] 
EAP-pwd server: Detect reflection attacks

When processing an EAP-pwd Commit frame, verify that the peer's scalar
and elliptic curve element differ from the one sent by the server. This
prevents reflection attacks where the adversary reflects the scalar and
element sent by the server. (CVE-2019-9497)

The vulnerability allows an adversary to complete the EAP-pwd handshake
as any user. However, the adversary does not learn the negotiated
session key, meaning the subsequent 4-way handshake would fail. As a
result, this cannot be abused to bypass authentication unless EAP-pwd is
used in non-WLAN cases without any following key exchange that would
require the attacker to learn the MSK.

Signed-off-by: Mathy Vanhoef <mathy.vanhoef@nyu.edu>
5 years agoEAP-pwd server: Verify received scalar and element
Mathy Vanhoef [Sun, 31 Mar 2019 15:13:06 +0000 (17:13 +0200)] 
EAP-pwd server: Verify received scalar and element

When processing an EAP-pwd Commit frame, the peer's scalar and element
(elliptic curve point) were not validated. This allowed an adversary to
bypass authentication, and impersonate any user if the crypto
implementation did not verify the validity of the EC point.

Fix this vulnerability by assuring the received scalar lies within the
valid range, and by checking that the received element is not the point
at infinity and lies on the elliptic curve being used. (CVE-2019-9498)

The vulnerability is only exploitable if OpenSSL version 1.0.2 or lower
is used, or if LibreSSL or wolfssl is used. Newer versions of OpenSSL
(and also BoringSSL) implicitly validate the elliptic curve point in
EC_POINT_set_affine_coordinates_GFp(), preventing the attack.

Signed-off-by: Mathy Vanhoef <mathy.vanhoef@nyu.edu>
5 years agoSAE: Fix confirm message validation in error cases
Jouni Malinen [Tue, 5 Mar 2019 21:43:25 +0000 (23:43 +0200)] 
SAE: Fix confirm message validation in error cases

Explicitly verify that own and peer commit scalar/element are available
when trying to check SAE confirm message. It could have been possible to
hit a NULL pointer dereference if the peer element could not have been
parsed. (CVE-2019-9496)

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoSAE: Use constant time operations in sae_test_pwd_seed_ffc()
Jouni Malinen [Sat, 2 Mar 2019 14:05:56 +0000 (16:05 +0200)] 
SAE: Use constant time operations in sae_test_pwd_seed_ffc()

Try to avoid showing externally visible timing or memory access
differences regardless of whether the derived pwd-value is smaller than
the group prime.

This is related to CVE-2019-9494.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoSAE: Use const_time selection for PWE in FFC
Jouni Malinen [Sat, 2 Mar 2019 10:45:33 +0000 (12:45 +0200)] 
SAE: Use const_time selection for PWE in FFC

This is an initial step towards making the FFC case use strictly
constant time operations similarly to the ECC case.
sae_test_pwd_seed_ffc() does not yet have constant time behavior,
though.

This is related to CVE-2019-9494.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoSAE: Mask timing of MODP groups 22, 23, 24
Jouni Malinen [Sat, 2 Mar 2019 10:24:09 +0000 (12:24 +0200)] 
SAE: Mask timing of MODP groups 22, 23, 24

These groups have significant probability of coming up with pwd-value
that is equal or greater than the prime and as such, need for going
through the PWE derivation loop multiple times. This can result in
sufficient timing different to allow an external observer to determine
how many rounds are needed and that can leak information about the used
password.

Force at least 40 loop rounds for these MODP groups similarly to the ECC
group design to mask timing. This behavior is not described in IEEE Std
802.11-2016 for SAE, but it does not result in different values (i.e.,
only different timing), so such implementation specific countermeasures
can be done without breaking interoperability with other implementation.

Note: These MODP groups 22, 23, and 24 are not considered sufficiently
strong to be used with SAE (or more or less anything else). As such,
they should never be enabled in runtime configuration for any production
use cases. These changes to introduce additional protection to mask
timing is only for completeness of implementation and not an indication
that these groups should be used.

This is related to CVE-2019-9494.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoSAE: Avoid branches in is_quadratic_residue_blind()
Jouni Malinen [Tue, 26 Feb 2019 17:34:38 +0000 (19:34 +0200)] 
SAE: Avoid branches in is_quadratic_residue_blind()

Make the non-failure path in the function proceed without branches based
on r_odd and in constant time to minimize risk of observable differences
in timing or cache use. (CVE-2019-9494)

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoSAE: Minimize timing differences in PWE derivation
Jouni Malinen [Tue, 26 Feb 2019 11:05:09 +0000 (13:05 +0200)] 
SAE: Minimize timing differences in PWE derivation

The QR test result can provide information about the password to an
attacker, so try to minimize differences in how the
sae_test_pwd_seed_ecc() result is used. (CVE-2019-9494)

Use heap memory for the dummy password to allow the same password length
to be used even with long passwords.

Use constant time selection functions to track the real vs. dummy
variables so that the exact same operations can be performed for both QR
test results.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoEAP-pwd: Use constant time and memory access for finding the PWE
Jouni Malinen [Tue, 26 Feb 2019 09:59:45 +0000 (11:59 +0200)] 
EAP-pwd: Use constant time and memory access for finding the PWE

This algorithm could leak information to external observers in form of
timing differences or memory access patterns (cache use). While the
previous implementation had protection against the most visible timing
differences (looping 40 rounds and masking the legendre operation), it
did not protect against memory access patterns between the two possible
code paths in the masking operations. That might be sufficient to allow
an unprivileged process running on the same device to be able to
determine which path is being executed through a cache attack and based
on that, determine information about the used password.

Convert the PWE finding loop to use constant time functions and
identical memory access path without different branches for the QR/QNR
cases to minimize possible side-channel information similarly to the
changes done for SAE authentication. (CVE-2019-9495)

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoOpenSSL: Use constant time selection for crypto_bignum_legendre()
Jouni Malinen [Thu, 7 Mar 2019 22:24:12 +0000 (00:24 +0200)] 
OpenSSL: Use constant time selection for crypto_bignum_legendre()

Get rid of the branches that depend on the result of the Legendre
operation. This is needed to avoid leaking information about different
temporary results in blinding mechanisms.

This is related to CVE-2019-9494 and CVE-2019-9495.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoAdd helper functions for constant time operations
Jouni Malinen [Wed, 27 Feb 2019 16:38:30 +0000 (18:38 +0200)] 
Add helper functions for constant time operations

These functions can be used to help implement constant time operations
for various cryptographic operations that must minimize externally
observable differences in processing (both in timing and also in
internal cache use, etc.).

This is related to CVE-2019-9494 and CVE-2019-9495.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoOpenSSL: Use constant time operations for private bignums
Jouni Malinen [Tue, 26 Feb 2019 09:43:03 +0000 (11:43 +0200)] 
OpenSSL: Use constant time operations for private bignums

This helps in reducing measurable timing differences in operations
involving private information. BoringSSL has removed BN_FLG_CONSTTIME
and expects specific constant time functions to be called instead, so a
bit different approach is needed depending on which library is used.

The main operation that needs protection against side channel attacks is
BN_mod_exp() that depends on private keys (the public key validation
step in crypto_dh_derive_secret() is an exception that can use the
faster version since it does not depend on private keys).

crypto_bignum_div() is currently used only in SAE FFC case with not
safe-prime groups and only with values that do not depend on private
keys, so it is not critical to protect it.

crypto_bignum_inverse() is currently used only in SAE FFC PWE
derivation. The additional protection here is targeting only OpenSSL.
BoringSSL may need conversion to using BN_mod_inverse_blinded().

This is related to CVE-2019-9494 and CVE-2019-9495.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agotests: Test cases for X.509 certificate checking
Jouni Malinen [Tue, 9 Apr 2019 10:22:57 +0000 (13:22 +0300)] 
tests: Test cases for X.509 certificate checking

This makes it easier to test various X.509 certificate validation steps
with the server certificate being generated and signed using pyOpenSSL
dynamically.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoExtend domain_match and domain_suffix_match to allow list of values
Jouni Malinen [Tue, 9 Apr 2019 13:18:19 +0000 (16:18 +0300)] 
Extend domain_match and domain_suffix_match to allow list of values

These wpa_supplicant network profile parameters could be used to specify
a single match string that would be used against the dNSName items in
subjectAltName or CN. There may be use cases where more than one
alternative match string would be useful, so extend these to allow a
semicolon delimited list of values to be used (e.g.,
"example.org;example.com"). If any of the specified values matches any
of the dNSName/CN values in the server certificate, consider the
certificate as meeting this requirement.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agowolfSSL: Fix dNSName matching with domain_match and domain_suffix_match
Jouni Malinen [Tue, 9 Apr 2019 13:22:13 +0000 (16:22 +0300)] 
wolfSSL: Fix dNSName matching with domain_match and domain_suffix_match

Incorrect gen->type value was used to check whether subjectAltName
contained dNSName entries. This resulted in all domain_match and
domain_suffix_match entries failing to find a match and rejecting the
server certificate. Fix this by checking against the correct type
definition for dNSName.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agotests: Fix build without CONFIG_SAE
Jouni Malinen [Tue, 9 Apr 2019 13:17:25 +0000 (16:17 +0300)] 
tests: Fix build without CONFIG_SAE

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agotests: ERP enabled on RADIUS server and peer and no wildcard user
Jouni Malinen [Mon, 8 Apr 2019 21:12:35 +0000 (00:12 +0300)] 
tests: ERP enabled on RADIUS server and peer and no wildcard user

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoRADIUS server: Accept ERP keyName-NAI as user identity
Jouni Malinen [Mon, 8 Apr 2019 21:10:20 +0000 (00:10 +0300)] 
RADIUS server: Accept ERP keyName-NAI as user identity

Previously the EAP user database had to include a wildcard entry for ERP
to work since the keyName-NAI as User-Name in Access-Request would not
be recognized without such wildcard entry (that could point to any EAP
method). This is not ideal, so add a separate check to allow any stored
ERP keyName-NAI to be used for ERP without any requirement for the EAP
user database to contain a matching entry.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agotests: scan_multi_bssid_check_ie to allow for Multi BSSID Index IE
Jouni Malinen [Mon, 8 Apr 2019 20:44:45 +0000 (23:44 +0300)] 
tests: scan_multi_bssid_check_ie to allow for Multi BSSID Index IE

cfg80211 was modified to allow the Multiple BSSID Index element to be
included in the IEs for a nontransmitted BSS. Update the validation step
in this test case to allow that different with the IEs in the Beacon
frame (transmitted BSS).

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoFix a typo in the Multiple BSSID Index element ID define
Jouni Malinen [Mon, 8 Apr 2019 20:42:12 +0000 (23:42 +0300)] 
Fix a typo in the Multiple BSSID Index element ID define

This was not used anywhere, so just rename the define to fix the typo.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoDPP: Fix a regression in non-DPP, non-OpenSSL builds
Jouni Malinen [Mon, 8 Apr 2019 15:07:28 +0000 (18:07 +0300)] 
DPP: Fix a regression in non-DPP, non-OpenSSL builds

Inclusion of common/dpp.h into hostapd/main.c brought in an undesired
unconditional dependency on OpenSSL header files even for builds where
DPP is not enabled. Fix this by making the dpp.h contents, and in
particular the inclusion of openssl/x509.h, conditional on CONFIG_DPP.

Fixes: 87d8435cf9fd ("DPP: Common configurator/bootstrapping data management")
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoSAE: Reject unsuitable groups based on REVmd changes
Jouni Malinen [Mon, 8 Apr 2019 15:01:07 +0000 (18:01 +0300)] 
SAE: Reject unsuitable groups based on REVmd changes

The rules defining which DH groups are suitable for SAE use were
accepted into IEEE 802.11 REVmd based on this document:
https://mentor.ieee.org/802.11/dcn/19/11-19-0387-02-000m-addressing-some-sae-comments.docx

Enforce those rules in production builds of wpa_supplicant and hostapd.
CONFIG_TESTING_OPTIONS=y builds can still be used to select any o the
implemented groups to maintain testing coverage.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agotests: Change most SAE test cases to use suitable groups
Jouni Malinen [Mon, 8 Apr 2019 14:59:17 +0000 (17:59 +0300)] 
tests: Change most SAE test cases to use suitable groups

Reduce testing dependency on the unsuitable groups so that a test case
against a production build would not fail the test case unnecessarily.
This is in preparation of making production builds
(CONFIG_TESTING_OPTIONS not defined) of wpa_supplicant hostapd disable
all DH groups that have been indicated as being unsuitable.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoAP: Avoid NULL use with snprintf string
Andrei Otcheretianski [Wed, 3 Apr 2019 15:17:16 +0000 (18:17 +0300)] 
AP: Avoid NULL use with snprintf string

identity_buf may be NULL here. Handle this case explicitly by printing
"N/A" instead relying on snprintf converting this to "(null)" or some
other value based on unexpected NULL pointer.

Signed-off-by: Andrei Otcheretianski <andrei.otcheretianski@intel.com>
5 years agotests: Skip DPP configuration test
Andrei Otcheretianski [Wed, 3 Apr 2019 15:17:15 +0000 (18:17 +0300)] 
tests: Skip DPP configuration test

Skip wpas_config_file_key_mgmt if DPP is not supported.

Signed-off-by: Andrei Otcheretianski <andrei.otcheretianski@intel.com>
5 years agoscan: Use normal scans after connection failure
Ilan Peer [Wed, 3 Apr 2019 15:17:13 +0000 (18:17 +0300)] 
scan: Use normal scans after connection failure

In case of connection attempt failure, set 'normal_scans'
to zero, as otherwise it is possible that scheduled scan
would be used and not normal scan, which might delay the
next connection attempt.

Signed-off-by: Ilan Peer <ilan.peer@intel.com>
5 years agotests: Flush correct iface in P2PS stale group removal tests
Andrei Otcheretianski [Wed, 3 Apr 2019 15:17:17 +0000 (18:17 +0300)] 
tests: Flush correct iface in P2PS stale group removal tests

FLUSH should be done on P2P device interface, otherwise the networks are
not removed. Fix that.

Signed-off-by: Andrei Otcheretianski <andrei.otcheretianski@intel.com>
5 years agohostapd: Reduce minimum beacon interval from 15 to 10 TUs
Brendan Jackman [Fri, 5 Apr 2019 12:36:42 +0000 (12:36 +0000)] 
hostapd: Reduce minimum beacon interval from 15 to 10 TUs

Very short beacon intervals can be useful for certain scenarios such
as minimising association time on PBSSs. Linux supports a minimum of
10[1] so let's reduce the minimum to match that.

[1] https://elixir.bootlin.com/linux/latest/ident/cfg80211_validate_beacon_int

Signed-off-by: Brendan Jackman <brendan.jackman@bluwireless.co.uk>
5 years agoOWE: Fix a possible memory leak on error path
Ilan Peer [Wed, 3 Apr 2019 12:16:15 +0000 (15:16 +0300)] 
OWE: Fix a possible memory leak on error path

Properly handle the case where OWE IE is allocated, but
there is no space left to add it in the WPA IE buffer.

Signed-off-by: Ilan Peer <ilan.peer@intel.com>
5 years agocrypto: Fix unreachable code in tls_prf_sha1_md5()
Ilan Peer [Wed, 3 Apr 2019 12:16:14 +0000 (15:16 +0300)] 
crypto: Fix unreachable code in tls_prf_sha1_md5()

While commit 1c156e783d35 ("Fixed tls_prf() to handle keys with
odd length") added support for keys with odd length, the function
never reached this code as the function would return earlier in
case the key length was odd. Fix this by removing the first check
for the key length.

Signed-off-by: Ilan Peer <ilan.peer@intel.com>
5 years agotests: ERP/FILS with external hostapd process as RADIUS server
Jouni Malinen [Sat, 6 Apr 2019 13:47:38 +0000 (16:47 +0300)] 
tests: ERP/FILS with external hostapd process as RADIUS server

Signed-off-by: Jouni Malinen <j@w1.fi>
5 years agotests: SAE test vector from IEEE P802.11-REVmd/D2.1, Annex J.10
Jouni Malinen [Sat, 6 Apr 2019 10:26:15 +0000 (13:26 +0300)] 
tests: SAE test vector from IEEE P802.11-REVmd/D2.1, Annex J.10

Signed-off-by: Jouni Malinen <j@w1.fi>
5 years agoAdd a QCA vendor attribute to carry the reason for roaming
Sunil Dutt [Fri, 29 Mar 2019 12:47:53 +0000 (18:17 +0530)] 
Add a QCA vendor attribute to carry the reason for roaming

This commit introduces an attribute
QCA_WLAN_VENDOR_ATTR_ROAM_AUTH_REASON to carry the roam reason code
through QCA_NL80211_VENDOR_SUBCMD_KEY_MGMT_ROAM_AUTH event.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agonl80211: Add SAE, FT-SAE, FT-EAP-SHA384 AKMs in connect request
Ankita Bajaj [Mon, 1 Apr 2019 10:18:41 +0000 (15:48 +0530)] 
nl80211: Add SAE, FT-SAE, FT-EAP-SHA384 AKMs in connect request

This is needed for full MAC drivers that use NL80211_CMD_CONNECT
for issuing connect request.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoP2P: Enable HE for both 2G and 5G bands
Peng Xu [Thu, 4 Apr 2019 23:03:20 +0000 (16:03 -0700)] 
P2P: Enable HE for both 2G and 5G bands

Previously HE was only enabled for a 2G P2P GO. This change enables HE
for both 2G and 5G P2P GO.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoMBO: Update connect params with new MBO attributes to driver
Ankita Bajaj [Tue, 2 Apr 2019 09:02:50 +0000 (14:32 +0530)] 
MBO: Update connect params with new MBO attributes to driver

MBO attributes Non-preferred channel list and Cellular capabilities are
updated using WNM-Notification Request frame to the current connected
BSS. These same attributes need to be added in the (Re)Association
Request frame sent by the station when roaming, including the case where
the driver/firmware takes care of SME/MLME operations during roaming, so
we need to update the MBO IE to the driver.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoMBO: Always include Non-preferred Channel Report attribute in AssocReq
Ankita Bajaj [Fri, 5 Apr 2019 09:07:40 +0000 (14:37 +0530)] 
MBO: Always include Non-preferred Channel Report attribute in AssocReq

Include the Non-preferred Channel Report attribute in (Re)Association
Request frames even when the MBO STA has no non-preferred channels in
any operating classes. In case of no non-preferred channels the
attribute length field shall be set to zero and the Operating Class,
Channel List, Preference and Reason Code fields shall not be included.
This indicates to the MBO AP that the MBO STA has no non-preferred
channels access all supported operating classes.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoDPP: Move GAS encapsulation into dpp_build_conf_req()
Jouni Malinen [Wed, 3 Apr 2019 16:09:59 +0000 (19:09 +0300)] 
DPP: Move GAS encapsulation into dpp_build_conf_req()

Avoid duplicated code in each user of dpp_build_conf_req() by moving the
common encapsulation case into this helper function.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoSAE: Fix commit message override with external authentication
Jouni Malinen [Fri, 29 Mar 2019 21:04:35 +0000 (23:04 +0200)] 
SAE: Fix commit message override with external authentication

Do not add duplicate Transaction Sequence and Status Code fields when
using test functionality to override SAE commit message.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agotests: sigma_dut controlled AP with PSK, SAE, FT
Jouni Malinen [Thu, 28 Mar 2019 20:09:45 +0000 (22:09 +0200)] 
tests: sigma_dut controlled AP with PSK, SAE, FT

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoPrefer FT-SAE over FT-PSK if both are enabled
Jouni Malinen [Thu, 28 Mar 2019 01:27:35 +0000 (03:27 +0200)] 
Prefer FT-SAE over FT-PSK if both are enabled

FT-SAE is considered stronger than FT-PSK, so prefer it over FT-PSK
similarly to how SAE is preferred over WPA-PSK.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoAdd more debug prints on suite selector selection
Jouni Malinen [Thu, 28 Mar 2019 00:58:00 +0000 (02:58 +0200)] 
Add more debug prints on suite selector selection

This makes it a bit easier to figure out why wpa_supplicant selects a
specific cipher/AKM for association.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agotests: WPA2-EAP-FT with SHA384 using REASSOCIATE
Jouni Malinen [Wed, 27 Mar 2019 23:12:59 +0000 (01:12 +0200)] 
tests: WPA2-EAP-FT with SHA384 using REASSOCIATE

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoSuite B: Prefer FT-EAP-SHA384 over WPA-EAP-SUITE-B-192
Jouni Malinen [Wed, 27 Mar 2019 23:13:57 +0000 (01:13 +0200)] 
Suite B: Prefer FT-EAP-SHA384 over WPA-EAP-SUITE-B-192

If both of these AKMs are enabled in the wpa_supplicant network profile
and the target AP advertises support for both, prefer the FT version
over the non-FT version to allow FT to be used.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agotests: WPA2-FT-SAE AP and PMKSA caching for initial MD association
Jouni Malinen [Wed, 27 Mar 2019 02:04:16 +0000 (04:04 +0200)] 
tests: WPA2-FT-SAE AP and PMKSA caching for initial MD association

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoSAE: Fix PMKSA cache entry search for FT-SAE case
Jouni Malinen [Wed, 27 Mar 2019 02:03:12 +0000 (04:03 +0200)] 
SAE: Fix PMKSA cache entry search for FT-SAE case

Previously, PMKSA cache entries were search for AKM=SAE and that did not
find an entry that was created with FT-SAE when trying to use FT-SAE
again. That resulted in having to use full SAE authentication instead of
the faster PMKSA caching alternative.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoAdd AKM info in the debug message noting PMKSA caching entry addition
Jouni Malinen [Wed, 27 Mar 2019 02:02:19 +0000 (04:02 +0200)] 
Add AKM info in the debug message noting PMKSA caching entry addition

This is useful for debugging issues where an expected PMKSA cache entry
is not found.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoFT-SAE: Use PMK as XXKey in AP when SAE PMKSA caching is used
vamsi krishna [Tue, 26 Mar 2019 14:49:02 +0000 (20:19 +0530)] 
FT-SAE: Use PMK as XXKey in AP when SAE PMKSA caching is used

When connected using FT-SAE key mgmt, use PMK from PMKSA cache as XXKey
for PMK-R0 and PMK-R1 derivations. This fixes an issue where FT key
hierarchy could not be established due to missing (not yet configured)
XXKey when using SAE PMKSA caching for the initial mobility domain
association.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoFT-SAE: Enable external auth support for FT-SAE also
vamsi krishna [Tue, 26 Mar 2019 14:29:59 +0000 (19:59 +0530)] 
FT-SAE: Enable external auth support for FT-SAE also

Extend the external authentication support to FT-SAE mode connections
also in addition to SAE mode connections.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agonl80211: Do not add WMM parameters when updating an existing STA entry
Jouni Malinen [Wed, 27 Mar 2019 01:14:02 +0000 (03:14 +0200)] 
nl80211: Do not add WMM parameters when updating an existing STA entry

In the case of the driver not supporting full AP mode STA state (i.e.,
not adding a STA entry before association), the QoS parameters are not
allowed to be modified when going through (re)association exchange for a
STA entry that has not been removed from the kernel. cfg80211 would
reject such command to update STA flags, so do not add the WMM parameter
in this case.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoFT/RRB: Pad RRB messages to at least minimum Ethernet frame length
Jouni Malinen [Tue, 26 Mar 2019 20:26:07 +0000 (22:26 +0200)] 
FT/RRB: Pad RRB messages to at least minimum Ethernet frame length

Ethernet frames have minimum length of 64 octets and shorter frames may
end up getting arbitrary padding in the end. This would result in the
FT/RRB receiver rejecting the frame as an incorrectly protected one.
Work around this by padding the message so that it is never shorter than
the minimum Ethernet frame.

Unfortunately, this padding is apparently not enough with all Ethernet
devices and it is still possible to see extra two octet padding at the
end of the message even if larger frames are used (e.g., showed up with
128 byte frames). For now, work around this by trying to do AES-SIV
decryption with two octets shorter frame (ignore last two octets) if the
first attempt fails.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoFT/RRB: Add more debug prints for RRB message encryption/decryptiom
Jouni Malinen [Tue, 26 Mar 2019 17:12:20 +0000 (19:12 +0200)] 
FT/RRB: Add more debug prints for RRB message encryption/decryptiom

This is needed to make it easier to understand what could be going wrong
in RRB communication.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agotests: sigma_dut controlled SAE association with Password Identifier/FT
Jouni Malinen [Tue, 26 Mar 2019 04:52:28 +0000 (06:52 +0200)] 
tests: sigma_dut controlled SAE association with Password Identifier/FT

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agotests: SAE + FT-SAE configuration
Jouni Malinen [Tue, 26 Mar 2019 04:35:33 +0000 (06:35 +0200)] 
tests: SAE + FT-SAE configuration

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoSAE: Reorder SAE and FT-SAE AKM selection to prefer the FT option
Jouni Malinen [Tue, 26 Mar 2019 04:32:10 +0000 (06:32 +0200)] 
SAE: Reorder SAE and FT-SAE AKM selection to prefer the FT option

If a network profile has both SAE and FT-SAE enabled, SAE was previously
picked (and used incorrectly as explained in the previous commit). This
is not ideal since use of FT protocol can speed up roaming within in
mobility domain. Reorder this checks so that FT-SAE is preferred over
SAE if both are enabled.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoFT: Fix SAE + FT-SAE behavior in association parameter selection
Jouni Malinen [Tue, 26 Mar 2019 04:29:34 +0000 (06:29 +0200)] 
FT: Fix SAE + FT-SAE behavior in association parameter selection

Do not try to initialize FT reassociation if the selected AKM is for SAE
instead of FT-SAE when both of these are enabled in a network profile.
This fixes an issue with MDE being included in an (Re)Association
Request frame even when using a non-FT AKM (which is something that
results in hostapd rejecting the association).

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agotests: sigma_dut and SAE Password Identifier
Jouni Malinen [Mon, 25 Mar 2019 23:09:04 +0000 (01:09 +0200)] 
tests: sigma_dut and SAE Password Identifier

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agotests: dpp_bootstrap_gen_failures to match implementation changes
Jouni Malinen [Sun, 24 Mar 2019 14:48:31 +0000 (16:48 +0200)] 
tests: dpp_bootstrap_gen_failures to match implementation changes

The separate dpp_bootstrap_gen() functions were merged into a single
one, so the test case needs a matching change to avoid failures.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoDPP: Common configurator/bootstrapping data management
Jouni Malinen [Sun, 24 Mar 2019 14:44:21 +0000 (16:44 +0200)] 
DPP: Common configurator/bootstrapping data management

Merge the practically copy-pasted implementations in wpa_supplicant and
hostapd into a single shared implementation in dpp.c for managing
configurator and boostrapping information. This avoid unnecessary code
duplication and provides a convenient location for adding new global DPP
data.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agotests: sigma_dut sta_scan GetParameter,SSID_BSSID
Jouni Malinen [Thu, 21 Mar 2019 15:08:02 +0000 (17:08 +0200)] 
tests: sigma_dut sta_scan GetParameter,SSID_BSSID

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoFix memcpy regression in PMK handling
Jouni Malinen [Sat, 23 Mar 2019 10:44:42 +0000 (12:44 +0200)] 
Fix memcpy regression in PMK handling

The memcpy calls added for exposing the PMK from wpa_auth module could
end up trying to copy the same memory buffer on top of itself.
Overlapping memory areas are not allowed with memcpy, so this could
result in undefined behavior. Fix this by making the copies conditional
on the updated value actually coming from somewhere else.

Fixes: b08c9ad0c78d ("AP: Expose PMK outside of wpa_auth module")
Signed-off-by: Jouni Malinen <j@w1.fi>
5 years agoFILS: Fix KEK2 derivation for FILS+FT
Jouni Malinen [Wed, 20 Mar 2019 20:26:56 +0000 (22:26 +0200)] 
FILS: Fix KEK2 derivation for FILS+FT

The offset update for copying KEK2 from the extended PTK was overriding
the offset instead of incrementing it (a likely copy-paste error from
the first offset assignment based on KCK). This resulted in KEK2 being
set to incorrect segment of PTK. Fix this by updating the offset
properly so that KEK2 is copied from the correct place at the end of the
PTK.

Fixes: 2f37387812a5 ("FILS: Add more complete support for FT-FILS use cases")
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoOpenSSL: Fix build with current BoringSSL
Jouni Malinen [Tue, 19 Mar 2019 16:15:28 +0000 (18:15 +0200)] 
OpenSSL: Fix build with current BoringSSL

SSL_use_certificate_chain_file() is not available in the current
BoringSSL even though the defined OPENSSL_VERSION_NUMBER is large enough
to claim that this function would be present in the OpenSSL API.

Fall back to using SSL_use_certificate_file() with BoringSSL to fix the
build.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agotests: Reset sae_groups in sigma_dut_dpp_qr_init_enrollee_sae
Jouni Malinen [Mon, 18 Mar 2019 17:00:06 +0000 (19:00 +0200)] 
tests: Reset sae_groups in sigma_dut_dpp_qr_init_enrollee_sae

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agotests: Remove unnecessary dump_monitor() calls from end of test cases
Jouni Malinen [Mon, 18 Mar 2019 16:23:02 +0000 (18:23 +0200)] 
tests: Remove unnecessary dump_monitor() calls from end of test cases

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agotests: Use a helper function for DPP_CONFIGURATOR_ADD/REMOVE
Jouni Malinen [Mon, 18 Mar 2019 11:36:32 +0000 (13:36 +0200)] 
tests: Use a helper function for DPP_CONFIGURATOR_ADD/REMOVE

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agotests: Use a helper function for DPP_AUTH_INIT
Jouni Malinen [Mon, 18 Mar 2019 09:36:43 +0000 (11:36 +0200)] 
tests: Use a helper function for DPP_AUTH_INIT

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoOWE: Move Association Response frame IE addition to appropriate place
Jouni Malinen [Mon, 18 Mar 2019 09:48:53 +0000 (11:48 +0200)] 
OWE: Move Association Response frame IE addition to appropriate place

This code was after the FILS handling that would have encrypted the
frame. While FILS and OWE are never used together, the OWE handling
should really be before the FILS handling since no IEs can be added
after the FILS encryption step. In addition, the Diffie-Hellman
Parameter element is not a Vendor Specific element, so it should be
before some of the Vendor Specific elements even though it is not
defined in IEEE 802.11.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agotests: DPP AP+STA provisioning and connection with Brainpool curves
Jouni Malinen [Mon, 18 Mar 2019 09:44:00 +0000 (11:44 +0200)] 
tests: DPP AP+STA provisioning and connection with Brainpool curves

Increase testing coverage by going through all six possible curves with
full provisioning of AP and STA and connection (which includes PFS with
DPP2).

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoDPP2: PFS for PTK derivation
Jouni Malinen [Sun, 17 Mar 2019 21:51:53 +0000 (23:51 +0200)] 
DPP2: PFS for PTK derivation

Use Diffie-Hellman key exchange to derivate additional material for
PMK-to-PTK derivation to get PFS. The Diffie-Hellman Parameter element
(defined in OWE RFC 8110) is used in association frames to exchange the
DH public keys. For backwards compatibility, ignore missing
request/response DH parameter and fall back to no PFS in such cases.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoDPP2: Extend wpa_pmk_to_ptk() to support extra Z.x component in context
Jouni Malinen [Sun, 17 Mar 2019 20:02:06 +0000 (22:02 +0200)] 
DPP2: Extend wpa_pmk_to_ptk() to support extra Z.x component in context

DPP allows Diffie-Hellman exchange to be used for PFS in PTK derivation.
This requires an additional Z.x (x coordinate of the DH shared secret)
to be passed to wpa_pmk_to_ptk(). This commit adds that to the function
and updates all the callers to pass NULL,0 for that part in preparation
of the DPP specific changes to start using this.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agoOWE: Allow Diffie-Hellman Parameter element to be included with DPP
Jouni Malinen [Sun, 17 Mar 2019 22:25:11 +0000 (00:25 +0200)] 
OWE: Allow Diffie-Hellman Parameter element to be included with DPP

The previous OWE implementation on the AP side rejected any
(Re)Association Request frame with the Diffie-Hellman Parameter element
if AKM was not OWE. This breaks compatibility with DPP PFS, so relax
that rule to allow DPP AKM to be used as well. While this commit alone
does not add support for PFS, this allows interoperability between
non-PFS implementation on the AP and a newer PFS implementation on the
STA.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
5 years agotests: Fix mesh_sae_groups_invalid to reset sae_groups setting
Jouni Malinen [Sun, 17 Mar 2019 22:01:34 +0000 (00:01 +0200)] 
tests: Fix mesh_sae_groups_invalid to reset sae_groups setting

This test case did not clear a possibly modified sae_groups value from a
prior test case for adev[2] and could fail if the previously set group
was not supported by the AP.

Signed-off-by: Jouni Malinen <j@w1.fi>
5 years agotests: Fix WPS with SAE test cases to reset sae_groups setting
Jouni Malinen [Sun, 17 Mar 2019 21:56:23 +0000 (23:56 +0200)] 
tests: Fix WPS with SAE test cases to reset sae_groups setting

These test cases did not clear a possibly modified sae_groups value from
a prior test case and could fail if the previously set group was not
supported by the AP.

Signed-off-by: Jouni Malinen <j@w1.fi>
5 years agotests: Fix ap_mixed_security to reset sae_groups setting
Jouni Malinen [Sun, 17 Mar 2019 19:42:38 +0000 (21:42 +0200)] 
tests: Fix ap_mixed_security to reset sae_groups setting

This test case did not clear a possibly modified sae_groups value from a
prior test case and could fail if the previously set group was not
supported by the AP.

Signed-off-by: Jouni Malinen <j@w1.fi>
5 years agotests: ap_mixed_security to use SAE capability from the correct station
Jouni Malinen [Sun, 17 Mar 2019 19:38:34 +0000 (21:38 +0200)] 
tests: ap_mixed_security to use SAE capability from the correct station

Signed-off-by: Jouni Malinen <j@w1.fi>
5 years agotests: Helper function for checking DPP-FAIL reporting
Jouni Malinen [Sun, 17 Mar 2019 18:26:23 +0000 (20:26 +0200)] 
tests: Helper function for checking DPP-FAIL reporting

Signed-off-by: Jouni Malinen <j@w1.fi>
5 years agotests: Helper functions for DPP PKEX initiator and responder
Jouni Malinen [Sun, 17 Mar 2019 17:22:11 +0000 (19:22 +0200)] 
tests: Helper functions for DPP PKEX initiator and responder

Signed-off-by: Jouni Malinen <j@w1.fi>
5 years agotests: DPP use the wait_auth_success() helper function
Jouni Malinen [Sun, 17 Mar 2019 16:37:56 +0000 (18:37 +0200)] 
tests: DPP use the wait_auth_success() helper function

Use the already existing helper function and extend it to cover the most
common test sequences.

Signed-off-by: Jouni Malinen <j@w1.fi>
5 years agotests: Use helper function for DPP_LISTEN commands
Jouni Malinen [Sun, 17 Mar 2019 16:19:58 +0000 (18:19 +0200)] 
tests: Use helper function for DPP_LISTEN commands

Signed-off-by: Jouni Malinen <j@w1.fi>
5 years agotests: Helper function for DISCONNECT + ABORT_SCAN + wait
Jouni Malinen [Sun, 17 Mar 2019 15:55:43 +0000 (17:55 +0200)] 
tests: Helper function for DISCONNECT + ABORT_SCAN + wait

Use a helper function to perform this common sequence to disconnect and
stop any possibly started reconnection attempt.

Signed-off-by: Jouni Malinen <j@w1.fi>
5 years agotests: Handle scan result clearing more carefully in ap_country
Jouni Malinen [Sun, 17 Mar 2019 15:40:39 +0000 (17:40 +0200)] 
tests: Handle scan result clearing more carefully in ap_country

If the ABORT_SCAN command succeeds, CTRL-EVENT-SCAN-RESULTS event is
delivered for the aborted scan. Following this with an immediate
flush_scan_cache() call can result in the first scan interpreting that
pending event as the completion and that results in trying to start
another scan while the first scan is still in progress.

Signed-off-by: Jouni Malinen <j@w1.fi>
5 years agotests: Remove group at the end of p2p_ext_vendor_elem_invitation
Jouni Malinen [Sun, 17 Mar 2019 15:06:04 +0000 (17:06 +0200)] 
tests: Remove group at the end of p2p_ext_vendor_elem_invitation

This is needed to avoid leaving behind a ROC operation at the end of the
test case. This was found with the following test sequence:
p2p_ext_vendor_elem_invitation wifi_display_r2

Signed-off-by: Jouni Malinen <j@w1.fi>
5 years agotests: Fix ECDSA signature generation
Jouni Malinen [Sun, 17 Mar 2019 14:53:05 +0000 (16:53 +0200)] 
tests: Fix ECDSA signature generation

Parsing of the DER encoded signature was unable to handle results that
were shorter than the prime. These need to be zero padded from left to
generate the correct value.

Signed-off-by: Jouni Malinen <j@w1.fi>
5 years agotests: Split event wait in grpform_cred_ready_timeout
Jouni Malinen [Sun, 17 Mar 2019 14:00:18 +0000 (16:00 +0200)] 
tests: Split event wait in grpform_cred_ready_timeout

The long wait for the monitor socket events resulted in another socket
running out of TX buffer space. Split the wait into smaller segments and
clear the other socket in each iteration.

Signed-off-by: Jouni Malinen <j@w1.fi>
5 years agotests: Clear monitor socket queue in ap_hs20_interworking_oom
Jouni Malinen [Sun, 17 Mar 2019 13:29:02 +0000 (15:29 +0200)] 
tests: Clear monitor socket queue in ap_hs20_interworking_oom

Do not leave all the event messages pending in the socket queue for the
full duration of the test case to avoid hitting the TX socket queue
limit.

Signed-off-by: Jouni Malinen <j@w1.fi>