MemEdit
MemEdit is a high-performance Python library for Windows memory manipulation, built with a C++20 core and pybind11. It is designed for speed, efficiency, and ease of use, making it ideal for memory scanning and editing tasks.
Features
- C++20 Core: Leverages modern C++ features for maximum performance.
- Multi-threaded Scanning: Uses
std::asyncand parallel processing to scan large memory blocks (GBs) in seconds. - SIMD-Ready: Designed for efficient buffer comparisons.
- AOB Scanning: Supports "Array of Bytes" searching with wildcards (e.g.,
48 8B ?? 05 ?? ?? ?? ??). - Pythonic Interface: Clean and easy-to-use Python bindings.
- GIL Management: Releases the Global Interpreter Lock (GIL) during heavy scanning operations to prevent UI freezing.
- RAII Memory Management: Safely handles process handles using modern C++ practices.
Requirements
- Windows OS
- Python 3.7+
- C++20 compatible compiler (MSVC recommended)
pybind11
Installation
To compile and install MemEdit, run the following command in the project root:
pip install .
Or for development:
python setup.py build_ext --inplace
Usage
Basic Scanning
import MemEdit
# Attach to a process by PID
pid = 1234
scanner = MemEdit.Scanner(pid)
if scanner.is_valid():
# Perform a first scan for an int32 value
results = scanner.first_scan_int32(100)
print(f"Found {len(results)} addresses.")
# Filter results with a next scan
results = scanner.next_scan_int32(200)
print(f"Filtered to {len(results)} addresses.")
# Write to memory
if results:
scanner.write_int32(results[0], 9999)
AOB Scanning
# Scan for a pattern with wildcards
pattern = "48 8B ?? 05 ?? ?? ?? ??"
results = scanner.aob_scan(pattern)
for addr in results:
print(f"Pattern found at: {hex(addr)}")
Performance Optimization
MemEdit optimizes performance by:
- Filtering Regions: Only scans
MEM_COMMITand readable/writable regions (PAGE_READWRITE, etc.) usingVirtualQueryEx. - Parallel Execution: Distributes scanning tasks across multiple threads.
- Efficient I/O: Minimizes
ReadProcessMemorycalls by reading large chunks into buffers.
Error Handling
The library includes robust error handling for common issues:
- Access Denied: Returns an invalid scanner object if the process cannot be opened.
- Read/Write Failures: Throws Python exceptions or returns boolean status for memory operations.
License
MIT License
Metadata
Release files for MemEdit-G3tFun 0.1.2
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 |
|---|---|---|---|---|
| memedit_g3tfun-0.1.2.tar.gz | 5.0 kB | Without provenance | Details for memedit_g3tfun-0.1.2.tar.gz |
Release files / memedit_g3tfun-0.1.2.tar.gz
| Download URL | memedit_g3tfun-0.1.2.tar.gz |
|---|---|
| Size | 5.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
8917c5fbfb2736c5b607c366223bbba7ef338a5548533a245fdb59fbc020f44c
|
|
BLAKE2b-256 checksum How to use checksums |
58436c7226fed7baad89822428ca335bbf8b8c0db6e718528e61d521bb1c0299
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.0rc1
|
Security for MemEdit-G3tFun 0.1.2
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.