Slashdot Mirror


Replicant OS Developers Find Backdoor In Samsung Galaxy Devices

An anonymous reader writes "Developers of the Free Software Foundation-endorsed Replicant OS have uncovered a backdoor through Android on Samsung Galaxy devices and the Nexus S. The research indicates the proprietary Android versions have a blob handling communication with the modem using Samsung's IPC protocol and in turn there's a set of commands that allow the modem to do remote I/O operations on the phone's storage. Replicant's open-source version of Android does away with the Samsung library to fend off the potential backdoor issue."

23 of 126 comments (clear)

  1. Re:OTA updates by mythosaz · · Score: 2

    It was a vulnerability. Now it's a back door.

  2. Re:How remote is remote? by MightyMartian · · Score: 2, Funny

    How remote is remote? Are we talking over the internet/sms or are we talking if you control a cell tower?

    Yes

    --
    The world's burning. Moped Jesus spotted on I50. Details at 11.
  3. Re:OTA updates by supertall · · Score: 5, Informative

    Actually, the article states that Cyanogenmod uses the same blob as well.

  4. Re:OTA updates by dos1 · · Score: 5, Interesting

    This is part of their undocumented protocol for communication with the modem. Modem can ask to read or write some file on disk using IPC_RFS_READ_FILE, IPC_RFS_WRITE_FILE, IPC_RFS_LSEEK_FILE, IPC_RFS_CLOSE_FILE, etc. messages and the library will happily do that for the modem. It's hardly unintended.

  5. Re:OTA updates by Anonymous Coward · · Score: 5, Funny

    "Nuts!" said the NSA. "Now we'll have to use one of our 12 other methods!"

  6. Re:How remote is remote? by dos1 · · Score: 5, Informative

    Modem can ask the APU app to write/read selected files and do some other file system operations. Why would modem want to read/write arbitrary files on user's file system and what and how could invoke such behavior of the modem? The answer is up to your imagination.

    Well, in fact many other phones don't need any backdoor to do the same as lots of them have modems directly connected to main RAM, exposing it to monitoring or even manipulation by the closed and strictly secured modem firmware.

    That's why projects like Neo900 opt for clear APU<->modem separation as host<->peripheral, together with power and antenna usage monitoring and fully free software stack on APU side.

  7. Re:How remote is remote? by Jane+Q.+Public · · Score: 2

    "How remote is remote? Are we talking over the internet/sms or are we talking if you control a cell tower?"

    Doesn't matter. Nobody likes to get "backdoored" without their consent.

  8. Re:OTA updates by Anonymous Coward · · Score: 3, Interesting

    Or anyone who sets up a fake tower? That's a pretty common and relatively easy attack vector now...

  9. Re:Third-party ROMs by dos1 · · Score: 5, Insightful

    Most of the popular ROMs are made using the very same closed drivers the article is talking about to provide hardware compatibility - otherwise they would be exactly where Replicant is now.
    Any third-party ROM for Galaxy devices that uses Samsung's library to communicate with the modem is vulnerable - so almost all of them are, including CyanogenMod.

  10. RMS was right by Anonymous Coward · · Score: 5, Insightful

    This is what you get for essentially renting a a black box with audiovideo and communication capability and letting 3rd parties control it fully: a personal tracker better than what the worst totalitarian regime could dream. There is no reason why operating systems or essential drivers should be shipped as binary blobs, not this day and age, not after the NSA revelations.

  11. Re:No contract, wifi-only by Charliemopps · · Score: 5, Informative

    No. The modem can write to your OS. Anyone can communicate with your modem, even Ham radio operators. Granted, exploiting this would be a huge technological challenge... unless of course this was placed there intentionally and they know exactly what to send to your modem to get it to do what they want.

  12. Re:OTA updates by megabeck42 · · Score: 4, Interesting

    I couldn't agree more. There is no evidence to suggest that it's a malicious backdoor.

    A quick strings on my samsung captivate glide's modem firmware, reveals all manner of novel debug messages and log strings:

    err/CP_MA_TRACE_%d_%04d%02d%02d%02d%02d%02d.bin
    [DUMP] FILE OPEN FAIL
    [ERROR]%s,%d,%s
    [DUMP] FILE CREATE FAIL
    [DUMP] Write MA Trace To /data/efs/err =====
    aurrcbp: discard cell due to system information read error
    [Net]NV Read Fail! OEM_NVM_TESTBED

    etc..

    I do know that a lot of data persistence for the radio is done with dotfiles scattered around and throughout /data and /efs (because real nvram is expensive).

    I'm curious what functionality is affected, if any is, by rejecting any of these IPC_RFS_ I/O.

    I don't think it's clearly a backdoor. But, I do believe the concern is warranted. The radio/modem's firmware blob is not auditable. Perhaps a combination of logging/auditing filesystem requests and limiting which files are accessible by the RILD? Actually, isn't the rild run as an unprivileged user, radio? (Possibly for this very reason?)

    --
    fnord.
  13. Re:No contract, wifi-only by megabeck42 · · Score: 3, Informative

    Two things, "Even Ham radio operators?" When did they become the retards of the RF world - I thought that title belonged to CB'ers? Honestly, hams are not interested in your phone.

    While, yes, technically anyone can communicate with your modem; anyone can communicate with your wifi card or your bluetooth adapter as well. And it would appear that the samsung radio interface IPC layer at least has a modicum less access to the entirety of your device than your wifi driver - which is in the kernel. People have, in the past, exploited mistakes in wifi drivers and wifi card firmware to remote exploit via wifi. (*: The specific instance I remember, was with an old intel 802.11b/g card and specially crafted management frames which could be trivially spoofed and didn't need to be encrypted to be accepted by the wireless card. The proof of concept was able to issue busmaster DMA read/writes which, ostensibly, would allow rewriting arbitrary kernel ram, etc.)

    Across the scope of samsung phones I was able to check (ok, two of them), the radio interface, the android host side of this communications channel, runs as uid 1001 (radio). As far as my cursory inspection revealed, meant that the radio/modem can read/write the files in /efs and only read a number of other places, such as /sdcard. Granted, /sdcard contains a lot of your personal data. My point is that, in this case, a compromised modem is still less privileged than a compromised android service or, worse, compromised driver/kernel. Also, given that these IPC instructions are used for reading/writing modem "nvram" data such as the handset IMEI, to describe them as a "backdoor" is horribly inappropriate.

    So, yeah, as you said, "huge technological challenge." Agreed. But, the idea that a data modem may be exploitable is by no means new.

    --
    fnord.
  14. Re:OTA updates by bug1 · · Score: 4, Insightful

    This is part of their undocumented protocol for communication with the modem. Modem can ask to read or write some file on disk using ...

    And "undocumented protocol for communication" is different than a Backdoor how ?

  15. Re:No contract, wifi-only by TheGavster · · Score: 4, Interesting

    Does anyone do verification on the "airplane mode" setting of phones? The FCC and FAA seem to have come to the conclusion that there's no way you can detect active radios via undesired behavior of an aircraft, and are down to sorting out the social ramifications of phone use on planes. I'd like to see an independent (and preferably paranoid) lab check to make sure that "all radios off" means that the radios are off, and not just that they stop passing traffic from the PDA OS.

    --
    "Because Science" is one step from "Because old book". Try "Because of my experiment testing my falsifiable assertion".
  16. OSS devs lack of communication skills by rubycodez · · Score: 3, Informative

    not even on their website do its developers explain what Replicant is, or what its goals and purpose are

    wikipedia does a better job...

    http://en.wikipedia.org/wiki/R...

  17. Any contacts at Samsung we can call? by slincolne · · Score: 2
    Does anyone have any contacts at Samsung (email addresses, phone numbers, etc.) that can address this issue?

    I just got back from looking at a Galaxy Note 3 (thinking form upgrading from by S2).

    Now I'm not sure - will probably just go buy a Nexus.

    I can't think of a single valid reason for this level of functionality to be available in a device that's sold commercially. I've never heard of any enterprise management tools that can use such functions, and their undisclosed existance is a real worry.

    The biggest laugh about this is that Samsung Australia is currently trying to get the Samsung Galaxy Note 10.1, Galaxy Note 2 and S3 onto the Australian Government Endorsed Product List (http://www.asd.gov.au/infosec/epl/index.php ) - I don't like their chances now.

  18. Re:No contract, wifi-only by ShaunC · · Score: 4, Interesting

    Two things, "Even Ham radio operators?" When did they become the retards of the RF world - I thought that title belonged to CB'ers? Honestly, hams are not interested in your phone.

    He wasn't calling hams retards, quite the contrary. He was pointing out that people with absolutely no control over your cellular carrier's towers, and thus no legitimate path into your cellphone, could give you problems despite not being an "authorized" party. Those people would still need to be extremely technically adept, familiar with radio, etc. so hams was a pretty good example IMO.

    --
    Thanks to the War on Drugs, it's easier to buy meth than it is to buy cold medicine!
  19. Great for defense lawyers! by ShaunC · · Score: 3, Insightful

    This will be wonderful news for criminal defense attorneys. Is your client accused of having a couple of terrorists in his phone's contact list? Did a customs official conveniently find child porn pictures on your client's phone during a border crossing? Did the prosecutor haul out telco logs "proving" that your client was sending text messages to arrange a heroin deal?

    Sounds to me like it's quite plausible that someone else put that $ILLEGAL_SHIT on your client's phone. After all, the capability was built right into the phone by Samsung.

    --
    Thanks to the War on Drugs, it's easier to buy meth than it is to buy cold medicine!
  20. Re:OTA updates by cheater512 · · Score: 2

    Where exactly would you expect the documentation for something like that to be in a consumer device?

  21. RIL and EFS by Technomancer · · Score: 3, Insightful

    I don't find that surprising. When I was playing with CyanogenMod it became obvious to me that RIL reads/writes files from EFS partition on behalf of the modem because settings for the modem, like IMEI, state of network lock, preferred networks etc, are stored there. I am not sure whether the interface is general enough so the modem can ask for any file.
    If they are concerned about binary blobs doing unknown stuff, RIL is small potatoes. There is huge GPS daemon binary made by 3rd party. Sensor drivers are linked with closed source processing libraries (AKM/akmd). Camera loads whole bunch of image/video processing libraries which are closed source/3rd party too. Lots of phones also use closed source 3rd party audio processing libraries. Not to mention 16MB of compressed modem firmware, running on modem CPU which is like another little independent computer.

  22. Re:OTA updates by s.petry · · Score: 3, Insightful

    I couldn't agree more. There is no evidence to suggest that it's a malicious backdoor.

    No evidence to the contrary either, and worth questioning since this is a common theme. Motorola was found to be sending all kinds of data to Motorola servers without user knowledge, including specific authentication information in plain text, Apple's SSL mess up, Countless MS back doors in just about everything they make. Then you have other players that made horrible decisions costing them their phone business.

    At a point we should at least wonder if these things are really just accidental and sloppy, or are they working as influenced/intended. The more we find that companies are doing the same things, the less plausible the "accidental" theory looks.

    How to actually find out is the hard part. Any company doing things for a fat check and favors from a government realizes that whistle blowers will lose future checks and favors. I'd be very interested in seeing all the files the government has on this, especially things like how many employees on Government payroll are working at places like Intel, Samsung, Apple, Microsoft, etc (if any).. It's too bad the CIA and Senate fight won't do anything to open that door.

    --

    -The wise argue that there are few absolutes, the fool argues that there are no probabilities.

  23. Re:OTA updates by teslar · · Score: 2

    I'm curious what functionality is affected, if any is, by rejecting any of these IPC_RFS_ I/O.

    Remotely wiping a stolen mobile phone perhaps? It's just a guess - but by definition that would require the ability to do stuff to the phone's file system without the current user's knowledge or permission.