Hello everybody, this will be continuation of setting up a mobile pentesting lab.
The required tools need are:
- apktools
- adb shell
- Drozer
We will be using Kali Linux OS.
Let’s first start with the installation of apktools,
apt-get install apktool
Followed by installing adb (Android Debug Bridge),
apt-get install android-tools-adb
Lastly, we will install Drozer (current version is drozer-2.4.4 as of 2020), go to the github page: https://github.com/FSecureLABS/drozer/releases
Based on my experience, after cloning the repository I have to do a ‘python setup.py bdist_wheel’, however, there was an error.
Thus, what I did was to download the ‘drozer-2.4.4-py2-none-any.whl’, and do a pip install of the file.
pip install drozer-2.4.4-py2-none-any.whl
Now, we will need to install the Drozer agent on the Android emulator device however, because we are using Genymotion, we will need genymotion arm translation because there was an error while trying to install an application apk file.
The link to the genymotion arm translation: https://github.com/m9rco/Genymotion_ARM_Translation/tree/master/package
Download the packages that is compatible to your android version in the emulator.
Just pop the zip file into the android emulator and restart the emulator.
After, installing the translation package, we will then install the Drozer agent. Go to the fsecure lab page, where you can download the Drozer agent.
Once, you downloaded the drozer-agent apk file, all you need to do is to pop it in the android emulator to install it.
Before we connect to the device, enable the Drozer agent in the device. Then run this adb command in the shell.
adb connect <ip address of the device>
adb devices [to check whether the device have been connected]
adb forward tcp:31415 tcp:31415
The reason we run these adb shell command is to establish connection between the drozer client and agent via port forwarding.
drozer console connect
And finally, we will be able to connect to the drozer server and send commands to the drozer agent via the adb shell.
Alright that’s all for today. Have a nice day and bye bye 🙂 If there
Author: Derek