problems caused by ESSID not being set

Santiago Garcia Mantinan hostap at manty.net
Thu Jul 10 14:11:49 EDT 2003


Hi!

This came out trying to confirm that the current cvs fixed the issued that
Lubomir Gelo had reported on "prism2_rx (hostap_hw.c) patch" message. I can
confirm that this is also working here.

Anyway, testing my laptops with kismet under hostap I have discovered some
other issues, this are related to the ESSID not being sed when trying ot
enter monitor mode. I'm using Debian unstable distribution in case this
makes any difference.

I believe what I found out related to monitor mode has a lot to do with
another small issue when trying to enter mater mode, and it is that you must
set an essid to enter master, it doesn't suffice to have an essid set via
essid any as shows this example:

ace:~# iwconfig wlan0
wlan0     IEEE 802.11b  ESSID:"beta.wl"  Nickname:"ace"
          Mode:Managed  Frequency:2.412GHz  Access Point: 00:50:C2:10:90:B3  
          Bit Rate:2Mb/s   Tx-Power:7 dBm   Sensitivity=1/242700000  
          Retry min limit:8   RTS thr:off   Fragment thr:off
          Encryption key:off
          Power Management:off
          Link Quality:28/1  Signal level:-83 dBm  Noise level:-100 dBm
          Rx invalid nwid:0  Rx invalid crypt:0  Rx invalid frag:0
          Tx excessive retries:0  Invalid misc:2   Missed beacon:0
ace:~# iwconfig wlan0 mode master
Error for wireless request "Set Mode" (8B06) :
    SET failed on device wlan0 ; Invalid argument.
ace:~# iwconfig wlan0 essid beta.wl
ace:~# iwconfig wlan0 mode master
ace:~# iwconfig wlan0
wlan0     IEEE 802.11b  ESSID:"beta.wl"  Nickname:"ace"
          Mode:Master  Frequency:2.427GHz  Access Point: 00:50:C2:10:92:6A  
          Bit Rate:11Mb/s   Tx-Power:6 dBm   Sensitivity=1/242700000  
          Retry min limit:8   RTS thr:off   Fragment thr:off
          Encryption key:off
          Power Management:off
          Link Quality:28/1  Signal level:-83 dBm  Noise level:-100 dBm
          Rx invalid nwid:0  Rx invalid crypt:0  Rx invalid frag:0
          Tx excessive retries:0  Invalid misc:5   Missed beacon:0


Well, similarly, you must set an essid before getting into monitor mode, if
you don't do it and the essid is set to "" (any without having register to
any AP), you'll find that you cannot set the frequencies under monitor mode
and everything becomes borked, like I show here, even though kismet starts
up, only that the hopper is disabled because of the frequencies problem:

ace:~# iwconfig wlan0
wlan0     IEEE 802.11b  ESSID:""  Nickname:"ace"
          Mode:Managed  Frequency:2.412GHz  Access Point: 44:44:44:44:44:44  
          Bit Rate:2Mb/s   Tx-Power:-3 dBm   Sensitivity=1/242700000  
          Retry min limit:8   RTS thr:off   Fragment thr:off
          Encryption key:off
          Power Management:off
          Link Quality:0/1  Signal level:-100 dBm  Noise level:-100 dBm
          Rx invalid nwid:0  Rx invalid crypt:0  Rx invalid frag:0
          Tx excessive retries:0  Invalid misc:7   Missed beacon:0
ace:~# prism2_param wlan0 monitor_type 1
ace:~# iwconfig wlan0 mode monitor
ace:~# iwconfig wlan0 channel 6
Error for wireless request "Set Frequency" (8B04) :
    SET failed on device wlan0 ; Invalid argument.
ace:~# iwconfig wlan0 mode managed
Error for wireless request "Set Mode" (8B06) :
    SET failed on device wlan0 ; Operation not supported.

This are the messages the kernel shows:

