Added a place for example mac80211_hwsim test cases
The tests directory and its subdirectories contain a set of configuration files that can be used to exercise various mac80211, hostapd, and wpa_supplicant features. The test.txt file in each test directory describes the particular test and includes the commands needed to run the test.
This commit is contained in:
parent
271d2830ff
commit
b3f240bc0e
7 changed files with 58 additions and 0 deletions
11
mac80211_hwsim/tests/0001-wpa2-psk/hostapd.conf
Normal file
11
mac80211_hwsim/tests/0001-wpa2-psk/hostapd.conf
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
interface=wlan0
|
||||||
|
driver=nl80211
|
||||||
|
|
||||||
|
hw_mode=g
|
||||||
|
channel=1
|
||||||
|
ssid=mac80211 test
|
||||||
|
|
||||||
|
wpa=2
|
||||||
|
wpa_key_mgmt=WPA-PSK
|
||||||
|
wpa_pairwise=CCMP
|
||||||
|
wpa_passphrase=12345678
|
7
mac80211_hwsim/tests/0001-wpa2-psk/test.txt
Normal file
7
mac80211_hwsim/tests/0001-wpa2-psk/test.txt
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
# WPA2-Personal (PSK) with CCMP, AP and single client
|
||||||
|
|
||||||
|
modprobe mac80211_hwsim
|
||||||
|
|
||||||
|
hostapd hostapd.conf
|
||||||
|
|
||||||
|
wpa_supplicant -Dwext -iwlan1 -c wpa_supplicant.conf
|
10
mac80211_hwsim/tests/0001-wpa2-psk/wpa_supplicant.conf
Normal file
10
mac80211_hwsim/tests/0001-wpa2-psk/wpa_supplicant.conf
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
ctrl_interface=/var/run/wpa_supplicant
|
||||||
|
|
||||||
|
network={
|
||||||
|
ssid="mac80211 test"
|
||||||
|
psk="12345678"
|
||||||
|
key_mgmt=WPA-PSK
|
||||||
|
proto=WPA2
|
||||||
|
pairwise=CCMP
|
||||||
|
group=CCMP
|
||||||
|
}
|
2
mac80211_hwsim/tests/0002-vlan/hostapd.accept
Normal file
2
mac80211_hwsim/tests/0002-vlan/hostapd.accept
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
02:00:00:00:01:00 1
|
||||||
|
02:00:00:00:02:00 2
|
12
mac80211_hwsim/tests/0002-vlan/hostapd.conf
Normal file
12
mac80211_hwsim/tests/0002-vlan/hostapd.conf
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
interface=wlan0
|
||||||
|
driver=nl80211
|
||||||
|
|
||||||
|
hw_mode=g
|
||||||
|
channel=1
|
||||||
|
ssid=mac80211 test
|
||||||
|
|
||||||
|
dynamic_vlan=2
|
||||||
|
vlan_file=hostapd.vlan
|
||||||
|
|
||||||
|
macaddr_acl=0
|
||||||
|
accept_mac_file=hostapd.accept
|
1
mac80211_hwsim/tests/0002-vlan/hostapd.vlan
Normal file
1
mac80211_hwsim/tests/0002-vlan/hostapd.vlan
Normal file
|
@ -0,0 +1 @@
|
||||||
|
* vlan#
|
15
mac80211_hwsim/tests/0002-vlan/test.txt
Normal file
15
mac80211_hwsim/tests/0002-vlan/test.txt
Normal file
|
@ -0,0 +1,15 @@
|
||||||
|
# Plaintext connection, two clients, different VLANs
|
||||||
|
|
||||||
|
modprobe mac80211_hwsim radios=3
|
||||||
|
|
||||||
|
hostapd hostapd.conf
|
||||||
|
|
||||||
|
ifconfig wlan1 up
|
||||||
|
iwconfig wlan1 essid "mac80211 test"
|
||||||
|
|
||||||
|
ifconfig wlan2 up
|
||||||
|
iwconfig wlan2 essid "mac80211 test"
|
||||||
|
|
||||||
|
# Expected results:
|
||||||
|
# STA1(wlan1) is bound to vlan1
|
||||||
|
# STA2(wlan2) is bound to vlan2
|
Loading…
Reference in a new issue