Project

General

Profile

Actions

ModemDisable » History » Revision 2

« Previous | Revision 2/18 (diff) | Next »
Denis 'GNUtoo' Carikli, 10/20/2019 06:50 PM
The airplane mode may not cut the receiver and the modem probably still runs


Disabling the Modem

Samsung-RIL devices

On devices that use Samsung-RIL, Replicant's Airplane Mode trusts the modem to actually turn off its transmitters. This is undesirable, since the modem is running non-free firmware that is not trustworthy. However, since the modem's firmware is loaded by the CPU on boot, the modem will be nonfunctional if the CPU chooses not to load the modem firmware. This can be used to achieve a more trustworthy Airplane-Mode-like state. It should be noted that while this does reduce attack surface, there may still be ways for the modem to be activated (e.g. if the non-free bootloader running on the CPU sends a firmware to the modem).

To disable the modem on Samsung-RIL devices, follow these steps:

Installation

From your PC, clone the user-scripts repository:

git clone https://git.replicant.us/replicant/user-scripts.git -b replicant-6.0

For the next steps, ADB needs to be set up and running as root. Connect the device to your PC. The scripts are in the networking/modem folder. Run the setup script the folder to push the scripts to the device:

./setup.sh

Then disconnect the device. Make sure root access for apps is enabled.

Usage

Open a terminal emulator. If the terminal is not running as root, you can gain root by running:

su

Navigate to the data/misc/modem directory and run one of the scripts:

bash disable_modem.sh

or
bash enable_modem.sh

Disabling the modem will reboot your device (the modem will be disabled when reboot completes). Enabling the modem does not require a reboot (it takes effect after a few seconds).

Other devices

We don't yet have a way to disable the modem on other devices.

Updated by Denis 'GNUtoo' Carikli over 4 years ago · 2 revisions

Also available in: PDF HTML TXT