Skip to main content

GitHub license Build status codecov Discord Documentation Status

Pymem

A python library to manipulate Windows processes (32 and 64 bits).
With pymem you can hack into windows process and manipulate memory (read / write).

Documentation

You can find pymem documentation on readthedoc there: http://pymem.readthedocs.io/

Discord Support

For questions and support, join us on discord https://discord.gg/xaWNac8

Examples

You can find more examples from the community in the Examples from the community of pymem documentation.

Listing process modules

import pymem

pm = pymem.Pymem('python.exe')
modules = list(pm.list_modules())
for module in modules:
    print(module.name)

Injecting a python interpreter into any process

from pymem import Pymem

notepad = subprocess.Popen(['notepad.exe'])

pm = pymem.Pymem('notepad.exe')
pm.inject_python_interpreter()
filepath = os.path.join(os.path.abspath('.'), 'pymem_injection.txt')
filepath = filepath.replace("\\", "\\\\")
shellcode = """
f = open("{}", "w+")
f.write("pymem_injection")
f.close()
""".format(filepath)
pm.inject_python_shellcode(shellcode)
notepad.kill()

Metadata

Release files for Pymem 1.11.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for Pymem 1.11.0
File Size Uploaded Provenance Actions
Pymem-1.11.0.tar.gz 23.9 kB Without provenance Details for Pymem-1.11.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for Pymem 1.11.0
File Interpreter ABI Platform Actions
Pymem-1.11.0-py3-none-any.whl Python 3 none any Details for Pymem-1.11.0-py3-none-any.whl

Total release size: 52.6 kB

Release files / Pymem-1.11.0.tar.gz

Download URL Pymem-1.11.0.tar.gz
Size 23.9 kB
Tags Source
SHA-256 checksum
How to use checksums
bfaf3562bfdee8dc79b4fe90654d12fe29af84c4f1483fd009c09230d6aafaa2
BLAKE2b-256 checksum
How to use checksums
aea7c05732b9e5bc2ebc5e390a8a32527d63b46010e25877ca960d6218edbd44
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.8.0 pkginfo/1.9.6 readme-renderer/34.0 requests/2.27.1 requests-toolbelt/0.10.1 urllib3/1.26.15 tqdm/4.64.1 importlib-metadata/4.8.3 keyring/23.4.1 rfc3986/1.5.0 colorama/0.4.5 CPython/3.6.8

Release files / Pymem-1.11.0-py3-none-any.whl

Download URL Pymem-1.11.0-py3-none-any.whl
Size 28.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
d75fa1b4d066f8895dd6728f98fad99d5ca43481260bdf1f449ada752b94c662
BLAKE2b-256 checksum
How to use checksums
2c9c1adb3e470e3a324acf5d78446c1a21cca2c62c46f888079ac1594e6fa91f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.8.0 pkginfo/1.9.6 readme-renderer/34.0 requests/2.27.1 requests-toolbelt/0.10.1 urllib3/1.26.15 tqdm/4.64.1 importlib-metadata/4.8.3 keyring/23.4.1 rfc3986/1.5.0 colorama/0.4.5 CPython/3.6.8

Security for Pymem 1.11.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.

Release history Release notifications | RSS feed

This release

1.11.0 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page