Android Applications and Games
Anbox puts the Android operating system into a container, abstracts hardware access and integrates core system services into a GNU/Linux system. Every Android application will be integrated with your operating system like any other native application. To achieve our goal we use standard Linux technologies like containers (LXC) to separate the Android operating system from the host. Any Android version is suitable for this approach and we try to keep up with the latest available version from the Android Open Source Project.
The project is open source and theoretically any application can be run. Anbox does not have direct access to a user's hardware or data. It should be noted that while it is possible to install the Google Play Store, Google will not allow anyone to ship applications if the device is not certified and the vendor has not signed an agreement. 
|Community Support Only!:|
- Do not use physical devices (mobile phones or tablets) for any kind of anonymous activities because any physical device has a unique IMEI number which can be easily fetched by Android applications. Always use virtual devices such as Anbox or Android x86 for these kind of activities.
- Always prefer using free and open source (FOSS) Android applications because they usually don't use any kind of surveillance. Using applications from F-Droid [archive] repositories is recommended.
- Do not install Android Package Kits (APKs) directly from untrusted sources.
- Always check permissions before starting an application. Note the Android settings menu only allows the user to manage dangerous permissions (such as Camera, Storage, Location, Phone etc.) but not AppOps (application operations) permissions. ADB shell or extended GUI application/permission manager [archive] (root required) is needed in order to display and manage not only dangerous but AppOps permissions.
- Do not store any private information inside Anbox or Android x86 filesystems.
- As the Android system cannot prevent applications from accessing the Internet, additional firewall management is required. Android uses Linux iptables firewall manager so a GUI application like AFWall+ [archive] can be used to control what applications are allowed to access the Internet (root needed).
- If a proprietary, non-free Android application installation is required, prefer installation from Google Play Store using an anonymous account. An Aurora Store [archive] application can be useful for this purpose. Do not use your real Google Account and do not download and install APKs from third-party websites because it can be dangerous. 
There are several issues with running popular Android applications using Anbox or Android x86 Workstation on top of a non-physical, certified Android device.
Unsupported CPU Architecture
Most popular Android applications (especially from Google Play Store) were written for ARMv7 and rarely for ARMv8 architectures. Therefore, some applications do not have support for x86 or x86_64 architectures. Android x86 users can use the
libhoudini library in order to try to emulate ARMv7 architecture but many Android applictions written for ARM still don't work.
Many non-free, popular Android applications check the device fingerprint for hardware identification purposes. Both Anbox and Android x86 have emulator fingerprints so applications can easily detect that an emulator is in use. It is generally possible to spoof the device fingerprint, but it is necessary to rebuild the Android image for Anbox. Android x86 can utilize the Magisk module called MagiskHide Props Config in order to spoof the device fingerprint.
Network Interface Detection
Most popular Android applications detect network adapters and will not work properly if no Wi-Fi or mobile connection is established. Anbox uses a bridge network interface by default so some applications will not see the Internet connection. However, Android x86 starting from Nougat has a built-in virtual Wi-Fi interface so applications think that a real Wi-Fi connection is established.
Google Play Services Mechanisms
At present, the biggest problem with running popular Android applications on top of a non-physical Android device is passing SafetyNet by Google. Android consists of two parts:
- The Android system itself (Android Open Source Project). This is a base system.
- A proprietary subsystem called Google Play Services. This helps applications from Google Play Store to interact with Google servers. This is an optional subsystem but all Android devices which are certified by Google have this arrangement.
If only free software (FOSS) applications will be run, then Google Play Services is unneeded since all applications from F-Droid are built without a dependency upon Google Play Services. If some types of proprietary applications are needed, this can be problematic because some will use the Google Play Services mechanism.
Generally, Google Play Services consists of two important parts:
- GCM (Google Cloud Messages)
GCM is a proprietary mechanism for delivering Push Notifications from Google servers. GCM is used by ~70-80% of proprietary applications from Google Play Store which rely upon the mechanism. It is not difficult to enable GCM support for both Android x86 and Anbox. The Android x86 image comes with built-in, non-free Google Play Services so GCM is enabled by default. With Anbox, it is possible to install either proprietary Google Play Services (OpenGAPPS) or an open-source implementation of Google Play Services called Micro-G.
SafetyNet is a mechanism which verifies the integrity of the device. If a device is not certified by Google Corporation then most of the proprietary Android applications from Google Play Store will not run because many use SafetyNet to check the device is authentic and has not been tampered with. Nowadays there is no way to pass SafetyNet on either Android x86 or Anbox because Google uses its own closed-source algorithm for non-real devices detection. SafetyNet is used by ~30-50% of Google Play Store applications, especially those relating to banking and social networks such as Tinder.
Anbox inside Whonix ™ vs. Android x86 Workstation
There are both distinct advantages and disadvantages of running Android applications in a native Whonix-Workstation ™ versus an Android x86 Workstation. 
Table: Anbox Advantages and Disadvantages 
|Bootloader / Ramdisk||Anbox does not have any type of bootloader and ramdisk. Consequently it is impossible to install Magisk or some kind of recovery tool which is probably necessary for some operations like hiding root from applications (for example Magisk Hide).|
|Emulation||No emulation is required, therefore Android applications can be run in a native Whonix-Workstation ™ environment.|
|Networking||Anbox does not provide a virtual Wi-Fi (|
|Speed||Android applications run faster in this configuration.|
Table: Android x86 Workstation Advantages and Disadvantages
|Bootloader / Ramdisk||It is possible to use Magisk to achieve root permissions and hide root from applications on Android x86. |
|Networking||Android x86 provides a virtual Wi-Fi interface (|
|Operating System||The full Android stack implemented as Android x86 is a full operating system which requires hardware virtualization (unlike Anbox).|
|Security||This configuration is less secure than utilizing a Whonix-Workstation ™. |
|Software||Any version of Android from 4.x to 9.x can be installed (Anbox provides only Nougat).|
|Speed||This configuration is slower as Android x86 does not provide any type of Guest Additions meaning no graphic card drivers are supported.|
Perform all installation steps inside Whonix-Workstation ™. No Whonix-Gateway ™ modifications are required.
A StandaloneVM is most suitable, otherwise changes will be non-persistent (lost after VM restart). Instructions on how to make Anbox persistent using a TemplateBased AppVM do not exist yet; see footnote for experimental instructions. 
Qubes-Whonix ™ requires the use of a Qubes VM kernel [archive].  Users can follow the instructions from the Qubes website Installing kernel in Debian VM [archive] which are equally functional in Qubes-Whonix ™.
It has been reported [archive] that it is necessary to enable Anbox software rendering [archive], but it is unclear how to accomplish that at present. The command from the previous link is likely non-functional because this guide does not use snap. Snap is not utilized because that would break the Always Verify Signatures recommendation (snap does not verify software signatures). 
From Start Menu
Start menu →
From Command Line
anbox launch --package=org.anbox.appmgr --component=org.anbox.appmgr.AppViewActivity
It is suggested to install F-Droid. The instructions below document how to download and verify F-Droid inside Whonix-Workstation ™. 
Figure: F-Droid Images
In a terminal, run. 
Files dropped to this download directory are readily visible to applications within Anbox.
- Running Android Apps inside Whonix-Workstation - Anbox - Proof of concept [archive]
- Integrate Anbox into Whonix-Workstation [archive]
- For example it disables SELinux which is a core part of the security model; see https://github.com/anbox/platform_system_core/commit/71907fc5e7833866be6ae3c120c602974edf8322 [archive]
- See the dates on the Github repositories. https://github.com/anbox [archive]
- https://anbox.io/#about [archive]
- https://anbox.io/#faq [archive]
- Note that most non-free applications from Google Play Store will not work properly without Google Play Services installed. Some will never work at all because an Android virtual device cannot pass Google's SafetyNet mechanism.
- https://forums.whonix.org/t/integrate-anbox-into-whonix-workstation/9642 [archive]
- The networking and software disadvantages below are very critical.
- Some individuals have already achieved this on Android x86.
- Also, it may be possible to run ssh-server on Whonix-Workstation ™ and connect the Android x86 through Termux or similar.
- Although it may have more flexibility, as static IP connections on the Android x86 Workstation have been accomplished.
anbox-container-manager.serviceexpects this file name.
- The following steps are probably not required because it should work out of the box after rebooting.
- This is because Anbox comes with its own bridged network. Whitelisting that interface in Whonix-Workstation ™ firewall is undocumented and might require source code modifications. Patches are Welcome.
These steps do not work yet.
[ 2019-10-14 11:00:41] [launch.cpp:214@operator()] Session manager failed to become ready
- Using a VM kernel is currently challenging to use because Anbox is implemented using kernel modules, see: Simplify and promote using in-vm kernel [archive].
- https://forums.whonix.org/t/snap-store-snaps-snapcraft-io-a-new-software-source/7631 [archive]
- https://f-droid.org/docs/Release_Channels_and_Signing_Keys/ [archive]
- Minor changes in the output such as new uids (email addresses) or newer expiration dates are inconsequential.
- https://forums.whonix.org/t/running-android-apps-inside-whonix-workstation-anbox-proof-of-concept/7441/13 [archive]
This is a wiki. Want to improve this page? Help is welcome and volunteer contributions are happily considered! Read, understand and agree to Conditions for Contributions to Whonix ™, then Edit! Edits are held for moderation. Policy of Whonix Website and Whonix Chat and Policy On Nonfreedom Software applies.
The personal opinions of moderators or contributors to the Whonix ™ project do not represent the project as a whole.