hostap issues on etch box...

fred fredmfp at gmail.com
Tue Mar 6 09:38:14 EST 2007


Hi all,

I'm trying to set up my debian box (etch, kernel 2.6.18, hostapd 0.5.5)
as a wifi ap using a DWL-520 wifi PCI card with the madwifi driver.
Note: this works fine if I use my wifi card as managed.

Bridging is enabled in my kernel.

Here is my configuration files:

1) /etc/network/interfaces:
auto lo
iface lo inet loopback

auto eth0
iface eth0 inet static
address 192.168.1.60 <http://192.168.1.60>
gateway 192.168.1.10 <http://192.168.1.10>
netmask 255.255.255.0 <http://255.255.255.0>
  up /etc/init.d/snort start eth0

iface ath0 inet static
wireless-mode master
wireless-channel 11

auto br0
iface br0 inet static
address 10.0.0.1 <http://10.0.0.1>
netmask 255.255.255.0 <http://255.255.255.0>
bridge_ports eth1 ath0
bridge_maxwait 0

2) /etc/hostapd/hostapd.conf

interface=ath0

bridge=br0

driver=madwifi

logger_syslog=-1
logger_syslog_level=2
logger_stdout=-1
logger_stdout_level=2

debug=0

dump_file=/tmp/hostapd.dump

ctrl_interface=/var/run/hostapd

ctrl_interface_group=0

ssid=myssid

max_num_sta=255
macaddr_acl=1

accept_mac_file=/etc/hostapd/hosts.allow
deny_mac_file=/etc/hostapd/hosts.deny

wme_enabled=1
wme_ac_bk_cwmin=4
wme_ac_bk_cwmax=10
wme_ac_bk_aifs=7
wme_ac_bk_txop_limit=0
wme_ac_bk_acm=0
wme_ac_be_aifs=3
wme_ac_be_cwmin=4
wme_ac_be_cwmax=10
wme_ac_be_txop_limit=0
wme_ac_be_acm=0
wme_ac_vi_aifs=2
wme_ac_vi_cwmin=3
wme_ac_vi_cwmax=4
wme_ac_vi_txop_limit=94
wme_ac_vi_acm=0
wme_ac_vo_aifs=2
wme_ac_vo_cwmin=2
wme_ac_vo_cwmax=3
wme_ac_vo_txop_limit=47
wme_ac_vo_acm=0

eapol_key_index_workaround=0

eap_server=0
own_ip_addr=127.0.0.1 <http://127.0.0.1>

wpa=3

wpa_psk=mykey

wpa_key_mgmt=WPA-PSK

wpa_pairwise=TKIP CCMP

Fisrt, when I start hostapd, it complains:

{pts/1}:~/[6]/> /etc/init.d/hostapd start
Starting advanced IEEE 802.11 management:
hostapdioctl[IEEE80211_IOCTL_SETMLME]: Invalid argument

Second, it complains that it is associated/disassociated, etc.
Here is the log file (-dd option):
Configuration file: /etc/hostapd/hostapd.conf
ctrl_interface_group=0
Configure bridge br0 for EAPOL traffic.
madwifi_set_iface_flags: dev_up=0
madwifi_set_privacy: enabled=0
Using interface ath0 with hwaddr xx:xx:xx:xx:xx:xx and ssid 'myssid'
madwifi_set_ieee8021x: enabled=1
madwifi_configure_wpa: group key cipher=1
madwifi_configure_wpa: pairwise key ciphers=0xa
madwifi_configure_wpa: key management algorithms=0x2
madwifi_configure_wpa: rsn capabilities=0x0
madwifi_configure_wpa: enable WPA=0x3
WPA: group state machine entering state GTK_INIT
GMK - hexdump(len=32): [REMOVED]
GTK - hexdump(len=32): [REMOVED]
WPA: group state machine entering state SETKEYSDONE
madwifi_set_key: alg=TKIP addr=00:00:00:00:00:00 key_idx=1
madwifi_set_privacy: enabled=1
SIOCGIWRANGE: WE(compiled)=20 WE(source)=13 enc_capa=0xf
ath0: IEEE 802.11 Fetching hardware channel/rate support not supported.
Flushing old station entries
madwifi_sta_deauth: addr=ff:ff:ff:ff:ff:ff reason_code=3
Could not connect to kernel driver.
Deauthenticate all stations
madwifi_set_iface_flags: dev_up=1
Wireless event: cmd=0x8b19 len=16
Wireless event: cmd=0x8c03 len=24
ath0: STA xx:xx:xx:xx:xx:xx IEEE 802.11: associated
  New STA
