mirror of
https://github.com/vanhoefm/fragattacks.git
synced 2024-11-25 00:38:24 -05:00
tests: Move vht_supported() into utils.py
Signed-off-by: Jouni Malinen <j@w1.fi>
This commit is contained in:
parent
31bdd8b7c7
commit
1bba048d78
@ -16,7 +16,6 @@ from hostapd import Hostapd
|
||||
import hostapd
|
||||
from utils import *
|
||||
from wlantest import Wlantest
|
||||
from test_ap_vht import vht_supported
|
||||
|
||||
def start_ap_wpa2_psk(ap):
|
||||
params = hostapd.wpa2_params(ssid="test-wpa2-psk", passphrase="12345678")
|
||||
|
@ -18,13 +18,6 @@ from test_dfs import wait_dfs_event
|
||||
from test_ap_csa import csa_supported
|
||||
from test_ap_ht import clear_scan_cache
|
||||
|
||||
def vht_supported():
|
||||
cmd = subprocess.Popen(["iw", "reg", "get"], stdout=subprocess.PIPE)
|
||||
reg = cmd.stdout.read()
|
||||
if "@ 80)" in reg or "@ 160)" in reg:
|
||||
return True
|
||||
return False
|
||||
|
||||
def test_ap_vht80(dev, apdev):
|
||||
"""VHT with 80 MHz channel width"""
|
||||
try:
|
||||
|
@ -16,11 +16,9 @@ import time
|
||||
|
||||
import hostapd
|
||||
from wpasupplicant import WpaSupplicant
|
||||
from utils import HwsimSkip, alloc_fail, fail_test, wait_fail_trigger
|
||||
from utils import disable_hapd, clear_regdom_dev, clear_regdom
|
||||
from utils import *
|
||||
from test_ap_ht import clear_scan_cache
|
||||
from remotehost import remote_compatible
|
||||
from test_ap_vht import vht_supported
|
||||
|
||||
def check_rrm_support(dev):
|
||||
rrm = int(dev.get_driver_status_field("capa.rrm_flags"), 16)
|
||||
|
@ -112,6 +112,13 @@ def check_sae_capab(dev):
|
||||
if "SAE" not in dev.get_capability("auth_alg"):
|
||||
raise HwsimSkip("SAE not supported")
|
||||
|
||||
def vht_supported():
|
||||
cmd = subprocess.Popen(["iw", "reg", "get"], stdout=subprocess.PIPE)
|
||||
reg = cmd.stdout.read()
|
||||
if "@ 80)" in reg or "@ 160)" in reg:
|
||||
return True
|
||||
return False
|
||||
|
||||
def get_phy(ap, ifname=None):
|
||||
phy = "phy3"
|
||||
try:
|
||||
|
Loading…
Reference in New Issue
Block a user