[PATCH 2/2] tests: NAN peer maximum SSI length in discovery result
Paul Hu
paulhu at google.com
Tue Nov 10 20:51:57 PST 2026
Verify that the subscriber reports the maximum Service Specific Info
length advertised in the publisher's DCEA.
Signed-off-by: Paul Hu <paulhu at google.com>
---
tests/hwsim/test_nan.py | 15 +++++++++++++++
1 file changed, 15 insertions(+)
diff --git a/tests/hwsim/test_nan.py b/tests/hwsim/test_nan.py
index f58dc906c..1ef025eae 100644
--- a/tests/hwsim/test_nan.py
+++ b/tests/hwsim/test_nan.py
@@ -476,6 +476,21 @@ def test_nan_sync_active_subscribe(dev, apdev, params):
pssi="aabbccdd", sssi="ddbbccaa",
unsolicited=0)
+def test_nan_sync_peer_max_ssi_len(dev, apdev, params):
+ """NAN synchronized discovery and peer maximum SSI length from DCEA"""
+ with hwsim_nan_radios(count=2) as [wpas1, wpas2], \
+ NanDevice(wpas1, "nan0") as pub, NanDevice(wpas2, "nan1") as sub:
+ pub.publish("test_service", ssi="aabbccdd", unsolicited=0)
+ sub.subscribe("test_service", ssi="ddbbccaa")
+
+ ev = sub.wpas.wait_event(["NAN-DISCOVERY-RESULT"], timeout=5)
+ if ev is None:
+ raise Exception("NAN-DISCOVERY-RESULT event not seen")
+
+ # The driver does not indicate the maximum MMPDU length, so the
+ # publisher advertises the default 1400 - (24 + 7 + 64 + 100) = 1205
+ _check_discovery_result_field(ev, "max_ssi_len", "1205")
+
def test_nan_sync_with_nmi_addresses(dev, apdev, params):
"""NAN synchronized active subscribe and solicited publish with NMI addresses"""
pnmi_addr = "40:00:00:00:17:00"
--
2.56.0.542.g3ef89b7020-goog
More information about the Hostap
mailing list