monrandria
Posts: 2
Joined: Fri Jan 15, 2016 10:16 pm

WiFi dongle with monitor mode?

Mon Jan 18, 2016 3:50 pm

I just assembled my Raspberry Pi, pretty cool. I'd like to watch the traffic to/from an Amazon dash button.

Like many others, I got the Edimax EW-7811Un. When I try to set it to monitor mode, I get:

Code: Select all

pi@rpi:~ $ sudo iwconfig wlan0 mode monitor
Error for wireless request "Set Mode" (8B06) :
    SET failed on device wlan0 ; Invalid argument.
pi@rpi:~ $ sudo iw dev wlan0 interface add mon0 type monitor
command failed: Invalid argument (-22)
Some searches have led to a lot of people having similar problems. There are some suggestions that by compiling your own kernel modules, you may or may not get this to work. There are other suggestions that you compile the creepy-sounding aircrack. However, I wasn't really looking to embark on Mr Toad's Wild Ride unless necessary...

A) The dongle is still well within the return window. If I returned it, can anyone suggest a dongle for which monitor mode works well with Raspberry Pi "out of the box"?

B) If the Edimax is my best option, does anyone know how successful either kernel module tomfoolery or "aircrack" is likely to be?

Thanks!

monrandria
Posts: 2
Joined: Fri Jan 15, 2016 10:16 pm

Re: WiFi dongle with monitor mode?

Mon Jan 18, 2016 4:36 pm

