adbi


Source link: https://github.com/crmulliner/adbi

adbi - The Android Dynamic Binary Instrumentation Toolkit

Simple binary instrumentation toolkit for Android ARM + Thumb.

Instrumentation is based on library injection and hooking function entry points (in-line hooking).

The toolkit consists of two main components the hijack tool and the base library.

hijack

The hijack tool provides the injection functionality. It supports a number of modes for supporting older and newer Android devices. hijack provides help on the command line.

libbase

The base library provides the hooking and unhooking functionality. The base library is compiled as a static library so it can be directly included in the actual instrumentation library. This is done so we can keep everything in /data/local/tmp.

Below we provide and easy to follow step-by-step instructions for howto build and use adbi. The example instrument hijacks epoll_wait() and logs every call to a file.

=== External Resources ===

more information at: http://www.mulliner.org/android/

slide deck about this toolkit: http://www.mulliner.org/android/feed/binaryinstrumentationandroid_mulliner_summercon12.pdf

old code (with more examples): http://www.mulliner.org/android/feed/collin_android_dbi_v02.zip

=== Prerequisites ===

Android SDK Android NDK

=== How to Build ===

= build the hijack tool =

cd hijack cd jni ndk-build cd .. adb push libs/armeabi/hijack /data/local/tmp/ cd .. 

= build the instrumentation base code =

cd instruments cd base cd jni ndk-build cd .. cd .. 

= build instrumentation example =

cd example cd jni ndk-build cd .. adb push libs/armeabi/libexample.so /data/local/tmp/ 

=== How to Run ===

adb shell su cd /data/local/tmp >/data/local/tmp/adbi_example.log # GET PID from com.android.phone ./hijack -d -p PID -l /data/local/tmp/libexample.so cat adbi_example.log 

output should look similar to:

started hooking:
epoll_wait = 0x4004c378 ARM using 0x4a84a588 epoll_wait() called epoll_wait() called epoll_wait() called removing hook for epoll_wait() 

Resources

This library imitates Google Inbox mailbox effect on the drop-down return.

A tool for mocking HTTP services.

Features:

  • HTTP response stubbing, matchable on URL, header and body content patterns
  • Request verification
  • Runs in unit tests, as a standalone process or as a WAR app
  • Configurable via a fluent Java API, JSON files and JSON over HTTP
  • Record/playback of stubs
  • Fault injection
  • Per-request conditional proxying
  • Browser proxying for request inspection and replacement
  • Stateful behaviour simulation
  • Configurable response delays

Mock your HTTP responses to test your REST API.

Mocky is a simple app which allows to generate custom HTTP responses. It's helpful when you have to request a build-in-progress WS, when you want to mock the backend response in a single app, or when you want to test your WS client.

Get a full fake REST API with zero coding in less than 30 seconds.

Java tool for mocking HTTP server behaviours for testing HTTP client code.

Fixd is an HTTP server fixture for testing web clients. Unlike a mock web server, it is backed by a fully functional HTTP server, bound to a port of your choosing. Its fluent interface allows you to quickly and easily script responses to client requests. Its clear, declarative interface also makes the setup portion of your unit tests easy to read and understand.

Topics


2D Engines   3D Engines   9-Patch   Action Bars   Activities   ADB   Advertisements   Analytics   Animations   ANR   AOP   API   APK   APT   Architecture   Audio   Autocomplete   Background Processing   Backward Compatibility   Badges   Bar Codes   Benchmarking   Bitmaps   Bluetooth   Blur Effects   Bread Crumbs   BRMS   Browser Extensions   Build Systems   Bundles   Buttons   Caching   Camera   Canvas   Cards   Carousels   Changelog   Checkboxes   Cloud Storages   Color Analysis   Color Pickers   Colors   Comet/Push   Compass Sensors   Conferences   Content Providers   Continuous Integration   Crash Reports   Credit Cards   Credits   CSV   Curl/Flip   Data Binding   Data Generators   Data Structures   Database   Database Browsers   Date &   Debugging   Decompilers   Deep Links   Dependency Injections   Design   Design Patterns   Dex   Dialogs   Distributed Computing   Distribution Platforms   Download Managers   Drawables   Emoji   Emulators   EPUB   Equalizers &   Event Buses   Exception Handling   Face Recognition   Feedback &   File System   File/Directory   Fingerprint   Floating Action   Fonts   Forms   Fragments   FRP   FSM   Functional Programming   Gamepads   Games   Geocaching   Gestures   GIF   Glow Pad   Gradle Plugins   Graphics   Grid Views   Highlighting   HTML   HTTP Mocking   Icons   IDE   IDE Plugins   Image Croppers   Image Loaders   Image Pickers   Image Processing   Image Views   Instrumentation   Intents   Job Schedulers   JSON   Keyboard   Kotlin   Layouts   Library Demos   List View   List Views   Localization   Location   Lock Patterns   Logcat   Logging   Mails   Maps   Markdown   Mathematics   Maven Plugins   MBaaS   Media   Menus   Messaging   MIME   Mobile Web   Native Image   Navigation   NDK   Networking   NFC   NoSQL   Number Pickers   OAuth   Object Mocking   OCR Engines   OpenGL   ORM   Other Pickers   Parallax List   Parcelables   Particle Systems   Password Inputs   PDF   Permissions   Physics Engines   Platforms   Plugin Frameworks   Preferences   Progress Indicators   ProGuard   Properties   Protocol Buffer   Pull To   Purchases   Push/Pull   QR Codes   Quick Return   Radio Buttons   Range Bars   Ratings   Recycler Views   Resources   REST   Ripple Effects   RSS   Screenshots   Scripting   Scroll Views   SDK   Search Inputs   Security   Sensors   Services   Showcase Views   Signatures   Sliding Panels   Snackbars   SOAP   Social Networks   Spannable   Spinners   Splash Screens   SSH   Static Analysis   Status Bars   Styling   SVG   System   Tags   Task Managers   TDD &   Template Engines   Testing   Testing Tools   Text Formatting   Text Views   Text Watchers   Text-to   Toasts   Toolkits For   Tools   Tooltips   Trainings   TV   Twitter   Updaters   USB   User Stories   Utils   Validation   Video   View Adapters   View Pagers   Views   Watch Face   Wearable Data   Wearables   Weather   Web Tools   Web Views   WebRTC   WebSockets   Wheel Widgets   Wi-Fi   Widgets   Windows   Wizards   XML   XMPP   YAML   ZIP Codes