How To Install python3-ptrace on Fedora 36

In this tutorial we learn how to install python3-ptrace in Fedora 36. python3-ptrace is Debugger using ptrace written in Python 3

Introduction

In this tutorial we learn how to install python3-ptrace on Fedora 36.

What is python3-ptrace

python-ptrace is a debugger using ptrace written in Python. Features o High level Python object API o Able to control multiple processes o Read/write bytes to arbitrary address and split bytes to cpu word o Execution step by step using ptrace_singlestep() or hardware interruption 3 o Dump registers, memory mappings, stack, etc. o Syscall tracer and parser (strace.py command) o Can use distorm disassembler (if available)

We can use yum or dnf to install python3-ptrace on Fedora 36. In this tutorial we discuss both methods but you only need to choose one of method to install python3-ptrace.

Install python3-ptrace on Fedora 36 Using dnf

Update yum database with dnf using the following command.

sudo dnf makecache --refresh

After updating yum database, We can install python3-ptrace using dnf by running the following command:

sudo dnf -y install python3-ptrace

Install python3-ptrace on Fedora 36 Using yum

Update yum database with yum using the following command.

sudo yum makecache --refresh

After updating yum database, We can install python3-ptrace using yum by running the following command:

sudo yum -y install python3-ptrace

How To Uninstall python3-ptrace on Fedora 36

To uninstall only the python3-ptrace package we can use the following command:

sudo dnf remove python3-ptrace

python3-ptrace Package Contents on Fedora 36