ath0: STA xx:xx:xx:xx:xx:xx WPA: event 1 notification
madwifi_del_key: addr=xx:xx:xx:xx:xx:xx key_idx=0
ath0: STA xx:xx:xx:xx:xx:xx WPA: start authentication
WPA: xx:xx:xx:xx:xx:xx WPA_PTK entering state INITIALIZE
madwifi_del_key: addr=xx:xx:xx:xx:xx:xx key_idx=0
madwifi_set_sta_authorized: addr=xx:xx:xx:xx:xx:xx authorized=0
ath0: STA xx:xx:xx:xx:xx:xx IEEE 802.1X: unauthorizing port
WPA: xx:xx:xx:xx:xx:xx WPA_PTK_GROUP entering state IDLE
WPA: xx:xx:xx:xx:xx:xx WPA_PTK entering state AUTHENTICATION
WPA: xx:xx:xx:xx:xx:xx WPA_PTK entering state AUTHENTICATION2
WPA: xx:xx:xx:xx:xx:xx WPA_PTK entering state INITPSK
WPA: xx:xx:xx:xx:xx:xx WPA_PTK entering state PTKSTART
ath0: STA xx:xx:xx:xx:xx:xx WPA: sending 1/4 msg of 4-Way Handshake
WPA: Send EAPOL(secure=0 mic=0 ack=1 install=0 pairwise=8 ie_len=0
gtk_len=0 keyidx=0 encr=0)
TX EAPOL - hexdump(len=113): 00 19 d2 5c a9 3e 00 19 5b 35 d3 22 88 8e
02 03 00 5f 02 00 8a 00 10 00 00 00 00 00 00 00 01 4a cd e3 2f 99 61 37
9a e0 fa 12 e9 74 e6 8f fb 09 19 9d ac 91 04 97 15 db 38 cc ec 90 91 c4
41 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00
ath0: STA xx:xx:xx:xx:xx:xx WPA: EAPOL-Key timeout
WPA: xx:xx:xx:xx:xx:xx WPA_PTK entering state PTKSTART
ath0: STA xx:xx:xx:xx:xx:xx WPA: sending 1/4 msg of 4-Way Handshake
WPA: Send EAPOL(secure=0 mic=0 ack=1 install=0 pairwise=8 ie_len=0
gtk_len=0 keyidx=0 encr=0)
TX EAPOL - hexdump(len=113): 00 19 d2 5c a9 3e 00 19 5b 35 d3 22 88 8e
02 03 00 5f 02 00 8a 00 10 00 00 00 00 00 00 00 02 4a cd e3 2f 99 61 37
9a e0 fa 12 e9 74 e6 8f fb 09 19 9d ac 91 04 97 15 db 38 cc ec 90 91 c4
41 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00
IEEE 802.1X: 121 bytes from xx:xx:xx:xx:xx:xx
   IEEE 802.1X: version=1 type=3 length=117
