GPS Spoofing
GPS spoofing attacks can manipulate drone position, triggering geofencing, forcing landings, or redirecting flight paths. Drones rely heavily on GPS for navigation.
GPS Spoofing Concepts
Attack Effects
- Position shift (gradual or sudden)
- Trigger geofence restrictions
- Force Return-to-Home
- Time manipulation
Requirements
- SDR capable of GPS frequencies
- GPS signal generator software
- Appropriate antenna
- Line of sight to target
"Line of sight to target" is also the sentence that makes this technique uncontrollable. A GNSS antenna is not a directional control - the signal you radiate arrives at every receiver that can hear it, including receivers in aircraft above you and in the timing infrastructure around you.
GPS Spoofing Tools
Read This Before the Commands: GNSS Transmission Is a Criminal Act
Spoofing a GNSS signal is unlawful for private parties in most jurisdictions, and the penalties do not depend on whether the target was harmed. In the United States, interference with an aircraft in service is a federal offence under 18 U.S.C. § 32 (the Aircraft Sabotage Act, prosecuted by the Department of Justice); transmitting on the GPS L1 band is separately prohibited by 47 U.S.C. § 333 and the FCC's Part 15 rules, which also make selling a jammer illegal. In the United Kingdom, the Wireless Telegraphy Act 2006 makes unauthorised transmission an offence and the Air Navigation Order covers endangering an aircraft. In the EU, Directive 2014/53/EU requires an authorised radio installation.
The reason the law is written that way is that GNSS interference has already reached manned aviation: a spoofed or jammed receiver in a cockpit produces confident, wrong position data, which is worse than no data. The only lawful settings for the commands below are an RF-shielded enclosure or a licensed test range, on a receiver you own, with written authorisation naming the frequency and the duration.
gps-sdr-sim
synthesises GPS L1 baseband samples from a RINEX broadcast-ephemeris file. Two things trip
people up. It is C, so cloning the repository does not give you a working binary - it has to be
compiled. And the ephemeris file is not in the repository: the daily merged broadcast
navigation file (brdc,
named like brdc0010.22n)
is published at cddis.nasa.gov/archive/gnss/data/daily/
and access requires a free Earthdata registration, so brdc.nav
is whatever you renamed your own download to, for the day you intend to simulate.
git clone https://github.com/osqzss/gps-sdr-sim.git
cd gps-sdr-sim
gcc gpssim.c -lm -O3 -o gps-sdr-sim
# -b 8 is not optional for HackRF: the default is 16-bit (bladeRF/USRP),
# and hackrf_transfer needs 8-bit signed I/Q or the samples are malformed.
./gps-sdr-sim -e brdc.nav -l 37.7749,-122.4194,100 -b 8 -d 60
hackrf_transfer -t gpssim.bin -f 1575420000 -s 2600000 -a 1 -x 0
The sample rate in hackrf_transfer
has to match the generator: -s 2600000
is gps-sdr-sim's default output rate, and feeding it to the HackRF at a different rate changes
the chipping rate the receiver sees. Drop -b 8
and the file is 16-bit, which the HackRF will happily transmit as noise.
What has changed on the receiver side is authentication. Galileo's Open Service Navigation Message Authentication (OSNMA) has been operational since 24 July 2025, and a receiver that implements it can verify a cryptographic signature over the navigation data before using it, so a synthetic message stream without valid authentication data is discarded instead of tracked. The generator on this page emits GPS L1 C/A only, which is the easier half of the problem to defend: a receiver that also tracks Galileo or BeiDou holds an independent position solution and can flag the disagreement. OSNMA authenticates the data, not the ranging signal: a delayed copy of a real signal still yields a plausible position, and closing that gap is what Galileo's Signal Authentication Service is being built for. SBAS and RAIM sit on a different axis - they bound integrity and flag inconsistency, which catches a crude spoof but not a careful one. A current module such as u-blox's M10 also reports jamming and spoofing detection in its own status output, so the receiver's flags are evidence worth capturing before and during any test.
The capture pattern the statutes above are aimed at is not one transmission. It begins with a signal that agrees with the real constellation so the receiver keeps tracking, then raises power until its tracking loops prefer the synthetic signal, then walks the reported position somewhere the operator never intended to fly. The second and third parts are the aircraft-seizure step: at that point the receiver is not being tested, it is being taken, and the position it reports is the attacker's choice rather than the sky's.