Skip to content
/ Adrill Public

An Android native libraries injection tool. supports arch arm/arm64/x86/x86_64. Support Android 4.x to 11.0.

License

Notifications You must be signed in to change notification settings

mustime/Adrill

Repository files navigation

About

English | 中文

Adrill is an Android native libraries injection tool written in C++1X, supports arch arm/arm64/x86/x86_64.

You may notice there are already tons of similar inject tools, but few of them targets on all archs(not that I know of).

Furthermore, Adrill make it more easier when it comes to zygote[64] injection(see for workaround at ptrace_wrapper.cc). And there will be detail info printed when any error occured.

I've test on multiple arch platforms from Android 4.x to 11.0. Fire an issue if there's something I could help with.

Notice: running on root privilege is a must.

Build from source

First clone this repository:

git clone git@github.com:mustime/Adrill.git

Then you need to update the submodle:

cd Adrill/
git submodule update --init

Say you want to use Adrill in Android emulators, i.e., normally a x86 executable:

cmake -S . -B build -DCMAKE_SYSTEM_NAME=Android -DCMAKE_SYSTEM_VERSION=21 -DCMAKE_ANDROID_ARCH_ABI=x86 -DCMAKE_ANDROID_NDK=$ANDROID_NDK_ROOT
cmake --build build --parallel 4 --target adrill

Notice: define ${ANDROID_NDK_ROOT} in your env or change the command at will.

Usage:

adrill [--pid <number>] | [--pname <string>] --libpath <path>
   -h,--help      print this message.
      --pid       target process id. e.g., grep from 'ps' command
      --pname     target process name. used to match with content in /proc/<pid>/cmdline.
      --libpath   absolute path to inject. only supports ELF file.

Liscense

See LISCENSE file for more details

About

An Android native libraries injection tool. supports arch arm/arm64/x86/x86_64. Support Android 4.x to 11.0.

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published