Jul 10 19:56:12 ace kernel: prism2: wlan0: operating mode changed 2 -> 6
Jul 10 19:56:12 ace kernel: Enabling monitor mode
Jul 10 19:56:29 ace kernel: wlan0: Interrupt, but SWSUPPORT0 does not match:
0000 != 8A32 - card removed?
Jul 10 19:56:29 ace kernel: wlan0: WTERR event
Jul 10 19:56:29 ace kernel: wlan0: interrupt - SWSUPPORT0=0000 MAGIC=8a32
Jul 10 19:56:29 ace kernel: wlan0: scheduled card reset
Jul 10 19:56:29 ace kernel: hostap_cs: wlan0: resetting card
Jul 10 19:56:29 ace kernel: prism2_pccard_cor_sreset: original COR 00
Jul 10 19:56:29 ace kernel: wlan0: removed pending cmd_queue entry (type=0,
cmd=0x0121, param0=0xfc03)
Jul 10 19:56:29 ace kernel: prism2_hw_init()
Jul 10 19:56:29 ace kernel: hostap_cs: card initialization timed out
Jul 10 19:56:29 ace kernel: hostap_cs: Initialization failed
Jul 10 19:56:30 ace kernel: wlan0: hfa384x_cmd: command was not completed
(res=0, entry=c29aafa0, type=0, cmd=0x0121, param0=0xfc03, EVSTAT=0000
INTEN=0000)
Jul 10 19:56:30 ace kernel: wlan0: hfa384x_set_rid: CMDCODE_ACCESS_WRITE
failed (res=-110, rid=fc03, len=2)
Jul 10 19:58:26 ace kernel: wlan0: Disabling monitor mode
Jul 10 19:58:28 ace kernel: wlan0: hfa384x_cmd: entry still in list?
(entry=c29aafa0, type=0, res=0)
Jul 10 19:58:28 ace kernel: wlan0: hfa384x_cmd: command was not completed
(res=0, entry=c29aafa0, type=0, cmd=0x0f38, param0=0x0000, EVSTAT=0000
INTEN=0000)
Jul 10 19:58:28 ace kernel: prism2: wlan0: operating mode changed 6 -> 2
Jul 10 19:58:30 ace kernel: wlan0: hfa384x_cmd: entry still in list?
(entry=c29aafa0, type=0, res=0)
Jul 10 19:58:30 ace kernel: wlan0: hfa384x_cmd: command was not completed
(res=0, entry=c29aafa0, type=0, cmd=0x0121, param0=0xfc00, EVSTAT=0000
INTEN=0000)
Jul 10 19:58:30 ace kernel: wlan0: hfa384x_set_rid: CMDCODE_ACCESS_WRITE
failed (res=-110, rid=fc00, len=2)

If the essid was any but we are now associated to an AP the user interaction
seems the same, except that kismet doesn't start up at all, only the server
is left around in background, and the kernel messages are completely
different, they look like this:

Jul 10 20:02:48 ace kernel: prism2: wlan0: operating mode changed 2 -> 6
Jul 10 20:02:48 ace kernel: Enabling monitor mode
Jul 10 20:03:02 ace kernel: wlan0: hfa384x_setup_bap - timeout after
Jul 10 20:03:02 ace kernel: wlan0: hfa384x_set_rid (rid=fc03, len=2) -
failed - res=-110
Jul 10 20:03:43 ace kernel: wlan0: Disabling monitor mode
Jul 10 20:03:45 ace kernel: wlan0: hfa384x_cmd: entry still in list?
(entry=c29aaa20, type=0, res=0)
Jul 10 20:03:45 ace kernel: wlan0: hfa384x_cmd: command was not completed
(res=0, entry=c29aaa20, type=0, cmd=0x0f38, param0=0x0000, EVSTAT=0000
INTEN=e09f)
Jul 10 20:03:45 ace kernel: prism2: wlan0: operating mode changed 6 -> 2
Jul 10 20:03:45 ace kernel: wlan0: hfa384x_setup_bap - timeout before
Jul 10 20:03:45 ace kernel: wlan0: hfa384x_set_rid (rid=fc00, len=2) -
failed - res=-110

I have solved this by adding a iwconfig wlan0 essid test to the
kismet_monitor script before doing any other thing, but I believe that the
problem is really on the driver, comments?

Well, hope this helps a bit.

Regards...
-- 
Manty/BestiaTester -> http://manty.net



More information about the HostAP mailing list