mirror of
https://github.com/vanhoefm/fragattacks.git
synced 2025-01-31 01:04:03 -05:00
tests: Prepare ap_wps_per_station_psk for the new wps=1 tag in PSK file
Signed-off-by: Jouni Malinen <j@w1.fi>
This commit is contained in:
parent
fde8e79463
commit
68e9b8cb16
@ -2161,7 +2161,15 @@ def get_psk(pskfile):
|
||||
for l in lines:
|
||||
if l == "# WPA PSKs":
|
||||
continue
|
||||
(addr, psk) = l.split(' ')
|
||||
vals = l.split(' ')
|
||||
if len(vals) == 2:
|
||||
addr = vals[0]
|
||||
psk = vals[1]
|
||||
elif len(vals) == 3 and vals[0] == "wps=1":
|
||||
addr = vals[1]
|
||||
psk = vals[2]
|
||||
else:
|
||||
continue
|
||||
psks[addr] = psk
|
||||
return psks
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user