向可执行文件中注入python代码或者任意可执行文件
使用python解释器直接注入
import tkinter.messagebox
import peinjecter
def hello():
tkinter.messagebox.showinfo('Hello peinjecter!')
if __name__ == '__main__':
peinjecter.inject('target.exe', before=hello)
打包后再进行注入
import sys
import tkinter.messagebox
import peinjecter
def hello():
tkinter.messagebox.showinfo('Hello peinjecter!')
if __name__ == '__main__':
if getattr(sys, 'frozen', False):
peinjecter.inject('target.exe', before=hello)
else:
peinjecter.build()
注入其他可执行文件
import peinjecter
if __name__ == '__main__':
peinjecter.inject('target.exe', before='test.exe')
Metadata
Release files for peinjecter 1.0.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| peinjecter-1.0.0.tar.gz | 8.7 MB | Without provenance | Details for peinjecter-1.0.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| peinjecter-1.0.0-py3-none-any.whl | Python 3 | none | any | Details for peinjecter-1.0.0-py3-none-any.whl |
Total release size: 17.8 MB
Release files / peinjecter-1.0.0.tar.gz
| Download URL | peinjecter-1.0.0.tar.gz |
|---|---|
| Size | 8.7 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
33b7b77d5b0262b4032d958629dace9d98d8ecbf9788f7fd0cdcaa8570fe5280
|
|
BLAKE2b-256 checksum How to use checksums |
df00a4128f7849a268deb3d1e4d264593d3b71eb76ff0c6952bab3ed1b3cc3b7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.3.1 CPython/3.10.8 Windows/10
|
Release files / peinjecter-1.0.0-py3-none-any.whl
| Download URL | peinjecter-1.0.0-py3-none-any.whl |
|---|---|
| Size | 9.1 MB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
997f56ed845302bd6cb9d2b6a5ecb9d2d99d2636b4291107b924b284d5769ac5
|
|
BLAKE2b-256 checksum How to use checksums |
177011241836c92353b1a3f2a962a9472e548dac2f2c72947e632991275ec74c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.3.1 CPython/3.10.8 Windows/10
|
Security for peinjecter 1.0.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.