Run Android (.apk) mobile applications.
Installation
Install Anbox
sudo apt install anbox
Read setup documentation
cat /usr/share/doc/anbox/README.Debian
Enable Kernel modules
sudo modprobe ashmem_linux
sudo modprobe binder_linux
If the modules are not available in the OS, follow these instructions (GitHub).
git clone https://github.com/anbox/anbox-modules.git
cd anbox-modules/
sudo apt install dkms
sudo cp anbox.conf /etc/modules-load.d/
sudo cp 99-anbox.rules /lib/udev/rules.d/
sudo cp -rT ashmem /usr/src/anbox-ashmem-1
sudo cp -rT binder /usr/src/anbox-binder-1
sudo apt install linux-headers-amd64
sudo dkms install anbox-ashmem/1 # GIVES AN ERROR :(
sudo dkms install anbox-binder/1
Download the Android image to /var/lib/anbox/android.img
Download latest pre-built images at https://build.anbox.io/android-images
sudo mv ~/Downloads/android_amd64.img /var/lib/anbox/android.img
Restart the service
sudo service anbox-container-manager restart
Install adb
sudo apt install android-tools-adb
Run Anbox
In Kali menu, search for Anbox Application Manager. This will start the GUI.
Command-line
anbox launch --package=org.anbox.appmgr --component=org.anbox.appmgr.AppViewActivity
Install applications (.apk) in Anbox
adb install <filename>.apk
Intercept resquests from Anbox using Burp Suite
Use IP address from the VPN or any network that the web app will try to connect to.
ip a | grep tun0
In Burp, in Proxy->Options, under Proxy Listeners, edit the listener to bind on “All interfaces” instead of “Loopback only”.
adb shell settings put global http_proxy x.x.x.x:8080
Troubleshooting
sudo service anbox-container-manager status
sudo journalctl -x -b -l | grep anbox