Expand description
A Rust library for dynamic kernel probing (kprobes and kretprobes). ! This library provides a safe and ergonomic interface for registering and managing kprobes and kretprobes in a kernel environment. ! It supports multiple architectures, including x86_64, riscv64, and loongarch64. ! # Features
- Register and unregister kprobes and kretprobes.
- Support for pre-handler and post-handler functions.
- Safe management of probe points and handlers.
- Architecture-specific implementations for handling breakpoints and single-stepping.
Structs§
- Kprobe
- The x86_64 implementation of Kprobe.
- Kprobe
Basic - The basic information of a kprobe.
- Kprobe
Builder - The builder for creating a kprobe.
- Kprobe
Manager - A manager for kprobes.
- Kretprobe
- The kretprobe structure.
- Kretprobe
Builder - The builder for creating a kretprobe.
- Kretprobe
Instance - The instance of a kretprobe.
- PtRegs
- The CPU register state for x86_64 architecture.
- X86Kprobe
Point - The probe point for x86_64 architecture.
Enums§
- Probe
- An enum representing either a kprobe or a kretprobe.
Traits§
- Call
Back Func - The callback function type for events.
- Kprobe
Auxiliary Ops - The auxiliary operations required for kprobes.
- Kprobe
Ops - The operations available for kprobes.
- Probe
Data - The user data associated with a probe point.
Functions§
- kprobe_
handler_ from_ break - Run kprobe which has been registered on the address
- kprobe_
handler_ from_ debug - Run kprobe which has been registered on the address
- register_
kprobe - Register a kprobe.
- register_
kretprobe - Register a kretprobe.
- unregister_
kprobe - Unregister a kprobe.
- unregister_
kretprobe - Unregister a kretprobe.
Type Aliases§
- Kprobe
Point - The probe point structure for the current architecture.
- Kprobe
Point List - A list of kprobe points.
- Probe
Handler Func - The type of the probe handler function.