Czas pohakować bejzbandy?
---------- Treść przekazywanej wiadomości ----------
Temat: The second operating system hiding in every mobile phone Data: środa, 13 listopada 2013, 09:54:09 Od: Eugen Leitl
http://www.osnews.com/story/27416/The_second_operating_system_hiding_in_ever...
The second operating system hiding in every mobile phone
posted by Thom Holwerda on Tue 12th Nov 2013 23:06 UTC
I've always known this, and I'm sure most of you do too, but we never really talk about it. Every smartphone or other device with mobile communications capability (e.g. 3G or LTE) actually runs not one, but two operating systems. Aside from the operating system that we as end-users see (Android, iOS, PalmOS), it also runs a small operating system that manages everything related to radio. Since this functionality is highly timing-dependent, a real-time operating system is required.
This operating system is stored in firmware, and runs on the baseband processor. As far as I know, this baseband RTOS is always entirely proprietary. For instance, the RTOS inside Qualcomm baseband processors (in this specific case, the MSM6280) is called AMSS, built upon their own proprietary REX kernel, and is made up of 69 concurrent tasks, handling everything from USB to GPS. It runs on an ARMv5 processor.
The problem here is clear: these baseband processors and the proprietary, closed software they run are poorly understood, as there's no proper peer review. This is actually kind of weird, considering just how important these little bits of software are to the functioning of a modern communication device. You may think these baseband RTOS' are safe and secure, but that's not exactly the case. You may have the most secure mobile operating system in the world, but you're still running a second operating system that is poorly understood, poorly documented, proprietary, and all you have to go on are Qualcomm's Infineon's, and others' blue eyes.
The insecurity of baseband software is not by error; it's by design. The standards that govern how these baseband processors and radios work were designed in the '80s, ending up with a complicated codebase written in the '90s - complete with a '90s attitude towards security. For instance, there is barely any exploit mitigation, so exploits are free to run amok. What makes it even worse, is that every baseband processor inherently trusts whatever data it receives from a base station (e.g. in a cell tower). Nothing is checked, everything is automatically trusted. Lastly, the baseband processor is usually the master processor, whereas the application processor (which runs the mobile operating system) is the slave.
So, we have a complete operating system, running on an ARM processor, without any exploit mitigation (or only very little of it), which automatically trusts every instruction, piece of code, or data it receives from the base station you're connected to. What could possibly go wrong?
With this in mind, security researcher Ralf-Philipp Weinmann of the University of Luxembourg set out to reverse engineer the baseband processor software of both Qualcomm and Infineon, and he easily spotted loads and loads of bugs, scattered all over the place, each and every one of which could lead to exploits - crashing the device, and even allowing the attacker to remotely execute code. Remember: all over the air. One of the exploits he found required nothing more but a 73 byte message to get remote code execution. Over the air.
You can do some crazy things with these exploits. For instance, you can turn on auto-answer, using the Hayes command set. This is a command language for modems designed in 1981, and it still works on modern baseband processors found in smartphones today (!). The auto-answer can be made silent and invisible, too.
While we can sort-of assume that the base stations in cell towers operated by large carriers are "safe", the fact of the matter is that base stations are becoming a lot cheaper, and are being sold on eBay - and there are even open source base station software packages. Such base stations can be used to target phones. Put a compromised base station in a crowded area - or even a financial district or some other sensitive area - and you can remotely turn on microphones, cameras, place rootkits, place calls/send SMS messages to expensive numbers, and so on. Yes, you can even brick phones permanently.
This is a pretty serious issue, but one that you rarely hear about. This is such low-level, complex software that I would guess very few people in the world actually understand everything that's going on here.
That complexity is exactly one of the reasons why it's not easy to write your own baseband implementation. The list of standards that describe just GSM is unimaginably long - and that's only GSM. Now you need to add UMTS, HSDPA, and so on, and so forth. And, of course, everything is covered by a ridiculously complex set of patents. To top it all off, communication authorities require baseband software to be certified.
Add all this up, and it's easy to see why every cellphone manufacturer just opts for an off-the-shelf baseband processor and associated software. This does mean that each and every feature and smartphone has a piece of software that always runs (when the device is on), but that is essentially a black box. Whenever someone does dive into baseband software, many bugs and issues are found, which raises the question just how long this rather dubious situation can continue.
It's kind of a sobering thought that mobile communications, the cornerstone of the modern world in both developed and developing regions, pivots around software that is of dubious quality, poorly understood, entirely proprietary, and wholly insecure by design. -----------------------------------------
On Wed, 13 of Nov 2013 13:03:26 rysiek wrote:
Czas pohakować bejzbandy?
---------- Treść przekazywanej wiadomości ----------
Temat: The second operating system hiding in every mobile phone
Jest jeszcze śmieszniej. Każdy telefon ma jeszcze trzeci komputer i system operacyjny. Karta SIM. Już dawno minęły czasy, kiedy robiła tylko durny storage.
Inna sprawa, że poziom bezpieczeństwa sprzętu na którym działają SIMy i ich systemu operacyjnego (w tych najbardziej zaawansowanych to jest ten sam GlobalPlatform co na kartach płatniczych) jest jednym z najlepszych jakie osiągnięto w powszechnie dostępnych komputerach.
On Wed, 13 Nov 2013, Remigiusz Marcinkiewicz wrote:
Jest jeszcze śmieszniej. Każdy telefon ma jeszcze trzeci komputer i system operacyjny. Karta SIM. Już dawno minęły czasy, kiedy robiła tylko durny storage.
Chyba nigdy nie robiła za storage, bo musiała mieć implementację RUN GSM ALGORITHM.
A zwykły laptop ma jeszcze więcej CPU, i jakoś nikt nie sieje paniki.
Chyba jest już open source baseband dla starożytnych Motoroli, pewnie ryzyko ogranicza się do możliwości zawieszania stacji bazowych niechcący:)
Ryzyko prawne trzeba zbadać, ale w systemie świadectw zgpdności da się to obejść; gorzej z patentami na oprogramowanie, których Qualcomm ma bez liku u nas one "nie obowiązują".
//Saper
W dniu 13 listopada 2013 15:30 użytkownik Marcin Cieslak saper@saper.infonapisał:
A zwykły laptop ma jeszcze więcej CPU, i jakoś nikt nie sieje paniki.
Zwykłego laptopa nikt nie nosi praktycznie non-stop przy sobie, włączonego, żadko który ma moduł GPS czy GSM, wiele nie ma mikrofonów. Słowem - komórka jest sprzętem o wiele bardziej osobistym, prywatnym, intymnym, z o wiele większym potencjałem na wykorzystywanie w "niecnych celach".
On Wed, 13 of Nov 2013 14:30:38 Marcin Cieslak wrote:
On Wed, 13 Nov 2013, Remigiusz Marcinkiewicz wrote:
Jest jeszcze śmieszniej. Każdy telefon ma jeszcze trzeci komputer i system operacyjny. Karta SIM. Już dawno minęły czasy, kiedy robiła tylko durny storage.
Chyba nigdy nie robiła za storage, bo musiała mieć implementację RUN GSM ALGORITHM.
OK, ale to zwykle robił wepchnięty na tym samym krzemie ASIC korzystający z tego storage do trzymania kluczy. Nowoczesne SIMy implementują to jako software.
On Wed, Nov 13, 2013 at 12:03 PM, rysiek rysiek@hackerspace.pl wrote:
Czas pohakować bejzbandy?
Dla tych co się na ten temat dopiero co obudzili - telefon z hackowanym bejzbandem jest nielegalny jeśli nie posiadasz odpowiednich uprawnień - a nawet z tymi AFAIK operator może ci wyłączyć dostęp jeśli działasz bez ich zgody. Broadcast media sucks :)
W dniu 13 listopada 2013 13:53 użytkownik Paweł Lasek pawel.lasek@gmail.com napisał:
On Wed, Nov 13, 2013 at 12:03 PM, rysiek rysiek@hackerspace.pl wrote:
Czas pohakować bejzbandy?
Dla tych co się na ten temat dopiero co obudzili - telefon z hackowanym bejzbandem jest nielegalny jeśli nie posiadasz odpowiednich uprawnień - a nawet z tymi AFAIK operator może ci wyłączyć dostęp jeśli działasz bez ich zgody. Broadcast media sucks :)
W Niemczech tcpdump jest nielegalny. Też mi argument ...
Pozdr, enki