Wifi
Wifi
Changing mac address
Some APs might try to block you or deauth you when they see you testing Wifi, hence changing your mac address might be helpful to bypass those restrictions:
# change to a random mac emulating a random vendor MAC of any kind
sudo macchanger wlan0 -A
Print Wifi SSID from hash
cat dump.hashcat | egrep -v "^$" | python2 -c "import sys; print(''.join([l.split('*')[5].decode('hex')+'\t'+l for l in sys.stdin]))"
Fixing issues with drivers
This driver is great for most chipsets: https://github.com/lwfinger/rtw88
If having issued with kernel headers
sudo apt update
sudo apt upgrade
sudo apt dist-upgrade
sudo reboot
# install the linux kernel headers as recommended by the git repo
GPS device
Difference between GPS and GNSS
GPS (Global Positioning System) is a specific satellite navigation system operated by the United States. It’s the most widely used and recognized global positioning system.
GNSS (Global Navigation Satellite System) is a general term that refers to all satellite-based navigation systems, including:
- GPS (United States)
- GLONASS (Russia)
- Galileo (European Union)
- BeiDou (BDS) (China)
- QZSS (Japan, regional coverage)
- NavIC (India, regional coverage)
Finding your GPS device
lsusb
# should be something like `/dev/ttyUSB0`, `/dev/ttyUSB1`, ..., `/dev/ttyACM0`, `/dev/ttyACM1`, etc.
ls /dev/tty*
Testing with gpsd
sudo apt install gpsd gpsd-clients
sudo gpsd /dev/ttyACM0 -F /var/run/gpsd.sock
cgps -s
Using bettercap with a GNSS device
# this will show you if you have issues with the gps:
# sudo bettercap -iface wlan0 --debug
# wlan0 » set gps.device "/dev/ttyACM0"
# wlan0 » gps on
# wlan0 » [16:10:38] [sys.log] [dbg] gps error parsing line ''7@': nmea: sentence does not start with a '$' or '!'
# instead you need to start the gpsd service and set bettercap to use that instead as such:
# start GPSD with you GNSS device
# this will start GPSD on localhost:2947
sudo gpsd /dev/ttyACM0 -F /var/run/gpsd.sock
sudo bettercap -iface wlan0
> set gps.device "localhost:2947"
> gps show