Skip to main content

Mobile Pentest Toolkit (MPT)

Project description

python size lastcommit follow

MPT (Mobile Pentest Toolkit)

The MPT (Mobile Pentest Toolkit) is a must-have solution for your android penetration testing workflows. This tool allow you to automate security tasks and focus on security assessment without to know, where the tools are located and with parameters are required.

Features:

  • Automation of your security checks
  • Perform project based security assessments
  • TMP provides a full set of required tools on any linux distribution
    • local installation of required tools, you can easy extend missing tools
    • installation of required APKs on your devices
  • ADB is included
  • Switch WI-FI proxy on your device (e.g. Burp Proxy)
  • Show colored logcat output with special highlighting
  • Install and run frida server on your device
  • Dump application memory
  • Analyse source code using several decompilers
  • Backup and dump you application data from device. Even if backup is disabled.
  • Disable SSL pinning
  • Disable root detection
  • Start security tools from one place

list of available tools:

  • MobSF [ Mobile Security Framework (MobSF) ]
  • RMS [ Runtime Mobile Security (RMS) ]
  • objection [ Runtime Mobile Exploration Toolkit ]
  • jadx [ Dex to Java decompiler ]
  • jd-gui [ Java Decompiler, dex2jar required ]
  • luyten [ Java Decompiler Gui for Procyon ]
  • sqlitestudio [ Multi-platform SQLite database manager ]
  • pidcat [ excellent logcat color script ]
  • pidcat-ex [ PID Cat (extended version) ]
  • adus [ Bash script to dump, build and sign apk ]
  • fridump [ Memory dumping tool uring frida ]
  • adb [ Android Debug Bridge (adb) ]
  • aapt [ Android Asset Packaging Tool ]
  • abe [ Android backup extractor, android:allowBackup="true" required ]
  • signapk [ sign an apk with the Android test certificate ]
  • apktool [ A tool for reverse engineering Android apk files ]
  • dex2jar [ Convert the Dalvik Executable (.dex) file to jar ]
  • janus [ scans an APK and an Android device for CVE-2017–13156 ]
  • linux-router [ Set Linux as router in one command. Able to provide Internet, or create WiFi hotspot ]
  • scrcpy [ Application mirrors Android devices (video and audio) connected via USB ]

The mobile pentest toolkit (MPT) was presented on conference OWASP Bucharest AppSec 2018.

Installation using PIPX

pipx install git+https://github.com/ByteSnipers/mobile-pentest-toolkit --include-deps

if required install pipx

  1. install OS package python-pipx or pipx
  • also possible to install using pip: python3 -m pip install --user pipx
  1. pipx ensurepath

Update using PIPX

pipx install git+https://github.com/ByteSnipers/mobile-pentest-toolkit --include-deps --force

Update using MPT

mpt --update

Uninstall using PIPX

pipx uninstall mptsec

Install Dependencies (local usage)

pip3 install -r requirements.txt

Alias pentest-dir

You can set this alias to quickly and easily navigate to your project directory based on the configuration in the settings.json file. Here’s how you can do it:

Adding the Alias to .bashrc or .zshrc

Run the following command to add the alias to your .bashrc file:

echo '\n# mpt alias\nalias pentest-dir="cd $(cat /home/$USER/.mpt/settings.json | grep pentest-dir | awk -F'\''\\"'\'' '\''{print $4}'\'') && ls -l"' >> ~/.bashrc

You can also add a new alias manually to your .bashrc file:

alias pentest-dir="cd $(cat /home/$USER/.mpt/settings.json | grep pentest-dir | awk -F'\"' '{print $4}') && ls -l"

Activating the Alias:

After adding the alias, reload your .bashrc file to make it immediately available or open a new terminal window

source ~/.bashrc

Install zsh plugin (autocomplete support) - Outdated

:warning: You need to install Oh My ZSH

:warning: The command line options has not been updated for a while and does not match with the latest version. PRs are welcome

