title | description | image | date | authors | |
---|---|---|---|---|---|
GPS Spoofing using a HackRF |
How to spoof your GPS signal using a HackRF One |
/images/tutorials/hackrf.jpeg |
2023-11-07 |
|
Greetings fellow hackers!
Today, we will show you how to spoof your location using a HackRF One. You will NEED a TCXO Clock for this to work.
Install the gps-sdr-sim program, Compile it using gcc, Get the satellite files, Run the program, Transfer it to the HackRF, Go to Antarctica!
If you have git installed on your machine, then you can clone it using:
git clone https://github.com/osqzss/gps-sdr-sim.git
Or by going to https://github.com/osqzss/gps-sdr-sim and downloading a zip and then extracting it.
Don't forget to get cd (get into the directory) before going to the next step!
Before you run the program, you have to compile it. You can do this by running:
gcc gpssim.c -lm -O3 -o gps-sdr-sim -DUSER_MOTION_SIZE=4000
Now comes the annoying part...
To get the satellite files you sadly need to create an account on the NASA's website.
- Go to https://cddis.nasa.gov/archive/gnss/data/daily/2023/brdc/
- Find the latest file
- Download it
- And finally, extract it.
In my case, I want to be in Antarctica. To do that, I will go to my favourite online map (like Google Maps), Right click on the place where you want to be, and click on it's coordinates (see the image)
Now you will need to create the .bin file with the gps-sdr-sim. Here's an example:
./gps-sdr-sim -b 8 -e brdc0010.22n -l -66.32458095460932, -62.33976614456196, 100
This will create a file named gpssim.bin.
sudo hackrf_transfer -t gpssim.bin -f 1575420000 -s 2600000 -a 1 -x 0
Wooooo! You are now spoofing your location using a HackRF. If it doesn't work, then it may take about 3-5min to get recognised by your phone. Still not working? Because this tutorial is free, you can get community support by opening an issue here: https://github.com/pwnguide/free