/usr/bin/gdb.py
/usr/bin/strace.py
/usr/lib/.build-id
/usr/lib/.build-id/7b
/usr/lib/.build-id/7b/9effc744471cfab4e2ebeee2b30187d2bdab0a
/usr/lib/python3.10/site-packages/ptrace
/usr/lib/python3.10/site-packages/ptrace/__init__.py
/usr/lib/python3.10/site-packages/ptrace/__pycache__
/usr/lib/python3.10/site-packages/ptrace/__pycache__/__init__.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/__init__.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/cpu_info.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/cpu_info.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/ctypes_libc.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/ctypes_libc.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/ctypes_tools.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/ctypes_tools.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/disasm.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/disasm.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/error.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/error.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/func_arg.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/func_arg.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/func_call.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/func_call.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/linux_proc.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/linux_proc.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/logging_tools.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/logging_tools.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/mockup.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/mockup.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/os_tools.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/os_tools.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/process_tools.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/process_tools.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/profiler.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/profiler.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/pydistorm.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/pydistorm.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/signames.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/signames.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/terminal.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/terminal.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/tools.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/tools.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/version.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/__pycache__/version.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/binding
/usr/lib/python3.10/site-packages/ptrace/binding/__init__.py
/usr/lib/python3.10/site-packages/ptrace/binding/__pycache__
/usr/lib/python3.10/site-packages/ptrace/binding/__pycache__/__init__.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/binding/__pycache__/__init__.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/binding/__pycache__/cpu.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/binding/__pycache__/cpu.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/binding/__pycache__/freebsd_struct.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/binding/__pycache__/freebsd_struct.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/binding/__pycache__/func.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/binding/__pycache__/func.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/binding/__pycache__/linux_struct.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/binding/__pycache__/linux_struct.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/binding/__pycache__/openbsd_struct.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/binding/__pycache__/openbsd_struct.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/binding/cpu.py
/usr/lib/python3.10/site-packages/ptrace/binding/freebsd_struct.py
/usr/lib/python3.10/site-packages/ptrace/binding/func.py
/usr/lib/python3.10/site-packages/ptrace/binding/linux_struct.py
/usr/lib/python3.10/site-packages/ptrace/binding/openbsd_struct.py
/usr/lib/python3.10/site-packages/ptrace/cpu_info.py
/usr/lib/python3.10/site-packages/ptrace/ctypes_libc.py
/usr/lib/python3.10/site-packages/ptrace/ctypes_tools.py
/usr/lib/python3.10/site-packages/ptrace/debugger
/usr/lib/python3.10/site-packages/ptrace/debugger/__init__.py
/usr/lib/python3.10/site-packages/ptrace/debugger/__pycache__
/usr/lib/python3.10/site-packages/ptrace/debugger/__pycache__/__init__.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/debugger/__pycache__/__init__.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/debugger/__pycache__/application.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/debugger/__pycache__/application.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/debugger/__pycache__/backtrace.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/debugger/__pycache__/backtrace.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/debugger/__pycache__/breakpoint.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/debugger/__pycache__/breakpoint.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/debugger/__pycache__/child.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/debugger/__pycache__/child.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/debugger/__pycache__/debugger.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/debugger/__pycache__/debugger.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/debugger/__pycache__/memory_mapping.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/debugger/__pycache__/memory_mapping.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/debugger/__pycache__/parse_expr.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/debugger/__pycache__/parse_expr.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/debugger/__pycache__/process.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/debugger/__pycache__/process.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/debugger/__pycache__/process_error.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/debugger/__pycache__/process_error.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/debugger/__pycache__/process_event.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/debugger/__pycache__/process_event.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/debugger/__pycache__/ptrace_signal.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/debugger/__pycache__/ptrace_signal.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/debugger/__pycache__/signal_reason.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/debugger/__pycache__/signal_reason.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/debugger/__pycache__/syscall_state.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/debugger/__pycache__/syscall_state.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/debugger/application.py
/usr/lib/python3.10/site-packages/ptrace/debugger/backtrace.py
/usr/lib/python3.10/site-packages/ptrace/debugger/breakpoint.py
/usr/lib/python3.10/site-packages/ptrace/debugger/child.py
/usr/lib/python3.10/site-packages/ptrace/debugger/debugger.py
/usr/lib/python3.10/site-packages/ptrace/debugger/memory_mapping.py
/usr/lib/python3.10/site-packages/ptrace/debugger/parse_expr.py
/usr/lib/python3.10/site-packages/ptrace/debugger/process.py
/usr/lib/python3.10/site-packages/ptrace/debugger/process_error.py
/usr/lib/python3.10/site-packages/ptrace/debugger/process_event.py
/usr/lib/python3.10/site-packages/ptrace/debugger/ptrace_signal.py
/usr/lib/python3.10/site-packages/ptrace/debugger/signal_reason.py
/usr/lib/python3.10/site-packages/ptrace/debugger/syscall_state.py
/usr/lib/python3.10/site-packages/ptrace/disasm.py
/usr/lib/python3.10/site-packages/ptrace/error.py
/usr/lib/python3.10/site-packages/ptrace/func_arg.py
/usr/lib/python3.10/site-packages/ptrace/func_call.py
/usr/lib/python3.10/site-packages/ptrace/linux_proc.py
/usr/lib/python3.10/site-packages/ptrace/logging_tools.py
/usr/lib/python3.10/site-packages/ptrace/mockup.py
/usr/lib/python3.10/site-packages/ptrace/os_tools.py
/usr/lib/python3.10/site-packages/ptrace/process_tools.py
/usr/lib/python3.10/site-packages/ptrace/profiler.py
/usr/lib/python3.10/site-packages/ptrace/pydistorm.py
/usr/lib/python3.10/site-packages/ptrace/signames.py
/usr/lib/python3.10/site-packages/ptrace/syscall
/usr/lib/python3.10/site-packages/ptrace/syscall/__init__.py
/usr/lib/python3.10/site-packages/ptrace/syscall/__pycache__
/usr/lib/python3.10/site-packages/ptrace/syscall/__pycache__/__init__.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/__pycache__/__init__.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/__pycache__/freebsd_constants.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/__pycache__/freebsd_constants.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/__pycache__/freebsd_syscall.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/__pycache__/freebsd_syscall.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/__pycache__/linux_constants.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/__pycache__/linux_constants.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/__pycache__/linux_struct.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/__pycache__/linux_struct.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/__pycache__/names.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/__pycache__/names.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/__pycache__/posix_arg.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/__pycache__/posix_arg.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/__pycache__/posix_constants.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/__pycache__/posix_constants.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/__pycache__/prototypes.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/__pycache__/prototypes.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/__pycache__/ptrace_syscall.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/__pycache__/ptrace_syscall.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/__pycache__/socketcall.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/__pycache__/socketcall.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/__pycache__/socketcall_constants.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/__pycache__/socketcall_constants.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/__pycache__/socketcall_struct.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/__pycache__/socketcall_struct.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/__pycache__/syscall_argument.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/__pycache__/syscall_argument.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/freebsd_constants.py
/usr/lib/python3.10/site-packages/ptrace/syscall/freebsd_syscall.py
/usr/lib/python3.10/site-packages/ptrace/syscall/linux
/usr/lib/python3.10/site-packages/ptrace/syscall/linux/__init__.py
/usr/lib/python3.10/site-packages/ptrace/syscall/linux/__pycache__
/usr/lib/python3.10/site-packages/ptrace/syscall/linux/__pycache__/__init__.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/linux/__pycache__/__init__.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/linux/__pycache__/aarch64.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/linux/__pycache__/aarch64.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/linux/__pycache__/i386.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/linux/__pycache__/i386.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/linux/__pycache__/powerpc32.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/linux/__pycache__/powerpc32.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/linux/__pycache__/powerpc64.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/linux/__pycache__/powerpc64.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/linux/__pycache__/x86_64.cpython-310.opt-1.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/linux/__pycache__/x86_64.cpython-310.pyc
/usr/lib/python3.10/site-packages/ptrace/syscall/linux/aarch64.py
/usr/lib/python3.10/site-packages/ptrace/syscall/linux/i386.py
/usr/lib/python3.10/site-packages/ptrace/syscall/linux/powerpc32.py
/usr/lib/python3.10/site-packages/ptrace/syscall/linux/powerpc64.py
/usr/lib/python3.10/site-packages/ptrace/syscall/linux/x86_64.py
/usr/lib/python3.10/site-packages/ptrace/syscall/linux_constants.py
/usr/lib/python3.10/site-packages/ptrace/syscall/linux_struct.py
/usr/lib/python3.10/site-packages/ptrace/syscall/names.py
/usr/lib/python3.10/site-packages/ptrace/syscall/posix_arg.py
/usr/lib/python3.10/site-packages/ptrace/syscall/posix_constants.py
/usr/lib/python3.10/site-packages/ptrace/syscall/prototypes.py
/usr/lib/python3.10/site-packages/ptrace/syscall/ptrace_syscall.py
/usr/lib/python3.10/site-packages/ptrace/syscall/socketcall.py
/usr/lib/python3.10/site-packages/ptrace/syscall/socketcall_constants.py
/usr/lib/python3.10/site-packages/ptrace/syscall/socketcall_struct.py
/usr/lib/python3.10/site-packages/ptrace/syscall/syscall_argument.py
/usr/lib/python3.10/site-packages/ptrace/terminal.py
/usr/lib/python3.10/site-packages/ptrace/tools.py
/usr/lib/python3.10/site-packages/ptrace/version.py
/usr/lib/python3.10/site-packages/python_ptrace-0.9.8-py3.10.egg-info
/usr/lib/python3.10/site-packages/python_ptrace-0.9.8-py3.10.egg-info/PKG-INFO
/usr/lib/python3.10/site-packages/python_ptrace-0.9.8-py3.10.egg-info/SOURCES.txt
/usr/lib/python3.10/site-packages/python_ptrace-0.9.8-py3.10.egg-info/dependency_links.txt
/usr/lib/python3.10/site-packages/python_ptrace-0.9.8-py3.10.egg-info/top_level.txt
/usr/lib64/python3.10/site-packages/cptrace-0.6.1-py3.10.egg-info
/usr/lib64/python3.10/site-packages/cptrace.cpython-310-x86_64-linux-gnu.so
/usr/share/doc/python3-ptrace
/usr/share/doc/python3-ptrace/Makefile
/usr/share/doc/python3-ptrace/README.rst
/usr/share/doc/python3-ptrace/authors.rst
/usr/share/doc/python3-ptrace/changelog.rst
/usr/share/doc/python3-ptrace/conf.py
/usr/share/doc/python3-ptrace/cptrace.rst
/usr/share/doc/python3-ptrace/examples
/usr/share/doc/python3-ptrace/examples/itrace.py
/usr/share/doc/python3-ptrace/examples/simple_dbg.py
/usr/share/doc/python3-ptrace/gdb.rst
/usr/share/doc/python3-ptrace/index.rst
/usr/share/doc/python3-ptrace/install.rst
/usr/share/doc/python3-ptrace/make.bat
/usr/share/doc/python3-ptrace/process_events.rst
/usr/share/doc/python3-ptrace/ptrace_signal.rst
/usr/share/doc/python3-ptrace/syscall.rst
/usr/share/doc/python3-ptrace/todo.rst
/usr/share/doc/python3-ptrace/usage.rst
/usr/share/licenses/python3-ptrace
/usr/share/licenses/python3-ptrace/COPYING

References

Summary

In this tutorial we learn how to install python3-ptrace on Fedora 36 using yum and [dnf]((/fedora/36/dnf/).