]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
dpp-nfc: Own MAC address fetching from hostapd
authorJouni Malinen <jouni@codeaurora.org>
Thu, 14 May 2020 21:44:27 +0000 (00:44 +0300)
committerJouni Malinen <j@w1.fi>
Thu, 14 May 2020 21:44:27 +0000 (00:44 +0300)
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
wpa_supplicant/examples/dpp-nfc.py

index 2f220f96427605fbcf5d97e6741580ff5da36a62..4f64bc25006e0334a3a059bc1ddbab2717fae3ff 100755 (executable)
@@ -144,7 +144,10 @@ def get_status_field(wpas, field, extra=None):
     return None
 
 def own_addr(wpas):
-    return get_status_field(wpas, "address")
+    addr = get_status_field(wpas, "address")
+    if addr is None:
+        addr = get_status_field(wpas, "bssid[0]")
+    return addr
 
 def dpp_bootstrap_gen(wpas, type="qrcode", chan=None, mac=None, info=None,
                       curve=None, key=None):