Skip to main content

A tool/library allowing dynamic library injection into running processes

Project description

Pyinjector

Tests (GitHub Actions) PyPI Supported Python Versions PyPI version Downloads GitHub license

A cross-platform tool/library allowing dynamic library injection into running processes. If you are looking for a way to inject python code into a running process, try the hypno library.

Pyinjector has no external python dependencies. It is implemented as a python wrapper for kubo/injector.

Installation

pip install pyinjector

Both source distributions, manylinux2010 wheels and windows wheels are uploaded to Pypi for every release.

Usage

CLI

inject <pid> <path/to/shared/library>

API

from pyinjector import inject

inject(pid, path_to_so_file)

How it works

We build kubo/injector as a C-extension and use its interface using ctypes. kubo/injector is an awesome repo allowing to inject shared libraries into running processes both on windows (CreateRemoteThread+LoadLibrary) and on linux (ptrace).

Project details


Download files

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

Files for pyinjector, version 1.0.5
Filename, size File type Python version Upload date Hashes
Filename, size pyinjector-1.0.5.zip (30.3 kB) File type Source Python version None Upload date Hashes View
Filename, size pyinjector-1.0.5-cp310-cp310-win_amd64.whl (13.6 kB) File type Wheel Python version cp310 Upload date Hashes View
Filename, size pyinjector-1.0.5-cp310-cp310-win32.whl (11.4 kB) File type Wheel Python version cp310 Upload date Hashes View
Filename, size pyinjector-1.0.5-cp310-cp310-manylinux_2_12_x86_64.manylinux2010_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl (38.4 kB) File type Wheel Python version cp310 Upload date Hashes View
Filename, size pyinjector-1.0.5-cp39-cp39-win_amd64.whl (13.6 kB) File type Wheel Python version cp39 Upload date Hashes View
Filename, size pyinjector-1.0.5-cp39-cp39-win32.whl (11.4 kB) File type Wheel Python version cp39 Upload date Hashes View
Filename, size pyinjector-1.0.5-cp39-cp39-manylinux_2_12_x86_64.manylinux2010_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl (38.3 kB) File type Wheel Python version cp39 Upload date Hashes View
Filename, size pyinjector-1.0.5-cp38-cp38-win_amd64.whl (13.7 kB) File type Wheel Python version cp38 Upload date Hashes View
Filename, size pyinjector-1.0.5-cp38-cp38-win32.whl (11.4 kB) File type Wheel Python version cp38 Upload date Hashes View
Filename, size pyinjector-1.0.5-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl (38.6 kB) File type Wheel Python version cp38 Upload date Hashes View
Filename, size pyinjector-1.0.5-cp37-cp37m-win_amd64.whl (13.6 kB) File type Wheel Python version cp37 Upload date Hashes View
Filename, size pyinjector-1.0.5-cp37-cp37m-win32.whl (11.4 kB) File type Wheel Python version cp37 Upload date Hashes View
Filename, size pyinjector-1.0.5-cp37-cp37m-manylinux_2_12_x86_64.manylinux2010_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl (38.6 kB) File type Wheel Python version cp37 Upload date Hashes View
Filename, size pyinjector-1.0.5-cp36-cp36m-win_amd64.whl (13.6 kB) File type Wheel Python version cp36 Upload date Hashes View
Filename, size pyinjector-1.0.5-cp36-cp36m-win32.whl (11.4 kB) File type Wheel Python version cp36 Upload date Hashes View
Filename, size pyinjector-1.0.5-cp36-cp36m-manylinux_2_12_x86_64.manylinux2010_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl (38.6 kB) File type Wheel Python version cp36 Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor NVIDIA NVIDIA PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page