Hostap and MD5 and wep key

Carlos Peñafiel carpeher
Wed May 17 04:27:55 PDT 2006


Hello, I have a problem with my hostap.
The configuration file is the following:

file "madwifi.conf"

interface=ath0
bridge=wifi0
driver=madwifi
logger_syslog=-1
logger_syslog_level=4
logger_stdout=-1
logger_stdout_level=4
debug=4
dump_file=/tmp/hostapd.dump
ssid=pfc
ieee8021x=1
eap_message=hello
eapol_key_index_workaround=0
own_ip_addr=127.0.0.1
auth_server_addr=127.0.0.1
auth_server_port=1812
auth_server_shared_secret=carpeher
acct_server_addr=127.0.0.1
acct_server_port=1813
acct_server_shared_secret=carpeher

I have this log when I do the following:

[root at inf-205-91 hostapd-0.4.8]# hostapd -dd -K -t madwifi.conf
Configuration file: madwifi.conf
Configure bridge wifi0 for EAPOL traffic.
madwifi_set_iface_flags: dev_up=0
Using interface ath0 with hwaddr 00:13:46:e3:1e:81 and ssid 'pfc'
May 17 12:55:57.054853: ath0: RADIUS Authentication server 127.0.0.1:1812
May 17 12:55:57.055170: ath0: RADIUS Accounting server 127.0.0.1:1813
madwifi_set_ieee8021x: enabled=1
madwifi_set_iface_flags: dev_up=1
RADIUS message: code=4 (Accounting-Request) identifier=0 length=67
   Attribute 40 (Acct-Status-Type) length=6
      Value: 7
   Attribute 45 (Acct-Authentic) length=6
      Value: 1
   Attribute 4 (NAS-IP-Address) length=6
      Value: 127.0.0.1
   Attribute 30 (Called-Station-Id) length=23
      Value: '00-13-46-E3-1E-81:pfc'
   Attribute 49 (Acct-Terminate-Cause) length=6
      Value: 11
Flushing old station entries
madwifi_sta_deauth: addr=ff:ff:ff:ff:ff:ff reason_code=3
Deauthenticate all stations
l2_packet_receive - recvfrom: Network is down
l2_packet_receive - recvfrom: Network is down
RADIUS message: code=5 (Accounting-Response) identifier=0 length=20
Wireless event: cmd=0x8b19 len=12


You can realize that I have the message "Network is down". I dont know why 
that happends, because the interface is up (I have the same message wheather 
the interface is up either is down). The last line "Wireless event: 
cmd=0x8b19 len=12" happens when I do "ifconfig ath0 up"
Now, I do:

[root at inf-205-91 hostapd-0.4.8]# iwconfig ath0
ath0      IEEE 802.11g  ESSID:"pfc"
          Mode:Master  Frequency:2.412 GHz  Access Point: 00:13:46:E3:1E:81
          Bit Rate:0 kb/s   Tx-Power:18 dBm   Sensitivity=0/3
          Retry:off   RTS thr:off   Fragment thr:off
          Encryption key:off
          Power Management:off
          Link Quality=0/94  Signal level=-95 dBm  Noise level=-95 dBm
          Rx invalid nwid:42  Rx invalid crypt:0  Rx invalid frag:0
          Tx excessive retries:0  Invalid misc:0   Missed beacon:0

Notice that "Encryption key:off"


No, I try to connect my client. (Wireless pcmcia card, Orinoco, firmware 
Lucent/Agare 7.28, but I have tried also with my ipw2200bg, and I have the 
same problem).

I do on my client:

[root at inf-205-245 ~]# iwlist eth2 scanning
eth2      Scan completed :
          Cell 01 - Address: 00:13:46:E3:1E:81
                    ESSID:"pfc"
                    Mode:Master
                    Frequency:2.412 GHz (Channel 1)
                    Signal level:-73 dBm  Noise level:-66 dBm
                    Encryption key:on


Notice that here happears "Encryption key:on".

So, that is my first question, why?

Good, I thought I am going to do the following on the hostap:

[root at inf-205-91 hostapd-0.4.8]# iwconfig ath0 key off

and I had the following:

Wireless event: cmd=0x8b2a len=12
Wireless event: cmd=0x8b19 len=12

good, maybe it was a good idea xD, because on the client i have:

[root at inf-205-245 ~]# iwlist eth2 scanning
eth2      Scan completed :
          Cell 02 - Address: 00:13:46:E3:1E:81
                    ESSID:"pfc"
                    Mode:Master
                    Frequency:2.412 GHz (Channel 1)
                    Signal level:-75 dBm  Noise level:-97 dBm
                    Encryption key:off


hehe, awesome!, but when I do on the client:

[root at inf-205-245 etc]# iwconfig eth2 essid pfc

and the hostap gets crazy like:


May 17 13:12:56.143328: ath0: STA 00:02:2d:66:67:d2 IEEE 802.11: associated
  New STA
