Android Studio is recommended for a Windows host machine, while Genymotion is a suitable alternative within the Kali VM due to Android Studio's instability.
Uncheck Launch in .. tool window in the Emulator Settings.
Use the Android Studio Device Manager to create 2 new Android Virtual Devices (AVD)
one with the Q Release (Android 10.0/API Level 29) Google Play image
one with the x86 Marshmallow Release (Android 6.0/API Level 23)
Tap on the Build number several times to enable Developer Options.
Enter System > Developer options.
Set the following options:
Enable OEM Unlocking
Disable Automatic system updates
Enable USB debugging
Enable Wireless debugging
Enable Disable adb authorization timeout
Enable Stay awake (while charging) (if wanted)
📌 I will use a physical Android Sony device for this course. To enable automatic USB connection to the Kali VM, I've added a line to the kali.vmx VM config file, obtaining the vid and pid values from the vmware.log file.
Android Device Emulator is running on the HOST machine
# Start adb on host machine
adb -a nodaemon server
# if port is already in use, kill the process first
taskkill /f /t /im adb.exe # Windows
adb kill-server # Linux
# Connect to the emulator via LAN
adb -H <host_machine_IP> -P 5037 shell
MobSF
sudo mkdir -p ~/docker/mobsf
chown 9901:9901 ~/docker/mobsf
docker run -it --rm --name mobsf -p 8000:8000 -v ~/docker/mobsf:/home/mobsf/.MobSF opensecurity/mobile-security-framework-mobsf:latest
# Set the above command as "mobsf" bash/zsh alias
Frida & Objection
# Frida with pipx
# Install pipx to manage frida-tools in its own VirtualEnv
sudo apt update
sudo apt install -y python3 python3-pip python3-venv pipx
# sudo rm -rf ~/.local/pipx
python3 -m pipx ensurepath
pipx install frida-tools
pipx upgrade frida-tools
# Restart zsh terminal