To prepare for an upcoming Wifi Survey, I decided to configure a Wifi Pineapple to use Kismet and GPS as described in Hacking Exposed – Wireless. In addition to the book, there are quite a few articles and posts to make this happen, and overall it is a simple effort.
- WiFi Pineapple Mark V
- Pineapple Juice 15000
- GlobalSat BU-353-S4 USB GPS Receiver
While some people recommend using Kismet for GPS, I did not have success with that configuration and ended up running GPSD. Consequently, the default kistmet.conf file does not require substantial changes as it defaults to a GPS/GPSD configuration.
Daemonizing GPSD and specifying the ‘don’t wait for a client to connect before polling’ flag (-n). Note that a capital ‘N’ flag is used to run GPSD interactively and may assist with your device troubleshooting.
While I think that your GPS will most likely register as /dev/ttyUSB0, double-check the load.
Kismet is a client interface for the Pineapple, so ensure that you install AutoSSH and auto-enable it.
To get Kismet running, we need to do the following:
- ssh to Pineapple
- Install dependencies:
- opkg update
- opkg install gpsd
- opkg install kistmet_server
- Edit Kismet configuration (see Wardriving with WiFi Pineapple Mark V running Kismet)
- Modify log directory; logprefix=/sd/kismet/
- Run GPS service:
- gpsd -n /dev/ttyUSB0
- Initialize Antenna
- ifconfig wlan1 down
- iwconfig wlan1 mode monitor
- Run Kismet
Kiswalk Startup/Shutdown Script
With your setup scripts in place, all that needs to be done is to SSH into the Pineapple, run ‘kiswalk.sh start’, go for a walk, SSH back in and run ‘kiswalk.sh stop’
#!/bin/bash if [[ "$1" == "start" ]] then echo "Starting Kismet..." # Initialize GPS device gpsd -n /dev/ttyUSB0 # Put the second antenna in monitor mode ifconfig wlan1 down iwconfig wlan1 mode monitor # Start Kismet kismet_server --daemonize elif [[ "$1" == "stop" ]] then # Stop Kismet echo -e '\n!0 shutdown' | nc localhost 2501 # Download the capture files tar cvzf /sd/kismet.tar.gz /sd/kismet/* scp /root/kismet.tar.gz email@example.com:/sd/kismet.tar.gz else echo "kiswalk.sh [start/stop]" fi
Script maintained on Github