Skip to main content

A powerful and versatile dynamic instrumentation toolkit

Project description

MIGI

Migi(My Ideas Got Incepted) is a powerful and versatile dynamic instrumentation toolkit.

How it works

By injecting Python scripts into target host, migi makes host manipulation possible.

To get started, follow the steps below.

1. Install from PyPI

pip install migi

2. Attach to target host

import migi

session = migi.attach_process('notepad.exe', python_console=[])

An interactive Python console, which runs inside the host app, will show up if nothing goes wrong.

3. Make function calls

Typing the scripts below into that host-running console you've just created and everything should be self-explanatory.

from ctypes import *
from migi.decorators import stdcall

@stdcall('MessageBoxW', 'User32.dll')
def _native_message_box_w(hwnd: c_void_p, content: c_wchar_p, title: c_wchar_p, flags: c_uint32) -> c_int32:
    pass


def message_box(content: str, title: str, flags: int = 0) -> c_int32:
    return _native_message_box_w(None, create_unicode_buffer(content), create_unicode_buffer(title), flags)

message_box("I'm in", '1')

4. Learn more

Learn more about calling convention, api interception and others by referring to docs and examples

How to build

1. Platform support

  • Windows
cmake --build out/windows --target all path_to_src
  • Other platform plans in roadmap.md

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

migi-0.0.19.tar.gz (43.7 kB view details)

Uploaded Source

Built Distribution

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

migi-0.0.19-cp39-cp39-win32.whl (355.4 kB view details)

Uploaded CPython 3.9Windows x86

File details

Details for the file migi-0.0.19.tar.gz.

File metadata

  • Download URL: migi-0.0.19.tar.gz
  • Upload date:
  • Size: 43.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.7.1 importlib_metadata/4.9.0 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7

File hashes

Hashes for migi-0.0.19.tar.gz
Algorithm Hash digest
SHA256 cb00efe2051152965c81e164abc275dd7a7648f85ecbc4fa33ec49f32c9426ff
MD5 6a553b241246105ff297110f069aea1a
BLAKE2b-256 bb3a9cbb0884330897566374c5b13142d93471760100f91b59951cb5fff4f046

See more details on using hashes here.

File details

Details for the file migi-0.0.19-cp39-cp39-win32.whl.

File metadata

  • Download URL: migi-0.0.19-cp39-cp39-win32.whl
  • Upload date:
  • Size: 355.4 kB
  • Tags: CPython 3.9, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.7.1 importlib_metadata/4.9.0 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7

File hashes

Hashes for migi-0.0.19-cp39-cp39-win32.whl
Algorithm Hash digest
SHA256 06b90a674e91442ea8806c9f20a6518b5c098e30b73a6b7368372baf45cbba3a
MD5 39cfe50c4f5e9a2fe68b30a8831cd2be
BLAKE2b-256 6314986ee8b0230625655517f8205e9e5ff03e85a6dac3c06378ea5bbfc1bd58

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