IEEE 802.1X: 00:02:2d:66:67:d2 AUTH_PAE entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 BE_AUTH entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 AUTH_KEY_TX entering state NO_KEY_TRANSMIT
IEEE 802.1X: 00:02:2d:66:67:d2 KEY_RX entering state NO_KEY_RECEIVE
IEEE 802.1X: 00:02:2d:66:67:d2 CTRL_DIR entering state IN_OR_BOTH
IEEE 802.1X: 00:02:2d:66:67:d2 AUTH_PAE entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 BE_AUTH entering state IDLE
IEEE 802.1X: 00:02:2d:66:67:d2 KEY_RX entering state NO_KEY_RECEIVE
IEEE 802.1X: 00:02:2d:66:67:d2 CTRL_DIR entering state FORCE_BOTH
IEEE 802.1X: 00:02:2d:66:67:d2 AUTH_PAE entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 KEY_RX entering state NO_KEY_RECEIVE
IEEE 802.1X: 00:02:2d:66:67:d2 AUTH_PAE entering state DISCONNECTED
madwifi_set_sta_authorized: addr=00:02:2d:66:67:d2 authorized=0
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 AUTH_PAE entering state RESTART
IEEE 802.1X: station 00:02:2d:66:67:d2 - new auth session, clearing State
IEEE 802.1X: Generated EAP Request-Identity for 00:02:2d:66:67:d2 
(identifier 0, timeout 30)
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 AUTH_PAE entering state CONNECTING
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 AUTH_PAE entering state AUTHENTICATING
IEEE 802.1X: 00:02:2d:66:67:d2 BE_AUTH entering state REQUEST
IEEE 802.1X: Sending EAP Packet to 00:02:2d:66:67:d2 (identifier 0)
TX EAPOL - hexdump(len=28): 00 02 2d 66 67 d2 00 13 46 e3 1e 81 88 8e 02 00 
00 0a 01 00 00 0a 01 68 65 6c 6c 6f
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 BE_AUTH entering state TIMEOUT
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 AUTH_PAE entering state ABORTING
IEEE 802.1X: 00:02:2d:66:67:d2 BE_AUTH entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 AUTH_PAE entering state RESTART
IEEE 802.1X: station 00:02:2d:66:67:d2 - new auth session, clearing State
IEEE 802.1X: Generated EAP Request-Identity for 00:02:2d:66:67:d2 
(identifier 1, timeout 30)
IEEE 802.1X: 00:02:2d:66:67:d2 BE_AUTH entering state IDLE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 AUTH_PAE entering state CONNECTING
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 AUTH_PAE entering state AUTHENTICATING
IEEE 802.1X: 00:02:2d:66:67:d2 BE_AUTH entering state REQUEST
IEEE 802.1X: Sending EAP Packet to 00:02:2d:66:67:d2 (identifier 1)
TX EAPOL - hexdump(len=28): 00 02 2d 66 67 d2 00 13 46 e3 1e 81 88 8e 02 00 
00 0a 01 01 00 0a 01 68 65 6c 6c 6f
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 BE_AUTH entering state TIMEOUT
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 AUTH_PAE entering state ABORTING
IEEE 802.1X: 00:02:2d:66:67:d2 BE_AUTH entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 AUTH_PAE entering state RESTART
IEEE 802.1X: station 00:02:2d:66:67:d2 - new auth session, clearing State
IEEE 802.1X: Generated EAP Request-Identity for 00:02:2d:66:67:d2 
(identifier 2, timeout 30)
IEEE 802.1X: 00:02:2d:66:67:d2 BE_AUTH entering state IDLE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 AUTH_PAE entering state CONNECTING
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 AUTH_PAE entering state DISCONNECTED
madwifi_set_sta_authorized: addr=00:02:2d:66:67:d2 authorized=0
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 AUTH_PAE entering state RESTART
IEEE 802.1X: station 00:02:2d:66:67:d2 - new auth session, clearing State
IEEE 802.1X: Generated EAP Request-Identity for 00:02:2d:66:67:d2 
(identifier 3, timeout 30)
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 AUTH_PAE entering state CONNECTING
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 AUTH_PAE entering state AUTHENTICATING
IEEE 802.1X: 00:02:2d:66:67:d2 BE_AUTH entering state REQUEST
IEEE 802.1X: Sending EAP Packet to 00:02:2d:66:67:d2 (identifier 3)
TX EAPOL - hexdump(len=28): 00 02 2d 66 67 d2 00 13 46 e3 1e 81 88 8e 02 00 
00 0a 01 03 00 0a 01 68 65 6c 6c 6f
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE
IEEE 802.1X: 00:02:2d:66:67:d2 REAUTH_TIMER entering state INITIALIZE


Until I press "control + x"


Signal 2 received - terminating
Removing station 00:02:2d:66:67:d2
Flushing old station entries
madwifi_sta_deauth: addr=ff:ff:ff:ff:ff:ff reason_code=3
Deauthenticate all stations
RADIUS message: code=4 (Accounting-Request) identifier=1 length=67
   Attribute 40 (Acct-Status-Type) length=6
      Value: 8
   Attribute 45 (Acct-Authentic) length=6
      Value: 1
   Attribute 4 (NAS-IP-Address) length=6
      Value: 127.0.0.1
   Attribute 30 (Called-Station-Id) length=23
      Value: '00-13-46-E3-1E-81:pfc'
   Attribute 49 (Acct-Terminate-Cause) length=6
      Value: 11
madwifi_set_privacy: enabled=0
madwifi_set_ieee8021x: enabled=0
madwifi_set_iface_flags: dev_up=0

Also, I have tries to do something with the xsupplicant, with the following 
configuration file:

(my xsupplicant configuration)

network_list = all
default_netname = default
logfile = /var/log/xsupplicant.log
default
{
  type = wireless
  allow_types = all
  identity = root
  eap-md5 {
      username = root
      password = carpeher
  }
}

but it doesnt work either.

so, could anyone please help me? I am stopped here and I dont know how to 
follow.

Thank you in advance.






More information about the Hostap mailing list