ath0: STA xx:xx:xx:xx:xx:xx WPA: received EAPOL-Key frame (2/4 Pairwise)
WPA: xx:xx:xx:xx:xx:xx WPA_PTK entering state PTKCALCNEGOTIATING
PMK - hexdump(len=32): [REMOVED]
PTK - hexdump(len=64): [REMOVED]
WPA: xx:xx:xx:xx:xx:xx WPA_PTK entering state PTKCALCNEGOTIATING2
WPA: xx:xx:xx:xx:xx:xx WPA_PTK entering state PTKINITNEGOTIATING
madwifi_get_seqnum: addr=00:00:00:00:00:00 idx=1
ath0: STA xx:xx:xx:xx:xx:xx WPA: sending 3/4 msg of 4-Way Handshake
WPA: Send EAPOL(secure=1 mic=1 ack=1 install=1 pairwise=8 ie_len=54
gtk_len=32 keyidx=1 encr=1)
Plaintext EAPOL-Key Key Data - hexdump(len=104): [REMOVED]
TX EAPOL - hexdump(len=217): 00 19 d2 5c a9 3e 00 19 5b 35 d3 22 88 8e
02 03 00 c7 02 13 ca 00 10 00 00 00 00 00 00 00 03 4a cd e3 2f 99 61 37
9a e0 fa 12 e9 74 e6 8f fb 09 19 9d ac 91 04 97 15 db 38 cc ec 90 91 c4
41 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 2f 80 95 35 a2 b3 88 93 31 4d 80 12 bf 56 fd
a1 00 68 5c dd ac d2 f8 84 4a d6 c9 30 78 da 95 f8 4d 23 b2 64 3d 65 35
81 e1 7c d4 67 d7 84 5e c0 9f 35 a0 43 86 13 be c2 1f 07 23 2f 42 f7 e2
2c 50 80 62 8b b9 0c 2d f8 6e 47 8c 12 59 aa 29 f3 f9 5e 3d 5a 14 36 7c
c9 d8 e3 30 c2 f7 1e f4 1b 72 db a2 53 43 b5 0a ed 8a 88 18 e3 a0 c5 76
82 f3 35 40 a8 43 9f 50 99 44 b2
ath0: STA xx:xx:xx:xx:xx:xx WPA: EAPOL-Key timeout
WPA: xx:xx:xx:xx:xx:xx WPA_PTK entering state PTKINITNEGOTIATING
madwifi_get_seqnum: addr=00:00:00:00:00:00 idx=1
ath0: STA xx:xx:xx:xx:xx:xx WPA: sending 3/4 msg of 4-Way Handshake
WPA: Send EAPOL(secure=1 mic=1 ack=1 install=1 pairwise=8 ie_len=54
gtk_len=32 keyidx=1 encr=1)
Plaintext EAPOL-Key Key Data - hexdump(len=104): [REMOVED]
TX EAPOL - hexdump(len=217): 00 19 d2 5c a9 3e 00 19 5b 35 d3 22 88 8e
02 03 00 c7 02 13 ca 00 10 00 00 00 00 00 00 00 04 4a cd e3 2f 99 61 37
9a e0 fa 12 e9 74 e6 8f fb 09 19 9d ac 91 04 97 15 db 38 cc ec 90 91 c4
41 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 de 80 73 21 44 56 2a 45 86 8a 59 4e 1f b1 b3
18 00 68 5c dd ac d2 f8 84 4a d6 c9 30 78 da 95 f8 4d 23 b2 64 3d 65 35
81 e1 7c d4 67 d7 84 5e c0 9f 35 a0 43 86 13 be c2 1f 07 23 2f 42 f7 e2
2c 50 80 62 8b b9 0c 2d f8 6e 47 8c 12 59 aa 29 f3 f9 5e 3d 5a 14 36 7c
c9 d8 e3 30 c2 f7 1e f4 1b 72 db a2 53 43 b5 0a ed 8a 88 18 e3 a0 c5 76
82 f3 35 40 a8 43 9f 50 99 44 b2
ath0: STA xx:xx:xx:xx:xx:xx WPA: EAPOL-Key timeout
WPA: xx:xx:xx:xx:xx:xx WPA_PTK entering state PTKINITNEGOTIATING
madwifi_get_seqnum: addr=00:00:00:00:00:00 idx=1
ath0: STA xx:xx:xx:xx:xx:xx WPA: sending 3/4 msg of 4-Way Handshake
WPA: Send EAPOL(secure=1 mic=1 ack=1 install=1 pairwise=8 ie_len=54
gtk_len=32 keyidx=1 encr=1)
Plaintext EAPOL-Key Key Data - hexdump(len=104): [REMOVED]
TX EAPOL - hexdump(len=217): 00 19 d2 5c a9 3e 00 19 5b 35 d3 22 88 8e
02 03 00 c7 02 13 ca 00 10 00 00 00 00 00 00 00 05 4a cd e3 2f 99 61 37
9a e0 fa 12 e9 74 e6 8f fb 09 19 9d ac 91 04 97 15 db 38 cc ec 90 91 c4
41 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 bf b9 57 9c 5b e8 a0 6b ef ee 7f 5d ef 6a a9
a0 00 68 5c dd ac d2 f8 84 4a d6 c9 30 78 da 95 f8 4d 23 b2 64 3d 65 35
81 e1 7c d4 67 d7 84 5e c0 9f 35 a0 43 86 13 be c2 1f 07 23 2f 42 f7 e2
2c 50 80 62 8b b9 0c 2d f8 6e 47 8c 12 59 aa 29 f3 f9 5e 3d 5a 14 36 7c
c9 d8 e3 30 c2 f7 1e f4 1b 72 db a2 53 43 b5 0a ed 8a 88 18 e3 a0 c5 76
82 f3 35 40 a8 43 9f 50 99 44 b2
ath0: STA xx:xx:xx:xx:xx:xx WPA: EAPOL-Key timeout
WPA: xx:xx:xx:xx:xx:xx WPA_PTK entering state PTKINITNEGOTIATING
madwifi_get_seqnum: addr=00:00:00:00:00:00 idx=1
ath0: STA xx:xx:xx:xx:xx:xx WPA: sending 3/4 msg of 4-Way Handshake
WPA: Send EAPOL(secure=1 mic=1 ack=1 install=1 pairwise=8 ie_len=54
gtk_len=32 keyidx=1 encr=1)
Plaintext EAPOL-Key Key Data - hexdump(len=104): [REMOVED]
TX EAPOL - hexdump(len=217): 00 19 d2 5c a9 3e 00 19 5b 35 d3 22 88 8e
02 03 00 c7 02 13 ca 00 10 00 00 00 00 00 00 00 06 4a cd e3 2f 99 61 37
9a e0 fa 12 e9 74 e6 8f fb 09 19 9d ac 91 04 97 15 db 38 cc ec 90 91 c4
41 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 ea 7f d0 67 d4 6d a3 3a a0 2d 44 2b c7 15 e9
77 00 68 5c dd ac d2 f8 84 4a d6 c9 30 78 da 95 f8 4d 23 b2 64 3d 65 35
81 e1 7c d4 67 d7 84 5e c0 9f 35 a0 43 86 13 be c2 1f 07 23 2f 42 f7 e2
2c 50 80 62 8b b9 0c 2d f8 6e 47 8c 12 59 aa 29 f3 f9 5e 3d 5a 14 36 7c
c9 d8 e3 30 c2 f7 1e f4 1b 72 db a2 53 43 b5 0a ed 8a 88 18 e3 a0 c5 76
82 f3 35 40 a8 43 9f 50 99 44 b2
WPA: xx:xx:xx:xx:xx:xx WPA_PTK entering state DISCONNECT
hostapd_wpa_auth_disconnect: WPA authenticator requests disconnect: STA
xx:xx:xx:xx:xx:xx reason 2
madwifi_sta_deauth: addr=xx:xx:xx:xx:xx:xx reason_code=2
WPA: xx:xx:xx:xx:xx:xx WPA_PTK entering state DISCONNECTED
WPA: xx:xx:xx:xx:xx:xx WPA_PTK entering state INITIALIZE
madwifi_del_key: addr=xx:xx:xx:xx:xx:xx key_idx=0
madwifi_set_sta_authorized: addr=xx:xx:xx:xx:xx:xx authorized=0
ath0: STA xx:xx:xx:xx:xx:xx IEEE 802.1X: unauthorizing port
Could not set station xx:xx:xx:xx:xx:xx flags for kernel driver (errno=29).
ath0: STA xx:xx:xx:xx:xx:xx IEEE 802.11: deauthenticated due to local
deauth request
Wireless event: cmd=0x8c02 len=108
Custom wireless event: 'STA-TRAFFIC-STAT
mac=xx:xx:xx:xx:xx:xx
rx_packets=1
rx_bytes=135
tx_packets=6
tx_bytes=1058

And so on...

Third, my kernel is very unstable when hostapd is running :-(


What's wrong ?


Any suggestion are welcome.

Thanks in advance.

Cheers,





More information about the HostAP mailing list