Update Wide Bandwidth Channel Switch element as per IEEE
P802.11-REVme/D4.0, 9.4.2.159 (Wide Bandwidth Channel Switch element)
and Table 9-314 (VHT Operation Information subfields).
Update New Channel Width, New Channel Center Frequency Segment 0, and
New Channel Center Frequency Segment 1 fields as per IEEE
P802.11-REVme/D4.0 for 160 MHz and 80+80 MHz bandwidth. This replaces
the use of now deprecated Channel Width 2 and 3 values with a more
backwards compatible design.
Signed-off-by: Yuvarani V <quic_yuvarani@quicinc.com>
Do not reject reauth threshold passed PMKSA indicated in successful
association event since the PMKSA is still valid.
Additionally, remove the reauth threshold passed PMKSA entry from the
driver to prevent using it further in the driver.
Signed-off-by: Veerendranath Jakkam <quic_vjakkam@quicinc.com>
Wi-Fi Aware pairing responder needs to forward the derive PMK to the
framework on successful pairing setup. The framework will set
corresponding PMK while a pairing verification is initiated by the
paired peer. Since the PMK is not updated for responder's PASN context,
framework does not have a valid PMK and verification fails. Hence copy
the derived PMK to PASN context.
Signed-off-by: Jouni Malinen <quic_jouni@quicinc.com>
Currently, during association handling, if any of the iface parameters
changes due to some reason, it calls ieee802_11_set_beacons() function.
This function sets beacon for the all the BSSes in that iface even if
the beacon was not set already. This leads to setting the beacon
prematurely for some BSSes which was intentionally not started.
Fix the above issue by calling ieee802_11_update_beacons() function
instead. This function only updates the beacon if it was already set.
While at it, do the same while freeing STA entry.
Signed-off-by: Aditya Kumar Singh <quic_adisi@quicinc.com>
Based on IEEE Std 802.11-2020 Table E-3 (Operating classes in Japan) and
Table E-4 (Global operating classes), we update channel 144 for those
corresponding operating classes.
The changes applicable to the global operating classes fixes an issue of
P2P GO not starting on channel 144 (frequency 5720 MHz) in cases where
the driver supports DFS operations.
Signed-off-by: Shuibing Dai <shuibing@google.com>
Enumeration qca_wlan_roam_stats_frame_subtype defines the various frame
subtypes which may be collected by the driver and reported via the
QCA_WLAN_VENDOR_ATTR_ROAM_STATS_FRAME_SUBTYPE attribute.
Two of the enumerators are:
* QCA_WLAN_ROAM_STATS_FRAME_SUBTYPE_PREAUTH
* QCA_WLAN_ROAM_STATS_FRAME_SUBTYPE_REASSOC
These were initially defined and used to respectively report
Authentication Response and Reassociation Response frames.
Now there is a requirement to also report Authentication Request and
Reassociation Request frames. In order to satisfy this requirement,
add two new enumerators:
* QCA_WLAN_ROAM_STATS_FRAME_SUBTYPE_AUTH_REQ
* QCA_WLAN_ROAM_STATS_FRAME_SUBTYPE_REASSOC_REQ
Note that the first of these uses the standard term "AUTH" instead of
the confusing term "PREAUTH" used previously.
And to align with that naming, and in order to clearly show the usage
of the original enumerators, rename them to:
* QCA_WLAN_ROAM_STATS_FRAME_SUBTYPE_AUTH_RESP
* QCA_WLAN_ROAM_STATS_FRAME_SUBTYPE_REASSOC_RESP
Furthermore, Authentication Request/Response frame refers to the
Authentication frames sent by the non-AP STA and AP, respectively.
And finally, to support backward compatibility with applications using
the original enumerators, redefine those in terms of the new names.
Signed-off-by: Chunquan Luo <quic_chunquan@quicinc.com>
Fetch AP BSSID from each roam connection frame and cache the info in the
WLAN driver. When user space gets roam stats by
QCA_WLAN_VENDOR_ATTR_ROAM_STATS_INFO, user space can now collect the AP
BSSID info for roam issue.
Signed-off-by: Chunquan Luo <quic_chunquan@quicinc.com>
Redesign the identity selection for MK derivation to be done explicitly
based on the last indicated identity (whether it is from
EAP-Response/Identity or method specific AT_IDENTITY) during the current
exchange. This makes the implementation cleaner and avoids cases were
more or less duplicated selection steps ended up being slightly
different. This is not as clean as it could otherwise be due to the
exception needed for the IMSI privacy case where the identity used in MK
derivation is actually not the one exchanged in the EAP messages.
Furthermore, this moves the somewhat confusing EAP method specific
tracking of the lasgt EAP-Response/Identity value from EAP-SIM/AKA into
the main EAP peer implementation.
Signed-off-by: Jouni Malinen <quic_jouni@quicinc.com>
Allow the EAP-SIM/AKA server to be configured to use a smaller limit for
the number of times fast re-authentication can be used before falling
back to running full authentication. This is particularly useful for EAP
peer testing to cover cases when falling back from fast
re-authentication to full authentication in various different cases.
Signed-off-by: Jouni Malinen <quic_jouni@quicinc.com>
While the EAP-SIM/AKA RFCs recommend against doing this, some deployed
authentication servers use the identity from the EAP-Response/Identity
directly without using an EAP method specific indication (AT_IDENTITY).
Having a capability to configure hostapd EAP server to behave in this
manner helps in increasing testing coverage for the EAP peer
implementation.
Signed-off-by: Jouni Malinen <quic_jouni@quicinc.com>
A case was missing in the way wpa_supplicant was tracking the identity
that is used when deriving MK if the EAP server does not follow the RFC
guidance on using EAP method specific identity determination (i.e.,
AT_IDENTITY for EAP-SIM/AKA) combined with a fallback from fast
re-authentication to full authentication. wpa_supplicant ended up using
the actual identity instead of the last identity included in an EAP
message even though MK derivation is supposed to use the identity that
was included in the last AT_IDENTITY or in the EAP-Response/Identity if
AT_IDENTITY was not used. This resulted in such an authentication
attempt failing due to incorrect MK being derived and AT_MAC validation
resulting in an mismatch.
Fix this by checking for the case where fast re-authentication is
attempted and the server recognizes the fast re-auth identity, but
decides to fall back to full authentication without a separate EAP
method specific identity exchange using AT_IDENTITY. This allows the
fast re-auth identity from EAP-Response/Identity to be used in MK
derivation in such cases.
Signed-off-by: Jouni Malinen <quic_jouni@quicinc.com>
Define a new QCA vendor attribute to configure traffic
shaping policy applied during coex scenarios.
Signed-off-by: Shailendra Singh <quic_shasing@quicinc.com>
Add an attribute QCA_WLAN_VENDOR_ATTR_ADD_STA_NODE_IS_ML to the
ADD_STA_NODE command. If this attribute is set, it implies that the node
being added is an MLD node.
Signed-off-by: Adil Saeed Musthafa <quic_adilm@quicinc.com>
Extend QCA_WLAN_VENDOR_ATTR_CONFIG_CHAN_WIDTH_UPDATE_TYPE attribute to
support handling interoperability issues with APs which don't handle
the maximum bandwidth change indication correctly.
Additionally define an enum for possible values of
QCA_WLAN_VENDOR_ATTR_CONFIG_CHAN_WIDTH_UPDATE_TYPE.
Signed-off-by: Veerendranath Jakkam <quic_vjakkam@quicinc.com>
Add QCA vendor attributes to indicate various MLO capabilities supported
by the WLAN driver to userspace. These capabilities are usually reported
by the firmware during the initial bootup handshake with the driver.
Signed-off-by: Mukul Sharma <quic_mukul@quicinc.com>
Add the copied EHT capabilities into the sta_add() call when adding a
TDLS peer.
The mld_link_id value was previously only for AP mode, but it can now be
used for TDLS links as well to indicate the link on which a
single-link-TDLS direct link is negotiated.
Signed-off-by: Jouni Malinen <quic_klokere@quicinc.com>
When the current association is with an AP MLD, the BSSID for TDLS
operations needs to be selected based on which link is used to transmit
the frames.
Signed-off-by: Jouni Malinen <quic_klokere@quicinc.com>
When the current association is with an AP MLD, the Discovery Response
needs to be sent using the link that matches the indicated BSSID.
Signed-off-by: Jouni Malinen <quic_klokere@quicinc.com>
This is needed to be able to determine which link is used for TDLS setup
when the current association is with an AP MLD.
Signed-off-by: Jouni Malinen <quic_klokere@quicinc.com>
This is needed to be able to configure the STA entry into the driver
with the information for EHT.
Signed-off-by: Jouni Malinen <quic_klokere@quicinc.com>
For now, only a vendor command is available for this functionality that
is needed to implement single-link TDLS during an MLO association.
Signed-off-by: Jouni Malinen <quic_klokere@quicinc.com>
This is needed to allow the driver to know on which operating channel
(as specified by the link that is affiliated with AP MLD for the current
association) is used for transmitting TDLS Discovery Response. This
commit adds the link_id parameter to various functions, but does not
implement the driver interface change itself.
Signed-off-by: Jouni Malinen <quic_klokere@quicinc.com>
Commit 9025def55c ("wpa_supplicant: Add support for pregenerated MAC")
added this capability, but did not update wpa_supplicant.conf to
document it. Add such documentation to match the information in
config_ssid.h.
Signed-off-by: Jouni Malinen <quic_jouni@quicinc.com>
wpa_supplicant does not configure BIGTK(s) to the driver when the STA
reconnects to the same AP after disconnect due to not clearing the last
configured BIGTK values during disconnect. To avoid such issues clear
the BIGTK values while clearing PTK and other group keys.
Fixes: 2d4c78aef7 ("Configure received BIGTK on station/supplicant side")
Fixes: f15cc834cb ("MLD STA: Processing of EAPOL-Key msg 3/4 frame when using MLO")
Signed-off-by: Veerendranath Jakkam <quic_vjakkam@quicinc.com>
This subelement within the Basic MLE Link Info can be long enough to
require fragmentation, so defragment it before parsing.
Signed-off-by: Jouni Malinen <quic_jouni@quicinc.com>
The Basic Multi-Link element is going to be fragmented in many cases, so
defragment it first before trying to parse it.
Signed-off-by: Jouni Malinen <quic_jouni@quicinc.com>
Extend FT Reassociation Response frame processing to support the new MLO
GTK/IGTK/BIGTK subelements similarly to how the MLO group keys were
already learned from EAPOL-Key msg 3/4.
Signed-off-by: Jouni Malinen <quic_jouni@quicinc.com>
The AP's RSNE needs to be modified by inserting the PMKR1Name in the
PMKID List field for each affiliated link.
Fixes: 8cf919ffd5 ("wlantest: FTE MIC calculation for MLO Reassociation Response frame")
Signed-off-by: Jouni Malinen <quic_jouni@quicinc.com>
IEEE P802.11be/D4.0 does not seem to have changed the rules for deriving
PTK in FT hierarchy since there were no changes to 12.7.1.6.5 (PTK)
where BSSID and STA-ADDR are used. However, the MLO changes for FT and
for PTK derivation in non-FT cases seem to imply that this FT case is
also supposed to use MLD MAC addresses.
Commit 628b9f1022 ("wlantest: Derive PMK-R1 and PTK using AA/SPA for
MLO FT over-the-DS") did this already for FT over-the-DS, so do the same
for FT over-the-air.
Signed-off-by: Jouni Malinen <quic_jouni@quicinc.com>
S1KH-ID is supposed to be SPA, so learn the MLD MAC address of the
non-AP MLD from the FT Authentication frame and use that instead of the
link address when deriving keys in FT over-the-air case.
Signed-off-by: Jouni Malinen <quic_jouni@quicinc.com>
The ap_mld_addr entry was added without introducing a new mask bit which
does not follow the expected style for adding new information into the
BSS command and might result in unexpected behavior for external
components. Define a new BSS command information mask bit for this AP
MLD address and print the AP MLD address in the BSS info only if the
mask bit is set.
Fixes: db99e7341a ("Add AP MLD address into BSS command output")
Signed-off-by: Jouni Malinen <quic_jouni@quicinc.com>
Use the initial BSS/STA routines to determine whether A1 points to STA
instead of maintaining multiple somewhat different ways of doing this.
In addition to making the code easier to maintain, this fixes at least
some cases where incorrect tx/rx_tid or rsc_tods/fromds value was
selected for 4-address frames.
Signed-off-by: Jouni Malinen <quic_jouni@quicinc.com>
Use the A1/A2/A3 overrides for MLO determined within rx_data_bss_prot()
in try_ptk_decrypt() to avoid duplicated code in these two functions.
Signed-off-by: Jouni Malinen <quic_jouni@quicinc.com>
Search the A1/A2 values in 4-address frames using the MLO enabled
functions to allow appropriate STA entries to be located when these
frames are used with MLO.
Signed-off-by: Jouni Malinen <quic_jouni@quicinc.com>
Add a vendor attribute for an EHT DUT to configure the type of TID-To-Link
Mapping Negotiation Support for testing purposes.
Signed-off-by: Jouni Malinen <quic_jouni@quicinc.com>
Add a QCA vendor attribute QCA_WLAN_VENDOR_ATTR_CONFIG_PEER_AMPDU_CNT to
enable configuration of TX maximum aggregate size with a specific peer.
This can be used to improve performance in noisy environment. In AP
mode, the peer MAC address of the associated STA is specified with
QCA_WLAN_VENDOR_ATTR_CONFIG_PEER_MAC.
Signed-off-by: Will Huang <quic_wilhuang@quicinc.com>
Rename the attribute QCA_WLAN_VENDOR_ATTR_CONFIG_RX_BLOCKSIZE_PEER_MAC
to a generic name QCA_WLAN_VENDOR_ATTR_CONFIG_PEER_MAC, so other
configuration commands can reuse it. And make backward compatibility of
QCA_WLAN_VENDOR_ATTR_CONFIG_RX_BLOCKSIZE_PEER_MAC, define it as same
value of QCA_WLAN_VENDOR_ATTR_CONFIG_PEER_MAC (35).
Signed-off-by: Will Huang <quic_wilhuang@quicinc.com>
The driver might decide to change the operating band on its own, e.g.,
when trying to use a single channel in AP + AP case. A CSA event will be
notified to hostapd to update the channel/frequency, but hw_mode did not
get updated accordingly.
This may cause hostapd interface restarting to fail, e.g., with control
interface DISABLE / ENABLE commands at configured_fixed_chan_to_freq(),
because of the mismatch between conf->channel and conf->hw_mode.
Update hw_mode right after channel change to fix this.
Signed-off-by: ngong <quic_ngong@quicinc.com>
Send the actual MFP configuration value to the driver instead of
overriding it with MFP required based on the wpa_supplicant selected BSS
when the driver takes care of BSS selection.
This is needed to allow the driver to know whether it can select an MFP
disabled BSS.
Signed-off-by: Veerendranath Jakkam <quic_vjakkam@quicinc.com>
Per IEEE P802.11be/D4.0, 9.4.2.316 (QoS Characteristics element), enable
support for the following optional QoS Characteristics parameters:
- Maximum MSDU Size
- Service Start Time
- Service Start Time LinkID
- Mean Data Rate
- Delayed Bounded Burst Size
- MSDU Lifetime
- MSDU Delivery Info
- Medium Time
Signed-off-by: Purushottam Kushwaha <quic_pkushwah@quicinc.com>
Add support to configure the mandatory QoS Characteristics parameters
per IEEE P802.11be/D4.0, 9.4.2.316 (QoS Characteristics element), in SCS
request:
- Minimum Service Interval
- Maximum Service Interval
- Minimum Data Rate
- Delay Bound
Enable STA SCS traffic descriptor support for EHT connection when the
connected EHT AP advertises SCS traffic descriptor capability in the EHT
Capabilities element.
Signed-off-by: Purushottam Kushwaha <quic_pkushwah@quicinc.com>