3
0
mirror of https://git.kernel.org/pub/scm/network/wireless/iwd.git synced 2024-12-22 04:32:37 +01:00

ap: Accept P2P wildcard SSIDs in probe requests

Add the special case "DIRECT-" SSID, called the P2P Wildcard SSID, in
ap_probe_req_cb so as not to reject those Probe Requests on the basis of
ssid mismatch.  I'd have preferred to keep all the P2P-specific bits in
p2p.c but in this case there's little point in adding a generic
config setting for SSID-matching quirks.
This commit is contained in:
Andrew Zaborowski 2020-09-09 01:49:28 +02:00 committed by Denis Kenzior
parent 0d2d34c353
commit c7b072ff21

View File

@ -1682,6 +1682,9 @@ static void ap_probe_req_cb(const struct mmpdu_header *hdr, const void *body,
else if (ssid && ssid_len == strlen(ap->config->ssid) && /* One SSID */
!memcmp(ssid, ap->config->ssid, ssid_len))
match = true;
else if (ssid && ssid_len == 7 && !memcmp(ssid, "DIRECT-", 7) &&
!memcmp(ssid, ap->config->ssid, 7)) /* P2P wildcard */
match = true;
else if (ssid_list) { /* SSID List */
ie_tlv_iter_init(&iter, ssid_list, ssid_list_len);