13 ms·
Dumping and extracting the SpaceX Starlink user terminal firmware
- flatiron 5y agoi bet we would all really like to spend some time at SNOW_RANCH!
- rurban 5y agoThey already got a root shell without being at SNOW RANCH. Satellite provider firmware images are a nice target. SpaceX is not the only one. I also inspected some.
- uniqueuid 5y agoGreat writeup. I haven't seen products that use geofences to verify debug flags. Would it be possible to spoof this using a fake GPS e.g. with SDR?
- jandrese 5y agoSure, GPS SDR Sim[1] works just fine. You will want to be in an RF chamber of some kind not only to prevent the terminal from seeing natural GPS signals, but also to prevent you from screwing up the GPS in nearby satnav systems. Also because broadcasting on those bands on public airwaves is illegal as a private citizen. Of course putting your satellite antenna inside of a RF chamber also prevents it from working, so this may not be a viable long term strategy. Plus the terminal is undoubtedly using the GPS coordinates to calculate the antenna steering profile so you won't be able to lock on if your GPS is wrong. But since all they want to do is enable access to dump the firmware this probably isn't an issue. [1] https://github.com/osqzss/gps-sdr-sim https://github.com/osqzss/gps-sdr-sim
- squarefoot 5y agoSpoofing GPS might be dangerous should the dish detect coarsely its position also from the IP satellite link. If it does, then having the incoming data telling one position and the GPS a very different one, would likely trigger some protection.
- ta988 5y agoI'm sure they would reactivate you if you say you work for the bounty. You do work for almost free...
- uniqueuid 5y agoYikes. Thanks for the details AND the warnings. An interesting question, however, is whether Starlink checks whether the satellite you're tuned to is plausible given the GPS coordinates ...
- ta988 5y agoThere is only one way to know until that thing gets reversed...
- useryman 5y agoFrom working on hardware with GPS-functionality tacked on before, I can suggest a simpler solution; 1: Find the GPS module, and look up its data sheet. 2: Spoof the data coming out of its IO ports. Cheap GNSS modules that spit out NMEA messages on a serial line are everywhere. (I guess because they're super cheap, and easy to integrate)
- jandrese 5y agoIf it is a separate chip this is a good solution, but these days you're more likely to find it integrated into something else.
- nucleardog 5y agoI'd have to imagine in this case it's using the GPS location to assist in acquiring and tracking the satellites (though that's entirely a guess based on the "auto-adjusting" that's claimed). Spoofing your GPS location like that may work as far as bypassing the geofence, but you may not get internet at the same time.
- gnu8 5y agoRight, if the UT has a mistaken idea of its position, it won't find the satellites that it is looking for in orbit, and simply not work. Alternatively, if it DID find satellites, then it will know at least what cell it is in (how big are these?) regardless of the spoofed GPS fix.
- stefan_ 5y agoI'm not sure the dish can continue to work if it doesn't have a real GPS lock. That said, this is a mechanism that they found on the dish side in the firmware - firmware that is unencrypted stored on that flash chip - so you can obviously manipulate the firmware side to ignore the debug fuse stuff.
- bigiain 5y ago> so you can obviously manipulate the firmware side to ignore the debug fuse stuff. Might not be as trivial as that makes it sound: "Continuing through the boot process we can see that U-Boot loads a kernel, ramdisk and Flattened Device Tree (FDT) from a Flattened uImage Tree (FIT) image that is stored on an embedded MultiMediaCard (eMMC). We can also see that the integrity (SHA256) and authenticity (RSA 2048) of the kernel, ramdisk and FDT is being checked. While we would have to perform some more tests it appears that a full trusted boot chain (TF-A) is implemented from the early stage ROM bootloader all the way down to the Linux operating system."
- ta988 5y agoThat's great, nothing stops you from using an alternative microcontroler that doesnt check signatures and mimic that one.
- bigiain 5y agoYeah. If you can futz with the hardware, pretty much any security can be circumvented. Desoldering a SOC and replacing it with something similar enough but different in its trusted boot config is somewhat less trivial than "manipulate the firmware" though, at least in my opinion...
- exikyut 5y agoI have no info about the UT's use of GPS, but given that you can basically construct a practically-unbreakable geofence around the fact that the UT can only physically see a specific set of satellite(s) at any particular point in time (and space), and you get this property for free given the UT's purpose, I can't imagine that not being leveraged in the design.
- sneak 5y agoBeen meaning to do this myself! Great to see it. :) > While we would have to perform some more tests it appears that a full trusted boot chain (TF-A) is implemented from the early stage ROM bootloader all the way down to the Linux operating system. This unfortunately means it will likely be somewhat difficult (or infeasible) to reflash it with a custom firmware that uses actual GPS location for targeting of satellites but reports a couple km offset to the telemetry service APIs to keep my residence address somewhat private from my ISP. It's a bummer they didn't share the dumps. It always bothers me when researchers act all coy about their results. Now I have to get my hands on a dish myself and do what they didn't (namely, actually publish the data).
- uniqueuid 5y agoGives IP geolocation a whole new meaning. 33-9207N-118-3278W.clients.starlink.com
- olyjohn 5y agoHow precise is that coordinate? My neighbor and I both have Starlink and our dishes can't be more than 200 feet apart.
- fotbr 5y agoAssuming that they're referring to decimal degree notation, and not Degrees-Minutes-Seconds, and that the location is correct, and ignoring the spheroid vs perfect sphere issues: about 11.1 meters (36.4 ft). http://wiki.gis.com/wiki/index.php/Decimal_degrees http://wiki.gis.com/wiki/index.php/Decimal_degrees If it's DMS, again assuming location is correct, ignoring spheroid vs sphere: something between 80 and 100 ft (24.4 - 30.48 meters). https://www.usgs.gov/faqs/how-much-distance-does-a-degree-minute-and-second-cover-your-maps?qt-news_science_products=0#qt-news_science_products https://www.usgs.gov/faqs/how-much-distance-does-a-degree-mi...
- Robotbeat 5y agoWell, given the digit pairs include values greater than 60, I doubt it’s arcseconds/arcminutes.
- ovi256 5y ago> Interestingly, some of these geofences do not seem to have a clear connection to SpaceX. While we will not disclose these locations here, I will say that the SNOW_RANCH looks like a nice location to play with development hardware. Most likely these are testing locations. Possibly even second homes of testers & engineers. After all, this is a product that has very different operating parameters depending on location.
- tyingq 5y agoThere's a "Snow Ranch" that is a working cattle ranch near Stockton California, where the owners allow model rocket launches. http://www.lunar.org/events.shtml http://www.lunar.org/events.shtml I wonder if that's what he's alluding to. I don't see an explicit connection to SpaceX, but it seems to fit.
- kijiki 5y agoI haven't been to snow ranch in years, but early Spacex investor Steve Jurvetson was a regular at the high power amateur rocket launches there. Probably other Spacex folks there as well. Launches have all been shutdown for COVID reasons, and even before that, not infrequently cancelled due to fire risk.
- FireBeyond 5y agoGotta be careful. Someone dumped the firmware from their Tesla Model S and discovered info about the then-unannounced Model 3. Tesla responded by disabling the car's ethernet port, downgrading the firmware, and preventing the car from receiving future upgrades to software.
- ivrrimum 5y agowth? Is that even legal?
- jve 5y agoSource? There is this ex-employee, telling some interesting stories. And regarding the downgrade... he was the one who did it for reasons he explains. I want to see if you are talking about different case or what. > Question: There's the story online of that hacker who was pulling software images off through the door Ethernet port and found that his car's firmware was remotely downgraded after he uncovered and posted the first references to the P100 models. > Answer: yup, i'm the guy that installed the older versions. this was a marketing mistake really. if i recall correctly, he ended up getting a marketing car or his car got tagged in the update system as a trusted car and he ended up getting pre-release stuff. this happened from time to time - sometimes marketing would sell off a car and the poo poo erp system wouldn't record the change. that car would then get prerelease and sometimes very broken firmware. i seem to recall another case where we just forgot to remove the prerelease materials from the official build, so all you had to do was look around. https://forums.somethingawful.com/showthread.php?threadid=3862643&userid=20544#post487301427 https://forums.somethingawful.com/showthread.php?threadid=38...
- dooglius 5y agoUh, that still doesn't paint Tesla in a good light, so this guy bought a car running special experimental firmware by mistake? What if there was a bug and he crashed?
- a-dub 5y agothen the firmware is downgraded again before anyone gets sued/fired or the hackers who hacked the manufacturer cover their tracks. duh. one big reason why i'm not particularly thrilled at the prospect of one day owning a car that is actively managed/controllable by the manufacturer. in the days of the audi 5000 sudden acceleration syndrome, they could take a production car and study it. how would a third party/government agency trustlessly investigate "brake lose control" when the manufacturer has root and remote access on the vehicle?
- etaioinshrdlu 5y agoDoes anyone know why there is a giant pcb with an array of little chips on it? This is not a normal satellite dish. How does it work?
- InitialLastName 5y agoLooks like a phased array [0], which is probably a smart idea with a dish like that. Instead of using a parabolic reflector with a receiver at the focus (like in a normal satellite dish) they use an array of a ton of tiny receivers (each of those tiny ICs would be a driver for a small, on-PCB antenna). Phased arrays (essentially algorithmically delaying the individual radio signals from/to each driver on the scale of fractions of a period of the carrier frequency) let you do really precise beamforming and aiming, but take a lot of processing power and a lot of antennae to be efficient so weren't practical until recently. [0] https://en.wikipedia.org/wiki/Phased_array https://en.wikipedia.org/wiki/Phased_array
- ChrisGammell 5y agoIt's a phased array, it uses those many little chips to do "beam steering". Check out this video by The Signal Path (a Bell Labs expert!) doing a teardown and explaning parts of it: https://www.youtube.com/watch?v=h6MfM8EFkGg https://www.youtube.com/watch?v=h6MfM8EFkGg
- walrus01 5y agoIt is a phased array, the closest thing that exists to it in the rest of the world is the phased array radar in the nose radome of an air superiority fighter jet.
- apcragg 5y agoPhased arrays are everywhere. An incredibly common example are many cellular base station antennas. They are fancy but nothing particularly special these days. Active phased arrays, e.g. steerable with either analog phase / delay shifters or with digital front ends are less common but still much more common than the BAE Systems phased arrays in F35's.
- sarak12070 5y agoBuy epielle with discount https://topsaleproductsonline.blogspot.com/2021/07/buy-epielle-with-discount.html https://topsaleproductsonline.blogspot.com/2021/07/buy-epiel... raisin water for weight loss complete guide http://healthwithbeauty.xyz/2021/07/06/raisin-water-for-weight-loss-complete-guide/ http://healthwithbeauty.xyz/2021/07/06/raisin-water-for-weig... snow leopard camouflage Interesting facts https://www.interestingnews.club/2021/07/snow-leopard-camouflage-interesting.html https://www.interestingnews.club/2021/07/snow-leopard-camouf...
- dmitrygr 5y agoUsing ECC is very strange in this context. eMMC storage already provides for data correctness (and wear leveling of flash). If flash is corrupted to a point where internal error correction cannot compensate for it, eMMC will return no data, simply returning an error. This means that the additional level of error correction that they added will never ever be used. Perhaps earlier revisions of this used raw NAND? Either that, or somebody got overzealous without thinking through.
- mkj 5y agoIs the internal error correction done on the eMMC module? Perhaps they don't trust that, or are being wary of bit errors on the data lines. It seems like a fair bit of effort for a device like this - I wonder if the same u-boot codebase is used on devices in space which have higher reliability requirements.
- dmitrygr 5y agoThe spec is quite clear. Read shall either produce the same data as was written or return an error. I haven't ever seen an eMMC device that didn't comply with this part of the spec given how obviously bad that would end.
- sgtnoodle 5y agoMaybe they're worried about bit flips before the data gets to emmc? They probably aren't doing it, but you could always interleave the data across the emmc blocks. A lost emmc block would therefore corrupt single-digit bytes across many ECC'ed blocks, rather than many bytes within a couple ECC'd blocks. 32 bytes of Reed Solomon should be able to correct up to 16 bytes of corruption. CDs do the same trick to be robust to scratches.
- anonymousiam 5y agoIt appears that after they discovered the ECC encoding, they simply ignored the ECC data to extract the image. What if some deliberate (correctable) bit errors were scattered through the image? They have the code that implements the ECC algorithm. If I were them, I would have used it and perhaps even submitted a patch to binwalk so it would automatically recognize/decode the image. Also, now that they have the image, they could try to override the geofence/fuse protections by running it on an SoC without the fuse blown, and a SDR-based GPS spoofer. Seems like a fun endeavor.
- PragmaticPulp 5y ago> Also, now that they have the image, they could try to override the geofence/fuse protections by running it on an SoC without the fuse blown, It’s a custom SoC. They can’t just buy one off the shelf.
- exikyut 5y agoI might be mistaken, but the geofencing might be based on the specific satellite you were connecting to, correlated with the time of day. And very likely verified/audit-logged on the satellite side too.
- pabs3 5y agoHmm, I wonder if locking down the boot chain like this is GPL compliant, since apparently even GPLv2 requires the ability to modify GPL parts on the device. https://sfconservancy.org/blog/2021/mar/25/install-gplv2/ https://sfconservancy.org/blog/2021/mar/25/install-gplv2/
- lights0123 5y agoThat article mentions nothing about code signing, and it's well known that the GPL 2 doesn't have anything that would prevent Tivoization.
- pabs3 5y ago> That article mentions nothing about code signing From the article: "... it appears that a full trusted boot chain (TF-A) is implemented from the early stage ROM bootloader all the way down to the Linux operating system." > the GPL 2 doesn't have anything that would prevent Tivoization. From the GPLv2: "... plus the scripts used to control compilation and installation of the executable." https://www.gnu.org/licenses/old-licenses/gpl-2.0.html https://www.gnu.org/licenses/old-licenses/gpl-2.0.html From the Software Freedom Conservancy blog post about the GPLv2 installation requirements: "GPLv2 assures, to the purchaser of an embedded product, their absolute right to receive the information necessary to install a modified version of the GPLv2'd works." https://sfconservancy.org/blog/2021/mar/25/install-gplv2/From https://sfconservancy.org/blog/2021/mar/25/install-gplv2/Fro... Of course, that doesn't mean that the proprietary software must continue to function after modifying the GPL software, apparently even the GPLv3 allows what Tivo did. From a presentation about GPLv3 on cars: "Ironically, even if Linux were GPLv3, Tivo’s method of crypto- lock-down would likely comply with GPLv3." https://events19.linuxfoundation.org/wp-content/uploads/2017/11/Safely-Copylefted-Cars-Reexamining-GPLv3-Installation-Information-Requirements-ALS-Bradley-Kuhn-Behan-Webster-1.pdf https://events19.linuxfoundation.org/wp-content/uploads/2017...
- outsomnia 5y ago"Tivoization" is a word because GPL2 does not say you must be given signing keys that allow your modified image to be accepted and executed by the device, these are not covered by "scripts used to control compilation and installation of the executable".