From nobody Thu Dec 02 22:47:56 2021 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id A780618C45B5; Thu, 2 Dec 2021 22:47:57 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4J4rhF2PdWz4VgT; Thu, 2 Dec 2021 22:47:57 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 2DA8025AC4; Thu, 2 Dec 2021 22:47:57 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 1B2Mlv7a089208; Thu, 2 Dec 2021 22:47:57 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 1B2Mluh8089207; Thu, 2 Dec 2021 22:47:56 GMT (envelope-from git) Date: Thu, 2 Dec 2021 22:47:56 GMT Message-Id: <202112022247.1B2Mluh8089207@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Cy Schubert Subject: git: db0ac6ded611 - main - Revert "wpa: Import wpa_supplicant/hostapd commit 14ab4a816" List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-main@freebsd.org X-BeenThere: dev-commits-src-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cy X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: db0ac6ded61105caab4700aeac255328d4238dc4 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1638485277; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=6QGWJfnQd4Lupjs8e07C+TrWiuG1/0AUK/B9jFPy71c=; b=r5HUfqFkraTpqL/7EGlC64PHNkF5AxYHa80urfFcAdogbK3LUkUkKWdD+f0QglV/Hy5Eel bzzzSoxvtzr59zNUbSL0oiiT6oFh7Fn6DVqHaXdZxiV+g25bY5Agu6xxY4aR0cVrmqtxCV hVeoQN4H7w2mbm12K/Exsgx2HidNFAeJh4dzKcQdzv71OelQMts8TrQuHTzbfiSpWK2Scj Ppkp/5Z0pjzuKzAk81X/FxLL0/rjJFwfTYNIVDIFId/C3DbJU4TMeM6b+D8RMyA0OJsUpH 7/2nYUA2WkAq2SD4zPbVFqeJZKZTD78YqUGlu4HbQt6/uPP4z7y2q4ezE179qQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1638485277; a=rsa-sha256; cv=none; b=QBtwW+X5I6vQJBX9CAFbjFaQapeQim8FR6Hh+BF4ZKoyPOYGbxJPF75v7plzUcfZNUTUcL saL6c9di2JU9Hf/idCBDIM7Tde/VsOOBkPFxopEDQaaWGrq7ypNDleacZq6B5HdS04Ovvo 7p8duuIlcTslCCOmmlWDU/Wazqt1l1M61XxSk+lcMKzaG/rpcUtUnsUI6WqJVOIAHfm6Fc TLjFxcgGAkxWK2votppA8Pji42imgI7Yxvv7c5JD8F2cpXQdChr8EpMNY3n27n81c84ceA jPBQAwc2PB/CehIOUW3d7nNEOJB6qRZdCUt6cjNSHiB95efMqH2Ss5mg5aENOA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by cy: URL: https://cgit.FreeBSD.org/src/commit/?id=db0ac6ded61105caab4700aeac255328d4238dc4 commit db0ac6ded61105caab4700aeac255328d4238dc4 Author: Cy Schubert AuthorDate: 2021-12-02 22:45:04 +0000 Commit: Cy Schubert CommitDate: 2021-12-02 22:45:04 +0000 Revert "wpa: Import wpa_supplicant/hostapd commit 14ab4a816" This reverts commit 266f97b5e9a7958e365e78288616a459b40d924a, reversing changes made to a10253cffea84c0c980a36ba6776b00ed96c3e3b. A mismerge of a merge to catch up to main resulted in files being committed which should not have been. --- ObsoleteFiles.inc | 19 + contrib/wpa/hostapd/config_file.c | 25 +- contrib/wpa/hostapd/ctrl_iface.c | 43 +- contrib/wpa/hostapd/hlr_auc_gw.milenage_db | 2 +- contrib/wpa/hostapd/hostapd.conf | 10 +- contrib/wpa/hostapd/hostapd_cli.c | 2 +- contrib/wpa/src/ap/acs.c | 4 +- contrib/wpa/src/ap/ap_config.c | 11 +- contrib/wpa/src/ap/ap_config.h | 3 - contrib/wpa/src/ap/beacon.c | 79 +- contrib/wpa/src/ap/ctrl_iface_ap.c | 56 +- contrib/wpa/src/ap/dhcp_snoop.c | 2 - contrib/wpa/src/ap/dpp_hostapd.c | 19 +- contrib/wpa/src/ap/hostapd.h | 2 - contrib/wpa/src/ap/hw_features.c | 2 - contrib/wpa/src/ap/ieee802_11.c | 388 +--- contrib/wpa/src/ap/ieee802_11.h | 2 - contrib/wpa/src/ap/ieee802_11_he.c | 3 - contrib/wpa/src/ap/ndisc_snoop.c | 2 - contrib/wpa/src/ap/neighbor_db.c | 8 +- contrib/wpa/src/ap/neighbor_db.h | 3 +- contrib/wpa/src/ap/wnm_ap.c | 12 +- contrib/wpa/src/ap/wnm_ap.h | 4 +- contrib/wpa/src/ap/wpa_auth.c | 18 +- contrib/wpa/src/ap/wpa_auth_ft.c | 16 +- contrib/wpa/src/ap/wps_hostapd.c | 5 - contrib/wpa/src/common/dpp.c | 175 +- contrib/wpa/src/common/dpp.h | 30 +- contrib/wpa/src/common/dpp_auth.c | 18 +- contrib/wpa/src/common/dpp_backup.c | 75 +- contrib/wpa/src/common/dpp_crypto.c | 1885 +++++++++++++++----- contrib/wpa/src/common/dpp_i.h | 70 +- contrib/wpa/src/common/dpp_pkex.c | 280 +-- contrib/wpa/src/common/dpp_reconfig.c | 34 +- contrib/wpa/src/common/dpp_tcp.c | 13 +- contrib/wpa/src/common/hw_features_common.c | 25 +- contrib/wpa/src/common/ieee802_11_common.c | 44 +- contrib/wpa/src/common/ieee802_11_common.h | 2 - contrib/wpa/src/common/ieee802_11_defs.h | 56 - contrib/wpa/src/common/ptksa_cache.c | 18 +- contrib/wpa/src/common/qca-vendor.h | 665 +------ contrib/wpa/src/common/sae.c | 12 +- contrib/wpa/src/common/wpa_common.c | 5 - contrib/wpa/src/common/wpa_common.h | 1 - contrib/wpa/src/common/wpa_ctrl.h | 8 - contrib/wpa/src/crypto/crypto.h | 371 +--- contrib/wpa/src/crypto/crypto_internal-rsa.c | 2 +- contrib/wpa/src/crypto/crypto_openssl.c | 1101 ++---------- contrib/wpa/src/crypto/crypto_wolfssl.c | 8 +- contrib/wpa/src/crypto/random.c | 42 +- contrib/wpa/src/crypto/tls_openssl.c | 23 - contrib/wpa/src/drivers/driver.h | 6 +- contrib/wpa/src/drivers/driver_common.c | 2 +- contrib/wpa/src/drivers/driver_hostap.h | 2 + contrib/wpa/src/drivers/driver_macsec_qca.c | 58 +- contrib/wpa/src/drivers/driver_ndis.c | 16 +- contrib/wpa/src/drivers/driver_nl80211.c | 29 +- contrib/wpa/src/drivers/driver_nl80211.h | 1 - contrib/wpa/src/drivers/driver_nl80211_capa.c | 2 +- contrib/wpa/src/eap_peer/eap_proxy_dummy.c | 2 +- contrib/wpa/src/eap_peer/eap_teap.c | 10 +- contrib/wpa/src/eap_peer/eap_tls_common.h | 2 +- contrib/wpa/src/eap_server/eap_tls_common.h | 2 +- contrib/wpa/src/l2_packet/l2_packet_none.c | 2 +- contrib/wpa/src/p2p/p2p.c | 4 +- contrib/wpa/src/p2p/p2p_build.c | 2 +- contrib/wpa/src/p2p/p2p_go_neg.c | 4 +- contrib/wpa/src/p2p/p2p_i.h | 3 +- contrib/wpa/src/p2p/p2p_pd.c | 2 +- contrib/wpa/src/pae/ieee802_1x_kay.c | 10 +- contrib/wpa/src/radius/radius_client.c | 5 +- contrib/wpa/src/rsn_supp/pmksa_cache.c | 92 +- contrib/wpa/src/rsn_supp/pmksa_cache.h | 9 - contrib/wpa/src/rsn_supp/tdls.c | 43 +- contrib/wpa/src/rsn_supp/wpa.c | 27 +- contrib/wpa/src/rsn_supp/wpa.h | 6 - contrib/wpa/src/rsn_supp/wpa_i.h | 3 +- contrib/wpa/src/utils/config.c | 18 +- contrib/wpa/src/utils/eloop.c | 25 +- contrib/wpa/src/wps/wps.c | 2 +- contrib/wpa/src/wps/wps_defs.h | 2 +- contrib/wpa/src/wps/wps_registrar.c | 26 +- contrib/wpa/src/wps/wps_upnp.c | 2 +- contrib/wpa/wpa_supplicant/Android.mk | 3 +- contrib/wpa/wpa_supplicant/ChangeLog | 3 +- contrib/wpa/wpa_supplicant/Makefile | 12 +- contrib/wpa/wpa_supplicant/README | 84 - contrib/wpa/wpa_supplicant/ap.c | 126 +- contrib/wpa/wpa_supplicant/ap.h | 1 - contrib/wpa/wpa_supplicant/config.c | 50 +- contrib/wpa/wpa_supplicant/config.h | 11 - contrib/wpa/wpa_supplicant/config_file.c | 13 - contrib/wpa/wpa_supplicant/config_none.c | 2 +- contrib/wpa/wpa_supplicant/config_ssid.h | 16 - contrib/wpa/wpa_supplicant/ctrl_iface.c | 623 +------ .../wpa_supplicant/doc/docbook/wpa_supplicant.sgml | 2 +- contrib/wpa/wpa_supplicant/eapol_test.py | 37 +- contrib/wpa/wpa_supplicant/events.c | 237 +-- contrib/wpa/wpa_supplicant/gas_query.c | 10 + contrib/wpa/wpa_supplicant/gas_query.h | 1 + contrib/wpa/wpa_supplicant/mesh.c | 31 - contrib/wpa/wpa_supplicant/mesh_mpm.c | 10 +- contrib/wpa/wpa_supplicant/notify.c | 10 +- contrib/wpa/wpa_supplicant/op_classes.c | 8 +- contrib/wpa/wpa_supplicant/p2p_supplicant.c | 164 +- contrib/wpa/wpa_supplicant/p2p_supplicant.h | 5 +- contrib/wpa/wpa_supplicant/p2p_supplicant_sd.c | 4 +- contrib/wpa/wpa_supplicant/preauth_test.c | 6 +- contrib/wpa/wpa_supplicant/robust_av.c | 1332 -------------- contrib/wpa/wpa_supplicant/scan.c | 57 +- .../systemd/wpa_supplicant.service.in | 1 - contrib/wpa/wpa_supplicant/wpa_cli.c | 47 - contrib/wpa/wpa_supplicant/wpa_supplicant.c | 284 +-- contrib/wpa/wpa_supplicant/wpa_supplicant.conf | 2 +- contrib/wpa/wpa_supplicant/wpa_supplicant_i.h | 138 +- contrib/wpa/wpa_supplicant/wpas_glue.c | 2 - lib/libc/net/sctp_sys_calls.c | 6 +- libexec/rc/rc.d/Makefile | 1 + share/man/man5/src.conf.5 | 10 +- sys/conf/files | 2 - sys/conf/options | 1 - sys/dev/amdtemp/amdtemp.c | 3 +- sys/dev/bce/if_bce.c | 2 +- sys/dev/e1000/em_txrx.c | 3 +- sys/dev/e1000/if_em.h | 1 - sys/dev/hyperv/netvsc/if_hn.c | 49 +- sys/dev/hyperv/storvsc/hv_storvsc_drv_freebsd.c | 15 +- sys/dev/mlx5/mlx5_en/mlx5_en_main.c | 2 +- sys/dev/mps/mps_sas.c | 38 +- sys/fs/nfs/nfs_commonacl.c | 6 +- sys/fs/nfs/nfs_commonsubs.c | 10 + sys/fs/nfsserver/nfs_nfsdserv.c | 3 +- sys/kern/subr_bus.c | 2 +- sys/kern/subr_epoch.c | 40 +- sys/kern/subr_witness.c | 4 +- sys/kern/uipc_ktls.c | 12 +- sys/modules/i2c/Makefile | 3 +- sys/net/if.c | 3 +- sys/net/rss_config.c | 5 - sys/netinet/cc/cc.c | 7 +- sys/netinet/in_pcb.c | 1028 +++++------ sys/netinet/in_pcb.h | 319 +--- sys/netinet/in_pcb_var.h | 7 + sys/netinet/in_pcbgroup.c | 566 ------ sys/netinet/in_rss.c | 5 - sys/netinet/ip_divert.c | 75 +- sys/netinet/ip_gre.c | 18 +- sys/netinet/ip_input.c | 3 +- sys/netinet/raw_ip.c | 288 ++- sys/netinet/tcp_hpts.c | 990 +++++----- sys/netinet/tcp_hpts.h | 116 +- sys/netinet/tcp_input.c | 2 - sys/netinet/tcp_lro.c | 5 +- sys/netinet/tcp_stacks/bbr.c | 24 +- sys/netinet/tcp_stacks/rack.c | 86 +- sys/netinet/tcp_subr.c | 79 +- sys/netinet/tcp_syncache.c | 5 +- sys/netinet/tcp_timewait.c | 4 + sys/netinet/tcp_var.h | 2 - sys/netinet/udp_usrreq.c | 305 ++-- sys/netinet/udp_var.h | 10 - sys/netinet6/icmp6.c | 171 +- sys/netinet6/in6_pcb.c | 368 +--- sys/netinet6/in6_pcb.h | 10 - sys/netinet6/in6_pcbgroup.c | 153 -- sys/netinet6/in6_rss.c | 5 - sys/netinet6/ip6_gre.c | 19 +- sys/netinet6/raw_ip6.c | 169 +- sys/netinet6/udp6_usrreq.c | 281 ++- sys/sys/epoch.h | 3 + sys/sys/libkern.h | 16 + tools/build/mk/OptionalObsoleteFiles.inc | 205 ++- tools/build/options/WITHOUT_CXX | 8 +- tools/build/options/WITH_CXX | 4 +- tools/tools/git/hooks/prepare-commit-msg | 1 - 175 files changed, 4444 insertions(+), 10588 deletions(-) diff --git a/ObsoleteFiles.inc b/ObsoleteFiles.inc index ac84263ab1b7..984437f481fd 100644 --- a/ObsoleteFiles.inc +++ b/ObsoleteFiles.inc @@ -504,6 +504,8 @@ OLD_FILES+=usr/share/man/man4/iscsi_initiator.4.gz OLD_FILES+=usr/share/man/man8/iscontrol.8.gz # 20211022 +OLD_FILES+=etc/rc.d/sppp +OLD_FILES+=rescue/spppcontrol OLD_FILES+=sbin/spppcontrol .if ${TARGET_ARCH} == "i386" OLD_FILES+=usr/include/machine/cserial.h @@ -514,11 +516,26 @@ OLD_FILES+=usr/share/man/man4/ng_sppp.4.gz OLD_FILES+=usr/share/man/man4/sppp.4.gz OLD_FILES+=usr/share/man/man8/spppcontrol.8.gz +# 20211004: Removed sparc64 tests for lastcomm/sa +OLD_FILES+=usr/tests/usr.bin/lastcomm/v1-sparc64-acct.in +OLD_FILES+=usr/tests/usr.bin/lastcomm/v1-sparc64.out +OLD_FILES+=usr/tests/usr.bin/lastcomm/v2-sparc64-acct.in +OLD_FILES+=usr/tests/usr.bin/lastcomm/v2-sparc64.out +OLD_FILES+=usr/tests/usr.sbin/sa/v1-sparc64-sav.in +OLD_FILES+=usr/tests/usr.sbin/sa/v1-sparc64-sav.out +OLD_FILES+=usr/tests/usr.sbin/sa/v1-sparc64-u.out +OLD_FILES+=usr/tests/usr.sbin/sa/v1-sparc64-usr.in +OLD_FILES+=usr/tests/usr.sbin/sa/v1-sparc64-usr.out +OLD_FILES+=usr/tests/usr.sbin/sa/v2-sparc64-sav.in +OLD_FILES+=usr/tests/usr.sbin/sa/v2-sparc64-u.out +OLD_FILES+=usr/tests/usr.sbin/sa/v2-sparc64-usr.in + # 20210929: OLD_FILES+=usr/sbin/hcseriald OLD_FILES+=usr/share/man/man8/hcseriald.8.gz # 20210929: Remove ng_h4 +OLD_FILES+=usr/include/netgraph/bluetooth/include/ng_h4.h OLD_FILES+=usr/share/man/man4/ng_h4.4.gz # 20210923: rename boot(9) to kern_reboot(9) @@ -526,6 +543,8 @@ OLD_FILES+=usr/share/man/man9/boot.9.gz # 20210921: remove cloudabi OLD_FILES+=usr/share/man/man4/cloudabi.4.gz +OLD_FILES+=usr/share/man/man4/cloudabi32.4.gz +OLD_FILES+=usr/share/man/man4/cloudabi64.4.gz # 20210906: stop installing {llvm,clang,lldb}-tblgen OLD_FILES+=usr/bin/llvm-tblgen diff --git a/contrib/wpa/hostapd/config_file.c b/contrib/wpa/hostapd/config_file.c index daf3f37ad99e..9bc1dc7756e9 100644 --- a/contrib/wpa/hostapd/config_file.c +++ b/contrib/wpa/hostapd/config_file.c @@ -13,7 +13,6 @@ #include "utils/common.h" #include "utils/uuid.h" -#include "utils/crc32.h" #include "common/ieee802_11_defs.h" #include "common/sae.h" #include "crypto/sha256.h" @@ -2397,19 +2396,16 @@ static int hostapd_config_fill(struct hostapd_config *conf, wpa_printf(MSG_INFO, "Line %d: DEPRECATED: 'dump_file' configuration variable is not used anymore", line); } else if (os_strcmp(buf, "ssid") == 0) { - struct hostapd_ssid *ssid = &bss->ssid; - - ssid->ssid_len = os_strlen(pos); - if (ssid->ssid_len > SSID_MAX_LEN || ssid->ssid_len < 1) { + bss->ssid.ssid_len = os_strlen(pos); + if (bss->ssid.ssid_len > SSID_MAX_LEN || + bss->ssid.ssid_len < 1) { wpa_printf(MSG_ERROR, "Line %d: invalid SSID '%s'", line, pos); return 1; } - os_memcpy(ssid->ssid, pos, ssid->ssid_len); - ssid->ssid_set = 1; - ssid->short_ssid = crc32(ssid->ssid, ssid->ssid_len); + os_memcpy(bss->ssid.ssid, pos, bss->ssid.ssid_len); + bss->ssid.ssid_set = 1; } else if (os_strcmp(buf, "ssid2") == 0) { - struct hostapd_ssid *ssid = &bss->ssid; size_t slen; char *str = wpa_config_parse_string(pos, &slen); if (str == NULL || slen < 1 || slen > SSID_MAX_LEN) { @@ -2418,10 +2414,9 @@ static int hostapd_config_fill(struct hostapd_config *conf, os_free(str); return 1; } - os_memcpy(ssid->ssid, str, slen); - ssid->ssid_len = slen; - ssid->ssid_set = 1; - ssid->short_ssid = crc32(ssid->ssid, ssid->ssid_len); + os_memcpy(bss->ssid.ssid, str, slen); + bss->ssid.ssid_len = slen; + bss->ssid.ssid_set = 1; os_free(str); } else if (os_strcmp(buf, "utf8_ssid") == 0) { bss->ssid.utf8_ssid = atoi(pos) > 0; @@ -3520,8 +3515,6 @@ static int hostapd_config_fill(struct hostapd_config *conf, conf->he_op.he_twt_responder = atoi(pos); } else if (os_strcmp(buf, "he_rts_threshold") == 0) { conf->he_op.he_rts_threshold = atoi(pos); - } else if (os_strcmp(buf, "he_er_su_disable") == 0) { - conf->he_op.he_er_su_disable = atoi(pos); } else if (os_strcmp(buf, "he_basic_mcs_nss_set") == 0) { conf->he_op.he_basic_mcs_nss_set = atoi(pos); } else if (os_strcmp(buf, "he_mu_edca_qos_info_param_count") == 0) { @@ -4712,8 +4705,6 @@ static int hostapd_config_fill(struct hostapd_config *conf, if (get_hex_config(bss->ext_capa, EXT_CAPA_MAX_LEN, line, "ext_capa", pos)) return 1; - } else if (os_strcmp(buf, "rnr") == 0) { - bss->rnr = atoi(pos); } else { wpa_printf(MSG_ERROR, "Line %d: unknown configuration item '%s'", diff --git a/contrib/wpa/hostapd/ctrl_iface.c b/contrib/wpa/hostapd/ctrl_iface.c index 6c99a3105f49..4a2d60627070 100644 --- a/contrib/wpa/hostapd/ctrl_iface.c +++ b/contrib/wpa/hostapd/ctrl_iface.c @@ -840,7 +840,7 @@ static int hostapd_ctrl_iface_bss_tm_req(struct hostapd_data *hapd, const char *pos, *end; int disassoc_timer = 0; struct sta_info *sta; - u8 req_mode = 0, valid_int = 0x01, dialog_token = 0x01; + u8 req_mode = 0, valid_int = 0x01; u8 bss_term_dur[12]; char *url = NULL; int ret; @@ -878,12 +878,6 @@ static int hostapd_ctrl_iface_bss_tm_req(struct hostapd_data *hapd, valid_int = atoi(pos); } - pos = os_strstr(cmd, " dialog_token="); - if (pos) { - pos += 14; - dialog_token = atoi(pos); - } - pos = os_strstr(cmd, " bss_term="); if (pos) { pos += 10; @@ -990,7 +984,7 @@ static int hostapd_ctrl_iface_bss_tm_req(struct hostapd_data *hapd, #endif /* CONFIG_MBO */ ret = wnm_send_bss_tm_req(hapd, sta, req_mode, disassoc_timer, - valid_int, bss_term_dur, dialog_token, url, + valid_int, bss_term_dur, url, nei_len ? nei_rep : NULL, nei_len, mbo_len ? mbo : NULL, mbo_len); #ifdef CONFIG_MBO @@ -1461,10 +1455,10 @@ static int hostapd_ctrl_iface_set(struct hostapd_data *hapd, char *cmd) wps_version_number & 0x0f); hostapd_wps_update_ie(hapd); } - } else if (os_strcasecmp(cmd, "wps_testing_stub_cred") == 0) { - wps_testing_stub_cred = atoi(value); - wpa_printf(MSG_DEBUG, "WPS: Testing - stub_cred=%d", - wps_testing_stub_cred); + } else if (os_strcasecmp(cmd, "wps_testing_dummy_cred") == 0) { + wps_testing_dummy_cred = atoi(value); + wpa_printf(MSG_DEBUG, "WPS: Testing - dummy_cred=%d", + wps_testing_dummy_cred); } else if (os_strcasecmp(cmd, "wps_corrupt_pkhash") == 0) { wps_corrupt_pkhash = atoi(value); wpa_printf(MSG_DEBUG, "WPS: Testing - wps_corrupt_pkhash=%d", @@ -3191,9 +3185,8 @@ static int hostapd_ctrl_iface_set_neighbor(struct hostapd_data *hapd, char *buf) u8 bssid[ETH_ALEN]; struct wpabuf *nr, *lci = NULL, *civic = NULL; int stationary = 0; - int bss_parameters = 0; char *tmp; - int ret = -1; + int ret; if (!(hapd->conf->radio_measurements[0] & WLAN_RRM_CAPS_NEIGHBOR_REPORT)) { @@ -3247,7 +3240,8 @@ static int hostapd_ctrl_iface_set_neighbor(struct hostapd_data *hapd, char *buf) if (!lci) { wpa_printf(MSG_ERROR, "CTRL: SET_NEIGHBOR: Bad LCI subelement"); - goto fail; + wpabuf_free(nr); + return -1; } } @@ -3263,7 +3257,9 @@ static int hostapd_ctrl_iface_set_neighbor(struct hostapd_data *hapd, char *buf) if (!civic) { wpa_printf(MSG_ERROR, "CTRL: SET_NEIGHBOR: Bad civic subelement"); - goto fail; + wpabuf_free(nr); + wpabuf_free(lci); + return -1; } } @@ -3273,21 +3269,10 @@ static int hostapd_ctrl_iface_set_neighbor(struct hostapd_data *hapd, char *buf) if (os_strstr(buf, "stat")) stationary = 1; - tmp = os_strstr(buf, "bss_parameter="); - if (tmp) { - bss_parameters = atoi(tmp + 14); - if (bss_parameters < 0 || bss_parameters > 0xff) { - wpa_printf(MSG_ERROR, - "CTRL: SET_NEIGHBOR: Bad bss_parameters subelement"); - goto fail; - } - } - set: ret = hostapd_neighbor_set(hapd, bssid, &ssid, nr, lci, civic, - stationary, bss_parameters); + stationary); -fail: wpabuf_free(nr); wpabuf_free(lci); wpabuf_free(civic); @@ -4485,7 +4470,7 @@ static void hostapd_ctrl_iface_flush(struct hapd_interfaces *interfaces) { #ifdef CONFIG_WPS_TESTING wps_version_number = 0x20; - wps_testing_stub_cred = 0; + wps_testing_dummy_cred = 0; wps_corrupt_pkhash = 0; #endif /* CONFIG_WPS_TESTING */ diff --git a/contrib/wpa/hostapd/hlr_auc_gw.milenage_db b/contrib/wpa/hostapd/hlr_auc_gw.milenage_db index a250653108b3..c156a29aeda0 100644 --- a/contrib/wpa/hostapd/hlr_auc_gw.milenage_db +++ b/contrib/wpa/hostapd/hlr_auc_gw.milenage_db @@ -3,7 +3,7 @@ # 4.3.20 Test Set 20. SQN is the last used SQN value. # These values can be used for both UMTS (EAP-AKA) and GSM (EAP-SIM) # authentication. In case of GSM/EAP-SIM, AMF and SQN values are not used, but -# stub values will need to be included in this file. +# dummy values will need to be included in this file. # IMSI Ki OPc AMF SQN [RES_len] 232010000000000 90dca4eda45b53cf0f12d7c9c3bc6a89 cb9cccc4b9258e6dca4760379fb82581 61df 000000000000 diff --git a/contrib/wpa/hostapd/hostapd.conf b/contrib/wpa/hostapd/hostapd.conf index 67d4cefb920b..b5d15061f850 100644 --- a/contrib/wpa/hostapd/hostapd.conf +++ b/contrib/wpa/hostapd/hostapd.conf @@ -841,11 +841,6 @@ wmm_ac_vo_acm=0 # unsigned integer = duration in units of 16 us #he_rts_threshold=0 -#he_er_su_disable: Disable 242-tone HE ER SU PPDU reception by the AP -# 0 = enable reception (default) -# 1 = disable reception -#he_er_su_disable=0 - # HE operating channel information; see matching vht_* parameters for details. # he_oper_centr_freq_seg0_idx field is used to indicate center frequency of 80 # and 160 MHz bandwidth operation. In 80+80 MHz operation, it is the center @@ -1837,7 +1832,7 @@ own_ip_addr=127.0.0.1 #assoc_sa_query_retry_timeout=201 # ocv: Operating Channel Validation -# This is a countermeasure against multi-channel on-path attacks. +# This is a countermeasure against multi-channel man-in-the-middle attacks. # Enabling this depends on the driver's support for OCV when the driver SME is # used. If hostapd SME is used, this will be enabled just based on this # configuration. @@ -2921,9 +2916,6 @@ own_ip_addr=127.0.0.1 # that allows sending of such data. Default: 0. #stationary_ap=0 -# Enable reduced neighbor reporting (RNR) -#rnr=0 - ##### Airtime policy configuration ########################################### # Set the airtime policy operating mode: diff --git a/contrib/wpa/hostapd/hostapd_cli.c b/contrib/wpa/hostapd/hostapd_cli.c index 0e7fdd6bccfb..eaa628ad0676 100644 --- a/contrib/wpa/hostapd/hostapd_cli.c +++ b/contrib/wpa/hostapd/hostapd_cli.c @@ -1048,7 +1048,7 @@ static char ** hostapd_complete_set(const char *str, int pos) int arg = get_cmd_arg_num(str, pos); const char *fields[] = { #ifdef CONFIG_WPS_TESTING - "wps_version_number", "wps_testing_stub_cred", + "wps_version_number", "wps_testing_dummy_cred", "wps_corrupt_pkhash", #endif /* CONFIG_WPS_TESTING */ #ifdef CONFIG_INTERWORKING diff --git a/contrib/wpa/src/ap/acs.c b/contrib/wpa/src/ap/acs.c index 46429f265433..a112045364e3 100644 --- a/contrib/wpa/src/ap/acs.c +++ b/contrib/wpa/src/ap/acs.c @@ -309,6 +309,8 @@ acs_survey_interference_factor(struct freq_survey *survey, s8 min_nf) else if (survey->filled & SURVEY_HAS_CHAN_TIME_RX) busy = survey->channel_time_rx; else { + /* This shouldn't really happen as survey data is checked in + * acs_sanity_check() */ wpa_printf(MSG_ERROR, "ACS: Survey data missing"); return 0; } @@ -390,7 +392,7 @@ static int acs_usable_bw40_chan(const struct hostapd_channel_data *chan) static int acs_usable_bw80_chan(const struct hostapd_channel_data *chan) { - const int allowed[] = { 5180, 5260, 5500, 5580, 5660, 5745, 5955, 6035, + const int allowed[] = { 5180, 5260, 5550, 5580, 5660, 5745, 5955, 6035, 6115, 6195, 6275, 6355, 6435, 6515, 6595, 6675, 6755, 6835, 6915, 6995 }; unsigned int i; diff --git a/contrib/wpa/src/ap/ap_config.c b/contrib/wpa/src/ap/ap_config.c index 86b6e097cf89..7b6d54c35fc2 100644 --- a/contrib/wpa/src/ap/ap_config.c +++ b/contrib/wpa/src/ap/ap_config.c @@ -273,7 +273,7 @@ struct hostapd_config * hostapd_config_defaults(void) conf->he_op.he_basic_mcs_nss_set = 0xfffc; conf->he_op.he_bss_color_disabled = 1; conf->he_op.he_bss_color_partial = 0; - conf->he_op.he_bss_color = os_random() % 63 + 1; + conf->he_op.he_bss_color = 1; conf->he_op.he_twt_responder = 1; conf->he_6ghz_max_mpdu = 2; conf->he_6ghz_max_ampdu_len_exp = 7; @@ -1423,15 +1423,6 @@ static int hostapd_config_check_bss(struct hostapd_bss_config *bss, } #endif /* CONFIG_SAE_PK */ -#ifdef CONFIG_FILS - if (full_config && bss->fils_discovery_min_int && - bss->unsol_bcast_probe_resp_interval) { - wpa_printf(MSG_ERROR, - "Cannot enable both FILS discovery and unsolicited broadcast Probe Response at the same time"); - return -1; - } -#endif /* CONFIG_FILS */ - return 0; } diff --git a/contrib/wpa/src/ap/ap_config.h b/contrib/wpa/src/ap/ap_config.h index b8f791e56307..ced36f9cc828 100644 --- a/contrib/wpa/src/ap/ap_config.h +++ b/contrib/wpa/src/ap/ap_config.h @@ -894,8 +894,6 @@ struct hostapd_bss_config { u8 ext_capa_mask[EXT_CAPA_MAX_LEN]; u8 ext_capa[EXT_CAPA_MAX_LEN]; - - u8 rnr; }; /** @@ -918,7 +916,6 @@ struct he_operation { u8 he_twt_required; u8 he_twt_responder; u16 he_rts_threshold; - u8 he_er_su_disable; u16 he_basic_mcs_nss_set; }; diff --git a/contrib/wpa/src/ap/beacon.c b/contrib/wpa/src/ap/beacon.c index 22782f54e480..15fc2b3db064 100644 --- a/contrib/wpa/src/ap/beacon.c +++ b/contrib/wpa/src/ap/beacon.c @@ -469,7 +469,6 @@ static u8 * hostapd_gen_probe_resp(struct hostapd_data *hapd, } #endif /* CONFIG_IEEE80211AX */ - buflen += hostapd_eid_rnr_len(hapd, WLAN_FC_STYPE_PROBE_RESP); buflen += hostapd_mbo_ie_len(hapd); buflen += hostapd_eid_owe_trans_len(hapd); buflen += hostapd_eid_dpp_cc_len(hapd); @@ -574,7 +573,6 @@ static u8 * hostapd_gen_probe_resp(struct hostapd_data *hapd, (hapd->iconf->ieee80211ax && !hapd->conf->disable_11ax)) pos = hostapd_eid_wb_chsw_wrapper(hapd, pos); - pos = hostapd_eid_rnr(hapd, pos, WLAN_FC_STYPE_PROBE_RESP); pos = hostapd_eid_fils_indic(hapd, pos, 0); pos = hostapd_get_rsnxe(hapd, pos, epos - pos); @@ -644,8 +642,7 @@ static u8 * hostapd_gen_probe_resp(struct hostapd_data *hapd, enum ssid_match_result { NO_SSID_MATCH, EXACT_SSID_MATCH, - WILDCARD_SSID_MATCH, - CO_LOCATED_SSID_MATCH, + WILDCARD_SSID_MATCH }; static enum ssid_match_result ssid_match(struct hostapd_data *hapd, @@ -656,9 +653,7 @@ static enum ssid_match_result ssid_match(struct hostapd_data *hapd, size_t short_ssid_list_len) { const u8 *pos, *end; - struct hostapd_iface *iface = hapd->iface; int wildcard = 0; - size_t i, j; if (ssid_len == 0) wildcard = 1; @@ -692,33 +687,7 @@ static enum ssid_match_result ssid_match(struct hostapd_data *hapd, } } - if (wildcard) - return WILDCARD_SSID_MATCH; - - if (!iface->interfaces || iface->interfaces->count <= 1 || - is_6ghz_op_class(hapd->iconf->op_class)) - return NO_SSID_MATCH; - - for (i = 0; i < iface->interfaces->count; i++) { - struct hostapd_iface *colocated; - - colocated = iface->interfaces->iface[i]; - - if (colocated == iface || - !is_6ghz_op_class(colocated->conf->op_class)) - continue; - - for (j = 0; j < colocated->num_bss; j++) { - struct hostapd_bss_config *conf; - - conf = colocated->bss[j]->conf; - if (ssid_len == conf->ssid.ssid_len && - os_memcmp(ssid, conf->ssid.ssid, ssid_len) == 0) - return CO_LOCATED_SSID_MATCH; - } - } - - return NO_SSID_MATCH; + return wildcard ? WILDCARD_SSID_MATCH : NO_SSID_MATCH; } @@ -1315,8 +1284,6 @@ static u8 * hostapd_gen_fils_discovery(struct hostapd_data *hapd, size_t *len) total_len += 3; } - total_len += hostapd_eid_rnr_len(hapd, WLAN_FC_STYPE_ACTION); - pos = hostapd_eid_fils_indic(hapd, buf, 0); buf_len = pos - buf; total_len += buf_len; @@ -1385,8 +1352,6 @@ static u8 * hostapd_gen_fils_discovery(struct hostapd_data *hapd, size_t *len) /* Fill in the Length field value */ *length_pos = pos - (length_pos + 1); - pos = hostapd_eid_rnr(hapd, pos, WLAN_FC_STYPE_ACTION); - /* FILS Indication element */ if (buf_len) { os_memcpy(pos, buf, buf_len); @@ -1473,7 +1438,6 @@ int ieee802_11_build_ap_params(struct hostapd_data *hapd, } #endif /* CONFIG_IEEE80211AX */ - tail_len += hostapd_eid_rnr_len(hapd, WLAN_FC_STYPE_BEACON); tail_len += hostapd_mbo_ie_len(hapd); tail_len += hostapd_eid_owe_trans_len(hapd); tail_len += hostapd_eid_dpp_cc_len(hapd); @@ -1598,7 +1562,6 @@ int ieee802_11_build_ap_params(struct hostapd_data *hapd, (hapd->iconf->ieee80211ax && !hapd->conf->disable_11ax)) tailpos = hostapd_eid_wb_chsw_wrapper(hapd, tailpos); - tailpos = hostapd_eid_rnr(hapd, tailpos, WLAN_FC_STYPE_BEACON); tailpos = hostapd_eid_fils_indic(hapd, tailpos, 0); tailpos = hostapd_get_rsnxe(hapd, tailpos, tailend - tailpos); @@ -1780,7 +1743,7 @@ void ieee802_11_free_ap_params(struct wpa_driver_ap_params *params) } -static int __ieee802_11_set_beacon(struct hostapd_data *hapd) +int ieee802_11_set_beacon(struct hostapd_data *hapd) { struct wpa_driver_ap_params params; struct hostapd_freq_params freq; @@ -1869,42 +1832,6 @@ fail: } -int ieee802_11_set_beacon(struct hostapd_data *hapd) -{ - struct hostapd_iface *iface = hapd->iface; - int ret; - size_t i, j; - bool is_6g; - - ret = __ieee802_11_set_beacon(hapd); - if (ret != 0) - return ret; - - if (!iface->interfaces || iface->interfaces->count <= 1) - return 0; - - /* Update Beacon frames in case of 6 GHz colocation */ - is_6g = is_6ghz_op_class(iface->conf->op_class); - for (j = 0; j < iface->interfaces->count; j++) { - struct hostapd_iface *colocated; - - colocated = iface->interfaces->iface[j]; - if (colocated == iface || !colocated || !colocated->conf) - continue; - - if (is_6g == is_6ghz_op_class(colocated->conf->op_class)) - continue; - - for (i = 0; i < colocated->num_bss; i++) { - if (colocated->bss[i] && colocated->bss[i]->started) - __ieee802_11_set_beacon(colocated->bss[i]); - } - } - - return 0; -} - - int ieee802_11_set_beacons(struct hostapd_iface *iface) { size_t i; diff --git a/contrib/wpa/src/ap/ctrl_iface_ap.c b/contrib/wpa/src/ap/ctrl_iface_ap.c index 1d8fb8246581..28e40ba9cede 100644 --- a/contrib/wpa/src/ap/ctrl_iface_ap.c +++ b/contrib/wpa/src/ap/ctrl_iface_ap.c @@ -50,35 +50,9 @@ static size_t hostapd_write_ht_mcs_bitmask(char *buf, size_t buflen, } -static int hostapd_get_sta_conn_time(struct sta_info *sta, - struct hostap_sta_driver_data *data, - char *buf, size_t buflen) -{ - struct os_reltime age; - unsigned long secs; - int ret; - - if (sta->connected_time.sec) { - /* Locally maintained time in AP mode */ - os_reltime_age(&sta->connected_time, &age); - secs = (unsigned long) age.sec; - } else if (data->flags & STA_DRV_DATA_CONN_TIME) { - /* Time from the driver in mesh mode */ - secs = data->connected_sec; - } else { - return 0; - } - - ret = os_snprintf(buf, buflen, "connected_time=%lu\n", secs); - if (os_snprintf_error(buflen, ret)) - return 0; - return ret; -} - - -static int hostapd_get_sta_info(struct hostapd_data *hapd, - struct sta_info *sta, - char *buf, size_t buflen) +static int hostapd_get_sta_tx_rx(struct hostapd_data *hapd, + struct sta_info *sta, + char *buf, size_t buflen) { struct hostap_sta_driver_data data; int ret; @@ -186,12 +160,29 @@ static int hostapd_get_sta_info(struct hostapd_data *hapd, len += ret; } - len += hostapd_get_sta_conn_time(sta, &data, buf + len, buflen - len); - return len; } +static int hostapd_get_sta_conn_time(struct sta_info *sta, + char *buf, size_t buflen) +{ + struct os_reltime age; + int ret; + + if (!sta->connected_time.sec) + return 0; + + os_reltime_age(&sta->connected_time, &age); + + ret = os_snprintf(buf, buflen, "connected_time=%u\n", + (unsigned int) age.sec); + if (os_snprintf_error(buflen, ret)) + return 0; + return ret; +} + + static const char * timeout_next_str(int val) { switch (val) { @@ -272,7 +263,8 @@ static int hostapd_ctrl_iface_sta_mib(struct hostapd_data *hapd, if (res >= 0) len += res; - len += hostapd_get_sta_info(hapd, sta, buf + len, buflen - len); + len += hostapd_get_sta_tx_rx(hapd, sta, buf + len, buflen - len); + len += hostapd_get_sta_conn_time(sta, buf + len, buflen - len); #ifdef CONFIG_SAE if (sta->sae && sta->sae->state == SAE_ACCEPTED) { diff --git a/contrib/wpa/src/ap/dhcp_snoop.c b/contrib/wpa/src/ap/dhcp_snoop.c index 551936b8e43c..edc77da2e797 100644 --- a/contrib/wpa/src/ap/dhcp_snoop.c +++ b/contrib/wpa/src/ap/dhcp_snoop.c @@ -88,7 +88,6 @@ static void handle_dhcp(void *ctx, const u8 *src_addr, const u8 *buf, } } -#ifdef CONFIG_HS20 if (hapd->conf->disable_dgaf && is_broadcast_ether_addr(buf)) { for (sta = hapd->sta_list; sta; sta = sta->next) { if (!(sta->flags & WLAN_STA_AUTHORIZED)) @@ -97,7 +96,6 @@ static void handle_dhcp(void *ctx, const u8 *src_addr, const u8 *buf, (u8 *) buf, len); } } -#endif /* CONFIG_HS20 */ if (msgtype == DHCPACK) { if (b->your_ip == 0) diff --git a/contrib/wpa/src/ap/dpp_hostapd.c b/contrib/wpa/src/ap/dpp_hostapd.c index 41769f475544..93ffd8cf7c36 100644 --- a/contrib/wpa/src/ap/dpp_hostapd.c +++ b/contrib/wpa/src/ap/dpp_hostapd.c @@ -2276,8 +2276,6 @@ void hostapd_dpp_deinit(struct hostapd_data *hapd) eloop_cancel_timeout(hostapd_dpp_conn_status_result_wait_timeout, hapd, NULL); hostapd_dpp_chirp_stop(hapd); - if (hapd->iface->interfaces) - dpp_controller_stop_for_ctx(hapd->iface->interfaces->dpp, hapd); #endif /* CONFIG_DPP2 */ dpp_auth_deinit(hapd->dpp_auth); hapd->dpp_auth = NULL; @@ -2389,7 +2387,6 @@ hostapd_dpp_chirp_scan_res_handler(struct hostapd_iface *iface) unsigned int i; struct hostapd_hw_modes *mode; int c; - bool chan6 = hapd->iface->hw_features == NULL; if (!bi) return; @@ -2409,21 +2406,7 @@ hostapd_dpp_chirp_scan_res_handler(struct hostapd_iface *iface) } /* Preferred chirping channels */ - mode = dpp_get_mode(hapd, HOSTAPD_MODE_IEEE80211G); - if (mode) { - for (c = 0; c < mode->num_channels; c++) { - struct hostapd_channel_data *chan = &mode->channels[c]; - - if (chan->flag & (HOSTAPD_CHAN_DISABLED | - HOSTAPD_CHAN_RADAR) || - chan->freq != 2437) - continue; - chan6 = true; - break; - } - } - if (chan6) - int_array_add_unique(&hapd->dpp_chirp_freqs, 2437); + int_array_add_unique(&hapd->dpp_chirp_freqs, 2437); mode = dpp_get_mode(hapd, HOSTAPD_MODE_IEEE80211A); if (mode) { diff --git a/contrib/wpa/src/ap/hostapd.h b/contrib/wpa/src/ap/hostapd.h index f3ca7529ac96..07d0aaa92100 100644 --- a/contrib/wpa/src/ap/hostapd.h +++ b/contrib/wpa/src/ap/hostapd.h @@ -138,8 +138,6 @@ struct hostapd_neighbor_entry { /* LCI update time */ struct os_time lci_date; int stationary; - u32 short_ssid; - u8 bss_parameters; }; struct hostapd_sae_commit_queue { diff --git a/contrib/wpa/src/ap/hw_features.c b/contrib/wpa/src/ap/hw_features.c index 4b66b02f4e16..bb5404fa7dd4 100644 --- a/contrib/wpa/src/ap/hw_features.c +++ b/contrib/wpa/src/ap/hw_features.c @@ -838,8 +838,6 @@ static int hostapd_is_usable_edmg(struct hostapd_iface *iface) iface->freq, NULL, iface->hw_features, iface->num_hw_features); - if (!pri_chan) - return 0; hostapd_encode_edmg_chan(iface->conf->enable_edmg, iface->conf->edmg_channel, pri_chan->chan, diff --git a/contrib/wpa/src/ap/ieee802_11.c b/contrib/wpa/src/ap/ieee802_11.c index db41049287fc..22cce961063e 100644 --- a/contrib/wpa/src/ap/ieee802_11.c +++ b/contrib/wpa/src/ap/ieee802_11.c @@ -2398,7 +2398,7 @@ static int pasn_wd_handle_sae_commit(struct hostapd_data *hapd, buf_len = wpabuf_len(wd); if (buf_len < 6) { - wpa_printf(MSG_DEBUG, "PASN: SAE buffer too short. len=%zu", + wpa_printf(MSG_DEBUG, "PASN: SAE buffer too short. len=%lu", buf_len); return -1; } @@ -2474,7 +2474,7 @@ static int pasn_wd_handle_sae_confirm(struct hostapd_data *hapd, buf_len = wpabuf_len(wd); if (buf_len < 6) { - wpa_printf(MSG_DEBUG, "PASN: SAE buffer too short. len=%zu", + wpa_printf(MSG_DEBUG, "PASN: SAE buffer too short. len=%lu", buf_len); return -1; } @@ -2704,7 +2704,7 @@ static int pasn_wd_handle_fils(struct hostapd_data *hapd, struct sta_info *sta, buf_len = wpabuf_len(wd); if (buf_len < 6) { - wpa_printf(MSG_DEBUG, "PASN: FILS: Buffer too short. len=%zu", + wpa_printf(MSG_DEBUG, "PASN: FILS: Buffer too short. len=%lu", buf_len); return -1; } @@ -7071,386 +7071,4 @@ u8 * hostapd_eid_wb_chsw_wrapper(struct hostapd_data *hapd, u8 *eid) return eid; } - -static size_t hostapd_eid_nr_db_len(struct hostapd_data *hapd, - size_t *current_len) -{ - struct hostapd_neighbor_entry *nr; - size_t total_len = 0, len = *current_len; - - dl_list_for_each(nr, &hapd->nr_db, struct hostapd_neighbor_entry, - list) { - if (!nr->nr || wpabuf_len(nr->nr) < 12) - continue; - - if (nr->short_ssid == hapd->conf->ssid.short_ssid) - continue; - - /* Start a new element */ - if (!len || - len + RNR_TBTT_HEADER_LEN + RNR_TBTT_INFO_LEN > 255) { - len = RNR_HEADER_LEN; - total_len += RNR_HEADER_LEN; - } - - len += RNR_TBTT_HEADER_LEN + RNR_TBTT_INFO_LEN; - total_len += RNR_TBTT_HEADER_LEN + RNR_TBTT_INFO_LEN; - } - - *current_len = len; - return total_len; -} - - -static size_t hostapd_eid_rnr_iface_len(struct hostapd_data *hapd, - struct hostapd_data *reporting_hapd, - size_t *current_len) -{ - size_t total_len = 0, len = *current_len; - int tbtt_count = 0; - size_t i, start = 0; - - while (start < hapd->iface->num_bss) { - if (!len || - len + RNR_TBTT_HEADER_LEN + RNR_TBTT_INFO_LEN > 255) { - len = RNR_HEADER_LEN; - total_len += RNR_HEADER_LEN; - } - - len += RNR_TBTT_HEADER_LEN; - total_len += RNR_TBTT_HEADER_LEN; - - for (i = start; i < hapd->iface->num_bss; i++) { - struct hostapd_data *bss = hapd->iface->bss[i]; - - if (!bss || !bss->conf || !bss->started) - continue; - - if (bss == reporting_hapd || *** 22002 LINES SKIPPED ***