Skip to main content

Bungeegum

Bungeegum is a set of tools designed to test code execution payloads within the context of a standard Android application. By leveraging the powerful Frida instrumentation framework, it precisely replicates the runtime conditions of an Android app, simulating the execution of ELFs or shellcode as though they were triggered by a remote code execution exploit.

Prerequisites

Install

Note: Bungeegum is developed on and regularly tested with Ubuntu 18.04 and Python 3.8. Other distributions and versions may work, but are currently untested.

  1. Clone the repository

  2. Install dependencies

    sudo apt-get update
    sudo apt-get install python3-venv python3.8-venv make wget xz-utils -y
    python3.8 -m venv venv
    source venv/bin/activate
    (venv) pip install --upgrade pip
    
  3. Build the APK and install the Python package by running the make command:

    make
    

Supported Android Versions

Bungeegum has been tested successfully on Android 7, 9, 11, and 12.

Usage

(venv) bungeegum -h
usage: bungeegum [-h] -d DEVICE [-r] (-s SHELLCODE | -e ELF) [-a [ARGS [ARGS ...]]]

Execute code within an application context

optional arguments:
  -h, --help            show this help message and exit
  -d DEVICE, --device DEVICE
                        ADB device ID to run on
  -r, --remote          Set if the file to be executed is on the device
  -s SHELLCODE, --shellcode SHELLCODE
                        Shellcode file to execute on the device
  -e ELF, --elf ELF     ELF file to execute on the device
  -a [ARGS [ARGS ...]], --args [ARGS [ARGS ...]]
                        Optional args to pass to the ELF file

Examples

  • Run an ELF from the host on the device:
bungeegum --elf ~/my_elf/arm64-v8a/my_elf
  • Run a shellcode blob on the device
bungeegum --shellcode ~/my_shellcode.bin
  • Run an on-device ELF:
bungeegum --remote --elf /system/bin/log --args "hello world"

Contributing

Contributions are welcome! If you find any issues or have suggestions for improvements, please open an issue or submit a pull request.

License

This project is licensed under the GPLv2 License.

Metadata

Release files for bungeegum 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for bungeegum 0.1.0
File Size Uploaded
bungeegum-0.1.0.tar.gz 20.3 MB Details

Built distribution (wheel)

Table of built distributions (wheels) for bungeegum 0.1.0
File Interpreter ABI Platform
bungeegum-0.1.0-py3-none-any.whl Python 3 none any Details

Total release size: 40.6 MB

Release files / bungeegum-0.1.0.tar.gz

Download URL bungeegum-0.1.0.tar.gz
Size 20.3 MB
Tags Source
SHA-256 checksum
How to use checksums
4135c572891088e626157acafdb406e94005bbe0ebb6a299d825f521618f505a
BLAKE2b-256 checksum
How to use checksums
d0a463b781a51a0f9c8190851422cef00a62804af0343a9227da41564fa0b15c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.8.0 colorama/0.4.4 importlib-metadata/4.6.4 keyring/23.5.0 pkginfo/1.8.2 readme-renderer/34.0 requests-toolbelt/0.9.1 requests/2.25.1 rfc3986/1.5.0 tqdm/4.57.0 urllib3/1.26.5 CPython/3.10.12

Release files / bungeegum-0.1.0-py3-none-any.whl

Download URL bungeegum-0.1.0-py3-none-any.whl
Size 20.3 MB
Tags Python 3
SHA-256 checksum
How to use checksums
71cc91eb2d28224ae80785aa845e0fddeefb6b41dbb51994008a842c961147b0
BLAKE2b-256 checksum
How to use checksums
73559ff3a828c21ebafe681c7af4b0825ab9509fa0bcb0d21e094c15e90f2e92
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.8.0 colorama/0.4.4 importlib-metadata/4.6.4 keyring/23.5.0 pkginfo/1.8.2 readme-renderer/34.0 requests-toolbelt/0.9.1 requests/2.25.1 rfc3986/1.5.0 tqdm/4.57.0 urllib3/1.26.5 CPython/3.10.12

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page