It turns out (for reasons I can't discern) that I am unable to return it. It's a nice day for a ride.

alec801
Posts: 4
Joined: Wed Dec 30, 2015 1:45 am

Re: WiFi dongle with monitor mode?

Fri Apr 29, 2016 7:11 am

probably a bit late but for others this may help.

the edimax EW-7811Un supports monitor mode in the mainline linux kernel but in raspbian the driver was changed due to stability issues

TP-LINK WN727N and TP-LINK WN722N both support monitor mode out of the box with raspbian and they are pretty cheap, but they are a larger dongle than the edimax dongle.


Look at this webpage https://en.wikipedia.org/wiki/Compariso ... ss_drivers
In the first table it lists the drivers. You want a driver that say "Yes" in the "Integration in mainline" column. This means the driver will be in the main linux kernel, and probably in the raspbian kernel too.

In the second table, it lists the abilities of the drivers. Out of the drivers that are in the mainline, you want to find a driver that says "Yes" in the "Monitor mode" column.

Once you have found the drivers that meet your requirements, in the top table next to the drivers is the "chipsets" supported by those drivers. Basically you want to do some research to find a wireless dongle that uses those chipsets.

Keep in mind this page might not be up to date and there is a chance that compatibility between the mainline kernel and the raspbian kernel may differ, so when you find a dongle, do some extra research to make sure that dongle works in your situation. But this is a general guide to find a dongle.
Good luck

nlandau
Posts: 9
Joined: Sat Jul 02, 2016 9:02 am

Re: WiFi dongle with monitor mode?

Sat Jul 02, 2016 5:12 pm

do you know if the stability issues with the old driver for EW-7811Un were solved in rasbian and monitor mode is now possible?

mark-bosco
Posts: 4
Joined: Mon Feb 15, 2016 11:37 am

Re: WiFi dongle with monitor mode?

Mon Jul 11, 2016 2:33 pm

Hi,

I'm looking for a dongle that support monitor mode in 5Ghz for the Pi.
Did anyone know a good one ?

Thanks !

aBUGSworstnightmare
Posts: 660
Joined: Tue Jun 30, 2015 1:35 pm

Re: WiFi dongle with monitor mode?

Fri Jul 15, 2016 5:25 am

i.e. this one http://www.ebay.de/itm/300Mbit-WLAN-Sti ... SwT6pVsofL

Monitor mode working/supported by Raspbian driver

thewoodcutter
Posts: 6
Joined: Wed Jan 25, 2017 2:16 pm

Re: WiFi dongle with monitor mode?

Wed Jan 25, 2017 2:50 pm

Hello

I too am trying to get monitor mode working on my pi. I have a couple of wifi dongles - the first is a Tontec wifi dongle which apparently uses the rtl8192cu chipset.

From examining https://wireless.wiki.kernel.org/en/users/drivers, this chipset should support monitor mode. When the dongle is added to my laptop running ubtunu 16.04, I am able to issue the following commands and successfully capture request packets:

Code: Select all

sudo ifconfig wlx0013ef650830 down
sudo iwconfig wlx0013ef650830 mode monitor
sudo ifconfig wlx0013ef650830 up
sudo tcpdump -i wlx0013ef650830 -e -s 256 type mgt subtype probe-req
where wlx0013ef650830 is the name of the device when added (the laptop already has a built in wireless card - hence the rename).

When I do the same with the dongle in a RPI 2 model B using jessie (lite I think!) I get a response indicating that operation is not supported.

Is this because the kernel used in jessie does not have the drivers supplied? Any way round this?

Thanks

BTW the other dongle is the official white raspberry pi dongle which does not support monitor mode even in my laptop. It uses the brcmfmac driver and when the aforementioned page is examined I can see that that driver does not support monitor mode. Sigh.

thewoodcutter
Posts: 6
Joined: Wed Jan 25, 2017 2:16 pm

Re: WiFi dongle with monitor mode?

Wed Jan 25, 2017 9:40 pm

Update:

Not sure whether it makes any difference, but I'm running it on an RPI model B, not RPI 2 model B.
The other thing I have noticed is that if I connect the wifi dongle whilst the RPI is on, it hangs. If I reboot the RPI comes up, but the eth0 is completely unresponsive as is my wireless keyboard plugged into a spare USB port.
Here's some debug ...

Code: Select all

$ ifconfig
eth0      Link encap:Ethernet  HWaddr b8:27:eb:7f:47:55  
          inet addr:192.168.1.200  Bcast:192.168.1.255  Mask:255.255.255.0
          inet6 addr: fde0:191d:9e45:a700:7046:4f31:94ca:3f14/64 Scope:Global
          inet6 addr: fe80::3918:a322:b8ec:3f41/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:73 errors:0 dropped:0 overruns:0 frame:0
          TX packets:100 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:5455 (5.3 KiB)  TX bytes:13105 (12.7 KiB)

lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:65536  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1 
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

wlan0     Link encap:Ethernet  HWaddr 00:13:ef:65:08:30  
          UP BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

$ lsusb
Bus 001 Device 005: ID 0bda:8176 Realtek Semiconductor Corp. RTL8188CUS 802.11n WLAN Adapter
Bus 001 Device 004: ID 05af:0630 Jing-Mold Enterprise Co., Ltd 
Bus 001 Device 003: ID 0424:ec00 Standard Microsystems Corp. SMSC9512/9514 Fast Ethernet Adapter
Bus 001 Device 002: ID 0424:9512 Standard Microsystems Corp. LAN9500 Ethernet 10/100 Adapter / SMSC9512/9514 Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

$ lshw
jasmine
    description: Computer
    product: Raspberry Pi Model B Rev 1
    serial: 00000000a17f4755
    width: 32 bits
  *-core
       description: Motherboard
       physical id: 0
       capabilities: brcm_bcm2708
     *-cpu:0
          description: CPU
          physical id: 0
          bus info: cpu@0
          size: 700MHz
          capacity: 700MHz
          capabilities: cpufreq
     *-cpu:1 DISABLED
          description: CPU
          physical id: 1
          bus info: cpu@1
     *-memory
          description: System memory
          physical id: 2
          size: 181MiB
  *-usbhost
       product: DWC OTG Controller
       vendor: Linux 4.4.44+ dwc_otg_hcd
       physical id: 1
       bus info: usb@1
       logical name: usb1
       version: 4.04
       capabilities: usb-2.00
       configuration: driver=hub slots=1 speed=480Mbit/s
     *-usb
          description: USB hub
          product: LAN9500 Ethernet 10/100 Adapter / SMSC9512/9514 Hub
          vendor: Standard Microsystems Corp.
          physical id: 1
          bus info: usb@1:1
          version: 2.00
          capabilities: usb-2.00
          configuration: driver=hub maxpower=2mA slots=3 speed=480Mbit/s
        *-usb:0
             description: Generic USB device
             product: SMSC9512/9514 Fast Ethernet Adapter
             vendor: Standard Microsystems Corp.
             physical id: 1
             bus info: usb@1:1.1
             version: 2.00
             capabilities: usb-2.00
             configuration: driver=smsc95xx maxpower=2mA speed=480Mbit/s
        *-usb:1
             description: Keyboard
             product: Rx504B  Ver:3.03
             vendor: Jing-Mold Enterprise Co., Ltd
             physical id: 2
             bus info: usb@1:1.2
             version: 3.10
             capabilities: usb-2.00
             configuration: driver=usbhid maxpower=98mA speed=2Mbit/s
        *-usb:2
             description: Wireless interface
             product: 802.11n WLAN Adapter
             vendor: Realtek
             physical id: 3
             bus info: usb@1:1.3
             logical name: wlan0
             version: 2.00
             serial: 00e04c000001
             capabilities: usb-2.00 ethernet physical wireless
             configuration: broadcast=yes driver=rtl8192cu maxpower=500mA multicast=yes speed=480Mbit/s wireless=unassociated
  *-network
       description: Ethernet interface
       physical id: 2
       logical name: eth0
       serial: b8:27:eb:7f:47:55
       size: 100Mbit/s
       capacity: 100Mbit/s
       capabilities: ethernet physical tp mii 10bt 10bt-fd 100bt 100bt-fd autonegotiation
       configuration: autonegotiation=on broadcast=yes driver=smsc95xx driverversion=22-Aug-2005 duplex=full firmware=smsc95xx USB 2.0 Ethernet ip=192.168.1.200 link=yes multicast=yes port=MII speed=100Mbit/s

$ uname -a
Linux jasmine 4.4.44+ #950 Sun Jan 22 16:15:51 GMT 2017 armv6l GNU/Linux

$ ifconfig wlan0 down

$ sudo iwconfig wlan0 mode monitor
Error for wireless request "Set Mode" (8B06) :
    SET failed on device wlan0 ; Invalid argument.

$ iw wlan0 info
Interface wlan0
	ifindex 3
	wdev 0x1
	addr 00:13:ef:65:08:30
	type monitor
	wiphy 0

I've read around (https://bugs.launchpad.net/ubuntu/+sour ... ug/1577421) and there is talk of raspbian shipping with an "out of tree Realtek driver".
I've found this driver exists on my system:
/lib/modules/4.4.44+/kernel/drivers/net/wireless/realtek/rtl8192cu/8192cu.ko

Any clues anyone?

rodizio
Posts: 38
Joined: Sat May 07, 2016 2:40 am

Re: WiFi dongle with monitor mode?

Tue Apr 04, 2017 5:56 pm

The other thing I have noticed is that if I connect the wifi dongle whilst the RPI is on, it hangs. If I reboot the RPI comes up, but the eth0 is completely unresponsive as is my wireless keyboard plugged into a spare USB port
Yeah, USB on the Pi has always been and still is a mess. Simple things like plugging in a usb device make it crash. I have the same problems with Atheros and Ralink sticks (perfectly reproducable with Raspbian versions from the last two years), also reported it on Github, but nobody cares.

jthess
Posts: 1
Joined: Sun Dec 17, 2017 4:55 am

Re: WiFi dongle with monitor mode?

Sun Dec 17, 2017 4:56 am

Newer versions of the TP Link TL-WN722N (namely v2 and v2.1) do not support monitor mode out of the box.

User avatar
Ronaldlees
Posts: 280
Joined: Sat Apr 16, 2016 4:28 pm
Location: North Carolina, US
Contact: Website

Re: WiFi dongle with monitor mode?

Mon Dec 18, 2017 2:29 pm

jthess wrote:
Sun Dec 17, 2017 4:56 am
Newer versions of the TP Link TL-WN722N (namely v2 and v2.1) do not support monitor mode out of the box.
Right. I think that is because they switched from the Atheros chipset to something else (maybe RAlink or Realtek). But v1 has the Atheros AFAIK.

The WN822N v1 had the AR9170 chipset, but it's the same deal so far as v1+ (later versions were changed to something else). I think some of the Zydas and Amtel chipset based adapters may allow for monitor mode. Of course it is not just a matter of chipset - but more a matter of what drivers are available for those chipsets and adapters. Some of the chipsets are better choices simply because drivers are available.
I am the Umbrella man: IR3/IR5 UV a/b/c OTS specs: break free, live life. Note that red cannot be seen with IR lenses, so cross at stop lights only on white walk signals, don't drive or operate machinery with lenses on, and don't use in low light.

theMusicMan
Posts: 63
Joined: Tue May 23, 2017 8:41 pm

Re: WiFi dongle with monitor mode?

Tue Apr 24, 2018 8:21 am

Another year on... :D

Has anyone managed to resolve the issue with these drivers?

Also, does anyone have any recommendations for a dual band WiFi dongle that supports both monitor mode and packet injection that will work with kali linux?

Return to “Recommended peripherals”

Who is online

Users browsing this forum: No registered users and 1 guest