Skip to content

Pymem support for Linux #157

@DannyS124

Description

@DannyS124

Summary

I'd like to propose adding Linux support to pymem, leveraging the /proc file system to implement the same read/write functionality currently available on Windows.

This would allow Python-based memory editing on Linux games like AssaultCube, CS:GO, or native apps — in the same way pymem supports Windows processes.

Proposed Features for Linux

  • Attach to processes by name or PID using /proc
  • Read/write process memory via /proc/<pid>/mem
  • Parse memory regions using /proc/<pid>/maps
  • Basic value reading/writing (ints, floats, strings)
  • Resolve pointer chains (multi-level pointers)

Advanced (Future) Features

  • Memory scanner (exact value / range)
  • Memory patching
  • AOB (pattern) scanning
  • mprotect/ptrace memory protections
  • .so injection via LD_PRELOAD or ptrace

There is currently no widely-supported cross-platform Python memory editing library. Making pymem support Linux

The core structure could mirror Windows:

  • Linux process class using psutil
  • Memory access via direct file I/O
  • Utils for type conversions and pointer resolution

Would the core team be open to this?

Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions