There were quite a few similar implementations. And this is soft to say very non -budget solutions. The material will be discussed by Copperheados-the system created by the developers of Tor and based on Open-Source components.
Protected smartphone based on Copperheados
The main feature of Copperheados is significantly racched hacking means. The firmware includes the modernized implementation of the memory allocator (malloc) from OpenBSD (more about it can be read here), which randomizes the page allocated to the application and fills with garbage the returned pages of memory. This makes USE-AFTER-FREE class attacks more complicated in implementation. OpenBSD Malloc also places marks at the end of the emitted memory areas, which are checked when it is released. This allows you to deal with attacks like Heap Overflow.
When assembling CopperHeados, compiler products are used to prevent stack breakdown. In particular, _Fortify_Source mechanisms in GCC (Android <7.0), -Fsanitize = Bounds, -Fsanitize = Object-Size (Android 7.0), the mechanism -fsanitize = Integer to protect against integrated re-pepper. These funds are used by Google in AOSP, but Copperheados developers have expanded their use for a much larger number of functions of the standard Language Language Language Language library (and, most importantly, it was reduced to upstream).
To protect against modification of the code, Copperheados uses the trust loading mechanism that first appeared in Android 4.4, and, in addition, does not relieve the optimized application code from the catalog/DATA/Dalvik-Cache. The latter is needed to quickly launch applications and is generated during the first loading of a smartphone (the message “Application optimization ...”). However, it can also be used to introduce a malicious code into the system: it makes no sense to replace the application in section/System - the trust loading mechanism will refuse to load the smartphone after modifying the system section, but the optimized c/data/cache code does not have suspicion Calls.
The copperheados core is assembled with PAX patch, which includes non -preventing mechanisms for preventing attacks:
Copperheados has more stringent Selinux rules - a system for distinguishing between the rights of the fight to files, system calls and iron. For example, it is impossible to execute a code from temporary catalogs (connected using TMPFS pseudofs), you cannot access important systemic information and information about other processes by reading the catalog/PROC files.
Copperheados includes many other restrictions. By default, the standard adjustment of the camera does not indicate the location of the shooting in the metadata picture, and the screen does not show notifications that may disclose confidential information (Android and iOS allow the show of such notifications, with the possibility of disconnecting). Applications working in the background cannot access the exchange buffer (which breaks the performance of several useful applications from the market). The MAC address of all network interfaces is randomized by default. The WebView component, which allows for the drawing of web pages in third-party applications (and many browsers), uses the ISOLATEDPROCESS function that allows you to lock each WebView instance in its own sandbox.
Chromium itself, on which WebView is based, includes a number of restrictions and settings aimed at protecting against data leaks: error correction is disabled, pages pre -load, context search, metric and hyperlink audit. As a search engine, a non -tracking user of Duckduckgo is used.
More from Tor
Copperheados is only the basic part of the firmware. A few more components work on top of it: Orbot, Orwall, F-Droid, My App List and Google Play, included in the basic supply not so much due to access to the Application store (its functions are performed by F-Droid) as for Signal. Pa-lecture uses Google services to obtain push notifications.
The two main components here are, of course, Orbot and Orwall. The first is the TOR assembly for Android, capable of working either as a local SOCKS-Proxy, redirecting traffic in Tor, or in Root mode, when all the traffic is wrapped in Tor IPTABles firewall, which avoids any leaks.
However, by default, the firmware does not use one method or the other method, but is getting on ORWALL, a kind of wrapper for the firewall, which allows you to wrap traffic in Orbot selectively, for each individual application. With it, you can subtly control who will go to the network via Tor, who directly, and who will be prohibited from the Internet at all.
Orwall completely blocks any Internet connection until the firmware is fully downloaded. This avoids any data leaks if you intend to go to the Internet exclusively via Tor or completely block access to the Internet that does not cause software to software.
My App List is another interesting application in the firmware kit. Initially, it was created as a convenient way to save the list of applications installed through the F-Droid store, but Tor developers used it for a quick installation of recommended applications: they prepared a software list in advance, which could be useful to the average user and loaded it at My App List.
Ponnovka
At the moment, the firmware is available for Nexus 5x and Nexus 6P, however, its installation is significantly different from the assignment of the same Cyanogenmod or any other Castom. In fact, this is just a set of scraps for Linux, which pumps out the latest version of Copperheados from the official site, downloads additional software, integrates it into the firmware, signs it and installs it on the device using the Fastboot utility.
For this reason, you will need to install the firmware:
In Ubuntu, all this can be installed as follows:
$ SUDO APT-GET Install Android-TOOLS-DOLS-TOOLS-FASTBOOT
$ Sudo Apt-Get Install Openjdk-7-JDK
$ Sudo Apt-Get Install Build-Sessional Git
$ Sudo Apt-Get Install Libssl-Dev
Next, we activate the USB debugging on the smartphone: settings -> ABOUT PHONE, five taps for Build Number, then: Settings -> Developer Options -> Allow USB Debuging, as well as Enable Oem UNLOCK.
We connect the smartphone via USB and perform the following command:
$ Sudo Adb Devices
In response, the smartphone should derive a dialog box with a question about PC trust, it should be agreed with it.
It remains only to download scripts and start the firmware process:
$ GIT CLONE
$ CD Mission-Improbable
The script will lead you through all the stages of installation. Naturally, the data from the device will be erased.
Instead of conclusions
The firmware from TOR developers is certainly an interesting project. Using it correctly, you can get a smartphone almost not tracking through the Internet. However, it should be borne in mind that the device will remain not protected from tracking with mobile networks and Side Channel attacks, for example, the opportunity to intercept passwords with a maximum analysis of changes in the Wi-Fi signal.
#Security and World #Security #Internet