cp -r mpt/mpt-zsh-plugin/ ~/.oh-my-zsh/plugins/mpt

Enable MPT plugin in .zshrc by adding the fooling line plugins=(mpt)

Start New Project

  1. Setup pentest environment and install required tools
mpt --install-tools
  1. Setup a new pentest project
mpt --setup <apk-file>

Usage

mpt.py <command> [options]

options:
  -h, --help            show this help message and exit
  --update              Update MPT to the latest version

Pentest:
  Configure and manage current pentest

  --setup [APK]         Setup pentest environment
  --config              Show current pentest config

Frida:
  Run frida server and execute frida scripts

  -f, --frida           Run frida server on the device
  -fs, --frida-select-version
                        Run frida server on the device (select frida version)

  -s [package-name], --ssl-pinning [package-name]
                        Disable SSL Pinning (<package name> optional)
  -r [package-name], --root-detection [package-name]
                        Disable Root Detection (<package name> optional)

Application:
  Perform app related tasks

  -l [all], --list-packages [all]
                        Show all installed packages (use option 'all' to display system apps)
  -p [package-name], --pidcat [package-name]
                        Show colored logcat for a specific application (<package name> optional)
  -st, --screenshot     Take a screenshot from device screen
  -sc, --screen-copy    Mirrors Android device screen connected via USB to host (scrcpy)
  -D, --fridump         Dump application memory
  -b [package-name], --backup [package-name]
                        Backup an android application (<package name> optional)
  -d [decompiler], --decompile [decompiler]
                        Start java decompiler for source code analysis (<decompiler> optional): jadx(default), jd-gui, luyten

Tools:
  Install and run pentest tools on your host

  -tl, --tool-list      Show all supported tools
  -t tool [tool ...], --tool tool [tool ...]
                        Run selected tool with <arguments> (use option 'list' to display all tools)
  -i, --install-tools   Install pentesting tools on local system in a separate environment
  -a, --adb-run         Start adb server with root to avoid a lot of issues using adb

Proxy and WiFi:
  Manage proxy on device and WiFi settings locally

  -ps, --proxy-status   Check WiFi proxy status
  -pe [host:port], --proxy-enable [host:port]
                        Set proxy for WiFi connection on your device (optional <host:port>), if not set loads proxy settings from configuration file
  -pd, --proxy-disable  Disable WiFi proxy
  -ap, --access-point   Create an Hotspot which connected to internet and can be used for Burp proxy

License

GNU GPL v3 ©@bytesnipers

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mptsec-0.7.44.tar.gz (53.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

mptsec-0.7.44-py3-none-any.whl (51.0 kB view details)

Uploaded Python 3

File details

Details for the file mptsec-0.7.44.tar.gz.

File metadata

  • Download URL: mptsec-0.7.44.tar.gz
  • Upload date:
  • Size: 53.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.8

File hashes

Hashes for mptsec-0.7.44.tar.gz
Algorithm Hash digest
SHA256 a08d5828ec7e45e38c1b39fa39812378b9ce9fd07cf1960616005515070bc4d3
MD5 fd7177f8cdd0665310d74961a7b53fad
BLAKE2b-256 543414627379954fc884a58667d14f354866a4e0bf35d24080c4d54a06c9d96e

See more details on using hashes here.

File details

Details for the file mptsec-0.7.44-py3-none-any.whl.

File metadata

  • Download URL: mptsec-0.7.44-py3-none-any.whl
  • Upload date:
  • Size: 51.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.8

File hashes

Hashes for mptsec-0.7.44-py3-none-any.whl
Algorithm Hash digest
SHA256 1e2dcd9719c84142bf8d2620165fc1edcddc345df9847bef4156100ae0ca8c71
MD5 fe964968afca210525c6218b282efd5a
BLAKE2b-256 9b8ebf9f6ebd4d2b8cc1be1ac89cb9a75929bd8afdd14ab4167f5ff04c211456

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page