Discussion:
802.11 "monitor mode" issues
(too old to reply)
s***@errno.com
2004-02-20 22:49:46 UTC
Permalink
In the man pages of "ifconfig" it states that "monitor"...
"Put the interface in monitor mode. No packets are transmitted,
and received packets are discarded after bpf(4) processing."
Now, using
ifconfig ath0 monitor up
does not seem to be doing that.
The monitor thing is totally bogus; it should be removed. You want to do the
following:

ifconfig ath0 mediaopt monitor <other stuff> up

(where other stuff might be commands to set the channel). At that point you
can run programs like Ethereal and tcpdump w/o the driver trying to associate
with an AP.

If you get the latest ethereal from CVS it has radiotap support which lets you
look at frames "below the 802.11 layer". The tcpdump port likewise has
radiotap support; you do

tcpdump -i ath0 -y IEEE802_11_RADIO

(I think, this is from memory).

Sam
K***@compuware.com
2004-02-23 16:43:27 UTC
Permalink
Sam,

Thanks for your reply.

I tried it and did not see ANY debug info this time. I think that's a good
thing. But on the 'ifconfig' output, the 'status' field stated that it was
'associated'. Just an observation.

Also, am I to assume that the 'monitor mode' itself, does not increment thru
the channels, it has to be done via the 'ifconfig' or ioctl in a program?

Thanks,

Kevin

-----Original Message-----
From: Sam Leffler [mailto:***@errno.com]
Sent: Friday, February 20, 2004 5:46 PM
To: Adams, Kevin; 'freebsd-***@freebsd.org'
Subject: Re: 802.11 "monitor mode" issues
In the man pages of "ifconfig" it states that "monitor"...
"Put the interface in monitor mode. No packets are transmitted, and
received packets are discarded after bpf(4) processing."
Now, using
ifconfig ath0 monitor up
does not seem to be doing that.
The monitor thing is totally bogus; it should be removed. You want to do
the
following:

ifconfig ath0 mediaopt monitor <other stuff> up

(where other stuff might be commands to set the channel). At that point you
can run programs like Ethereal and tcpdump w/o the driver trying to
associate with an AP.

If you get the latest ethereal from CVS it has radiotap support which lets
you look at frames "below the 802.11 layer". The tcpdump port likewise has
radiotap support; you do

tcpdump -i ath0 -y IEEE802_11_RADIO

(I think, this is from memory).

Sam



The contents of this e-mail are intended for the named addressee only. It
contains information that may be confidential. Unless you are the named
addressee or an authorized designee, you may not copy or use it, or disclose
it to anyone else. If you received it in error please notify us immediately
and then destroy it.
s***@errno.com
2004-02-23 17:26:34 UTC
Permalink
Post by K***@compuware.com
Sam,
Thanks for your reply.
I tried it and did not see ANY debug info this time. I think that's a good
thing. But on the 'ifconfig' output, the 'status' field stated that it was
'associated'. Just an observation.
Also, am I to assume that the 'monitor mode' itself, does not increment
thru the channels, it has to be done via the 'ifconfig' or ioctl in a
program?
Correct. kismet or similar will scan channels or you can do it manually with
ifconfig (something I routinely do--start a tcpdump or ethereal and then go
to another window and switch channels).

Sam
w***@osu.edu
2004-02-25 19:29:41 UTC
Permalink
I'm running -current dated 2-23-04. When I try this with my SMC2632 card, I
sudo ifconfig wi0 mediaopt monitor
ifconfig: SIOCGIFMEDIA: Operation not supported by device

In fact, I get the same error when I try a lot of the different options for
'mediaopt', even the ones I find listed from 'ifconfig -m wi0'
Ideas?

Thanks!
Aaron
The monitor thing is totally bogus; it should be removed. You want to do the
ifconfig ath0 mediaopt monitor <other stuff> up
i***@bsdimp.com
2004-02-29 21:20:09 UTC
Permalink
In message: <089401c3fbd5$83f4a500$***@gswa.tld>
"A. Wright" <***@osu.edu> writes:
: I'm running -current dated 2-23-04. When I try this with my SMC2632 card, I
: get the following:
:
: >sudo ifconfig wi0 mediaopt monitor
: ifconfig: SIOCGIFMEDIA: Operation not supported by device
:
: In fact, I get the same error when I try a lot of the different options for
: 'mediaopt', even the ones I find listed from 'ifconfig -m wi0'
: Ideas?

specify media.

Warner
w***@osu.edu
2004-03-02 17:02:43 UTC
Permalink
I just installed 5.2-Release to be sure it wasn't something I didn't
understand in -current. I insert the card and then run these commands.
Here's what I got.

# uname -a
FreeBSD LAPTOP.domain.com 5.2-RELEASE FreeBSD 5.2-RELEASE #0: Sun Jan 11
04:21:45 GMT 2004 ***@wv1u.btc.adaptec.com:/usr/obj/usr/src/sys/GENERIC
i386
# ifconfig wi0
wi0: flags=8802<BROADCAST,SIMPLEX,MULTICAST> mtu 1500
ether 00:04:e2:1e:0c:de
media: IEEE 802.11 Wireless Ethernet autoselect (none)
ssid ""
stationname "FreeBSD WaveLAN/IEEE node"
channel -1 authmode OPEN powersavemode OFF powersavesleep 100
wepmode OFF weptxkey 1
# ifconfig wi0 media DS/11Mbps mediaopt monitor
ifconfig: SIOCSIFMEDIA (mediaopt): Device not configured
# ifconfig wi0 inet 192.168.0.10 netmask 0xffffff00 ssid my_ap media
DS/11Mbps mediaopt hostap
ifconfig: SIOCSIFMEDIA (mediaopt): Device not configured

That last command is directly from the man page for wi(4) for 5.2-Release.
Do I have to add anything to the kernel? I certainly don't rule out that
it's something that I'm doing wrong. So if anyone can point out to me how
to fix this, I'd appreciate it.

Thanks for your time.
Aaron


----- Original Message -----
From: "M. Warner Losh" <***@bsdimp.com>
To: <***@osu.edu>
Cc: <freebsd-***@freebsd.org>
Sent: Sunday, February 29, 2004 4:18 PM
Subject: Re: 802.11 "monitor mode" issues
Post by i***@bsdimp.com
: I'm running -current dated 2-23-04. When I try this with my SMC2632 card, I
: >sudo ifconfig wi0 mediaopt monitor
: ifconfig: SIOCGIFMEDIA: Operation not supported by device
: In fact, I get the same error when I try a lot of the different options for
: 'mediaopt', even the ones I find listed from 'ifconfig -m wi0'
: Ideas?
specify media.
Warner
Loading...