Tech Blog

Security Testing

Android Pentesting Using Drozer – 1

By Karapureddy Yeswanth Reddy2 min read
← Back to blog

Introduction:

Drozer is an FSecureLABS Android application security testing tool used for penetration testing to scan application components for potential vulnerabilities. It acts as a local Android application and works by connecting to the Dalvik virtual machine.

Benefits of using Drozer:

  • Static analysis
  • Run time manipulation
  • Information gathering
  • Enumeration of packages

Drozer Installation Steps:

1. Install docker and run the Drozer docker image

cmd: docker run -it fsecurelabs/drozer

2. Connect the Drozer console to the server IP

cmd: drozer console connect –server 192.168.31.154

Drozer Usage:

In this document, for reference, a vulnerable package is used i.e. com.mwr.example.sieve

1. The app.package.list module is used to retrieve the list of installed packages on the device.

cmd: run app.package.list

2. The app.package.info module is used to retrieve the information for the requested package on the device. i.e., com.mwr.example.sieve – package name

cmd: run app.package.info -a com.mwr.example.sieve

3. The app.package.manifest module is used to retrieve the Android manifest file and to show it on the terminal.

cmd: run app.package.manifest com.mwr.example.sieve

4. The app.package.attacksurface module is used to check the package’s attack surface and it displays the number of vulnerable components in the package. 

cmd: run app.package.attacksurface com.mwr.example.sieve

5. In Drozer, there are some modules for checking the exported activities, services, content providers, and broadcast receivers. (android:exported=true)

cmd: run app.activity.info -a com.mwr.example.sieve

There are three exported activities without any permissions and these might be vulnerable.

cmd: run app.service.info -a com.mwr.example.sieve

These two services are found without any permissions and these might be vulnerable.

cmd: run app.provider.info -a com.mwr.example.sieve

There are two content providers which do not have any READ and WRITE permissions given for them; These may be vulnerable to traversal and injection vulnerabilities.

cmd: run app.broadcast.info -a com.mwr.example.sieve

As there are no vulnerable broadcast receivers, here it shows ‘no matching receivers’. 

6. There are three exported activities in the com.mwr.example.sieve package, one of the activity is exploited and bypassed the login page as shown below: 

Before the exploitation:

This login screen can be bypassed by invoking the activity using Drozer or it can be done using ADB commands also.

After exploitation:

The same method can be followed to exploit other exported activities.

We will continue with this topic in an upcoming article. Stay tuned!

Keep reading

You may be interested in

Browse all articles →
Information Security: Best Practices
June 5, 20234 min read

Information Security: Best Practices

Protecting an information technology infrastructure from the ever-growing cyber attacks and threats is quite a challenging job. Everyday, hackers try to discover new ways to hack into our systems in order to steal sensitive information. Lack of information security measures in an organization can put every aspect of Confidentiality, Integrity, and Availability components of a […]

By Sangam GandhiRead More →
API Security
December 21, 20228 min read

API Security

What is API? An API stands for Application Programming Interface. It is a software intermediary that allows two applications to communicate with each other using a set of definitions and protocols. An API architecture usually contains a client and server. The application sending a request is called client, and the application sending a response is […]

By Abinash MishraRead More →
Using SCEP Certificates with Okta and SureMDM for Zero Trust Security
August 5, 20257 min read

Using SCEP Certificates with Okta and SureMDM for Zero Trust Security

For businesses embracing zero-trust principles, secure certificate-based authentication isn’t just nice to have—it’s a necessity. With Okta as your Identity Provider (IdP) and SureMDM as your unified endpoint management solution, you can now seamlessly distribute and manage device certificates using Simple Certificate Enrollment Protocol (SCEP). This blog will guide you through: Why Use SCEP with […]

By Sunny KumarRead More →