Available on crate feature
ptrace
only.Expand description
Provides helpers for making ptrace system calls
Modules§
Structs§
- Options
- Ptrace options used in conjunction with the PTRACE_SETOPTIONS request.
See
man ptrace
for more details.
Enums§
- Event
- Using the ptrace options the tracer can configure the tracee to stop
at certain events. This enum is used to define those events as defined
in
man ptrace
. - Register
SetValue - Defines a specific register set, as used in
PTRACE_GETREGSET
andPTRACE_SETREGSET
. - Request
- Ptrace Request enum defining the action to be taken.
Traits§
- Register
Set - Represents register set areas, such as general-purpose registers or floating-point registers.
Functions§
- attach
- Attach to a running process, as with
ptrace(PTRACE_ATTACH, ...)
- cont
- Restart the stopped tracee process, as with
ptrace(PTRACE_CONT, ...)
- detach
- Detaches the current running process, as with
ptrace(PTRACE_DETACH, ...)
- getevent
- Gets a ptrace event as described by
ptrace(PTRACE_GETEVENTMSG, ...)
- getregs
- Get user registers, as with
ptrace(PTRACE_GETREGS, ...)
- getregset
- Get a particular set of user registers, as with
ptrace(PTRACE_GETREGSET, ...)
- getsiginfo
- Get siginfo as with
ptrace(PTRACE_GETSIGINFO, ...)
- interrupt
- Stop a tracee, as with
ptrace(PTRACE_INTERRUPT, ...)
- kill
- Issues a kill request as with
ptrace(PTRACE_KILL, ...)
- read
- Reads a word from a processes memory at the given address, as with ptrace(PTRACE_PEEKDATA, …)
- read_
user - Reads a word from a user area at
offset
, as with ptrace(PTRACE_PEEKUSER, …). The user struct definition can be found in/usr/include/sys/user.h
. - seize
- Attach to a running process, as with
ptrace(PTRACE_SEIZE, ...)
- setoptions
- Set options, as with
ptrace(PTRACE_SETOPTIONS, ...)
. - setregs
- Set user registers, as with
ptrace(PTRACE_SETREGS, ...)
- setregset
- Set a particular set of user registers, as with
ptrace(PTRACE_SETREGSET, ...)
- setsiginfo
- Set siginfo as with
ptrace(PTRACE_SETSIGINFO, ...)
- step
- Move the stopped tracee process forward by a single step as with
ptrace(PTRACE_SINGLESTEP, ...)
- syscall
- Continue execution until the next syscall, as with
ptrace(PTRACE_SYSCALL, ...)
- syscall_
info - Get the informations of the syscall that caused the stop, as with
ptrace(PTRACE_GET_SYSCALL_INFO, ...
. - sysemu
- Continue execution until the next syscall, as with
ptrace(PTRACE_SYSEMU, ...)
- sysemu_
step - Move the stopped tracee process forward by a single step or stop at the next syscall
as with
ptrace(PTRACE_SYSEMU_SINGLESTEP, ...)
- traceme
- Sets the process as traceable, as with
ptrace(PTRACE_TRACEME, ...)
- write
- Writes a word into the processes memory at the given address, as with ptrace(PTRACE_POKEDATA, …)
- write_
user - Writes a word to a user area at
offset
, as with ptrace(PTRACE_POKEUSER, …). The user struct definition can be found in/usr/include/sys/user.h
.