arch ¤
Classes:
-
PwndbgArchitecture–This class defines the context of the currently debugged architecture as well as other related information of the platform.
-
AMD64Arch– -
i386Arch–32-bit mode x86
-
i8086Arch–16-bit mode x86
-
ArmArch– -
ArmCortexArch–Cortex-M processors run the M-profile Arm architecture.
-
AArch64Arch– -
PowerPCArch– -
SparcArch– -
RISCV32Arch– -
RISCV64Arch– -
MipsArch– -
Loongarch64Arch– -
S390xArch–
Functions:
Attributes:
-
EndianType– -
FMT_LITTLE_ENDIAN– -
FMT_BIG_ENDIAN– -
registered_architectures(dict[PWNDBG_SUPPORTED_ARCHITECTURES_TYPE, PwndbgArchitecture]) – -
all_arches–
registered_architectures module-attribute ¤
registered_architectures: dict[
PWNDBG_SUPPORTED_ARCHITECTURES_TYPE, PwndbgArchitecture
] = {}
all_arches module-attribute ¤
all_arches = [
AMD64Arch(),
i386Arch(),
i8086Arch(),
ArmArch(),
ArmCortexArch(),
AArch64Arch(),
PowerPCArch(),
SparcArch(),
RISCV32Arch(),
RISCV64Arch(),
MipsArch(),
Loongarch64Arch(),
S390xArch(),
]
PwndbgArchitecture ¤
PwndbgArchitecture(name: PWNDBG_SUPPORTED_ARCHITECTURES_TYPE)
Bases: ArchDefinition
This class defines the context of the currently debugged architecture as well as other related information of the platform.
This includes the following information: - Capstone/Unicorn constants - ABI information
Methods:
-
update–While debugging a process, certain aspects of the architecture can change.
-
pack– -
unpack– -
pack_size– -
unpack_size– -
get_capstone_constants–Return tuple of (CAPSTONE ARCH, CAPSTONE MODE) used to instantiate the Capstone disassembler for this architecture.
-
read_thumb_bit–Return 0 or 1, representing the status of the Thumb bit in the current Arm architecture
Attributes:
-
max_instruction_size(int) – -
instruction_alignment(int) – -
endian(EndianType) – -
ptrsize(int) –Pointer size in bytes
-
ptrbits(int) –Pointer size in bits
-
ptrmask(int) – -
function_abi(ABI | None) – -
syscall_abi(SyscallABI | None) – -
sigreturn_abi(SyscallABI | None) – -
platform(Platform) – -
attributes(list[ArchAttribute]) – -
fmts(dict[int, str]) – -
fmt(str) – -
name(PWNDBG_SUPPORTED_ARCHITECTURES_TYPE) –
update ¤
update(arch_definition: ArchDefinition) -> None
While debugging a process, certain aspects of the architecture can change.
For example: - Some architectures can change endianness dynamically.
get_capstone_constants ¤
Return tuple of (CAPSTONE ARCH, CAPSTONE MODE) used to instantiate the Capstone disassembler for this architecture.
read_thumb_bit ¤
Return 0 or 1, representing the status of the Thumb bit in the current Arm architecture
Return None if the Thumb bit is not relevent to the current architecture
AMD64Arch ¤
Bases: PwndbgArchitecture
Methods:
-
get_capstone_constants– -
update–While debugging a process, certain aspects of the architecture can change.
-
pack– -
unpack– -
pack_size– -
unpack_size– -
read_thumb_bit–Return 0 or 1, representing the status of the Thumb bit in the current Arm architecture
Attributes:
-
max_instruction_size– -
instruction_alignment– -
name(PWNDBG_SUPPORTED_ARCHITECTURES_TYPE) – -
ptrsize(int) –Pointer size in bytes
-
endian(EndianType) – -
platform(Platform) – -
attributes(list[ArchAttribute]) – -
ptrbits(int) –Pointer size in bits
-
ptrmask(int) – -
function_abi(ABI | None) – -
syscall_abi(SyscallABI | None) – -
sigreturn_abi(SyscallABI | None) – -
fmts(dict[int, str]) – -
fmt(str) –
update ¤
update(arch_definition: ArchDefinition) -> None
While debugging a process, certain aspects of the architecture can change.
For example: - Some architectures can change endianness dynamically.
read_thumb_bit ¤
Return 0 or 1, representing the status of the Thumb bit in the current Arm architecture
Return None if the Thumb bit is not relevent to the current architecture
i386Arch ¤
Bases: PwndbgArchitecture
32-bit mode x86
Methods:
-
get_capstone_constants– -
update–While debugging a process, certain aspects of the architecture can change.
-
pack– -
unpack– -
pack_size– -
unpack_size– -
read_thumb_bit–Return 0 or 1, representing the status of the Thumb bit in the current Arm architecture
Attributes:
-
max_instruction_size– -
instruction_alignment– -
name(PWNDBG_SUPPORTED_ARCHITECTURES_TYPE) – -
ptrsize(int) –Pointer size in bytes
-
endian(EndianType) – -
platform(Platform) – -
attributes(list[ArchAttribute]) – -
ptrbits(int) –Pointer size in bits
-
ptrmask(int) – -
function_abi(ABI | None) – -
syscall_abi(SyscallABI | None) – -
sigreturn_abi(SyscallABI | None) – -
fmts(dict[int, str]) – -
fmt(str) –
update ¤
update(arch_definition: ArchDefinition) -> None
While debugging a process, certain aspects of the architecture can change.
For example: - Some architectures can change endianness dynamically.
read_thumb_bit ¤
Return 0 or 1, representing the status of the Thumb bit in the current Arm architecture
Return None if the Thumb bit is not relevent to the current architecture
i8086Arch ¤
Bases: PwndbgArchitecture
16-bit mode x86
Methods:
-
get_capstone_constants– -
update–While debugging a process, certain aspects of the architecture can change.
-
pack– -
unpack– -
pack_size– -
unpack_size– -
read_thumb_bit–Return 0 or 1, representing the status of the Thumb bit in the current Arm architecture
Attributes:
-
max_instruction_size– -
instruction_alignment– -
name(PWNDBG_SUPPORTED_ARCHITECTURES_TYPE) – -
ptrsize(int) –Pointer size in bytes
-
endian(EndianType) – -
platform(Platform) – -
attributes(list[ArchAttribute]) – -
ptrbits(int) –Pointer size in bits
-
ptrmask(int) – -
function_abi(ABI | None) – -
syscall_abi(SyscallABI | None) – -
sigreturn_abi(SyscallABI | None) – -
fmts(dict[int, str]) – -
fmt(str) –
update ¤
update(arch_definition: ArchDefinition) -> None
While debugging a process, certain aspects of the architecture can change.
For example: - Some architectures can change endianness dynamically.
read_thumb_bit ¤
Return 0 or 1, representing the status of the Thumb bit in the current Arm architecture
Return None if the Thumb bit is not relevent to the current architecture
ArmArch ¤
Bases: PwndbgArchitecture
Methods:
-
get_capstone_constants– -
read_thumb_bit– -
update–While debugging a process, certain aspects of the architecture can change.
-
pack– -
unpack– -
pack_size– -
unpack_size–
Attributes:
-
max_instruction_size– -
instruction_alignment– -
name(PWNDBG_SUPPORTED_ARCHITECTURES_TYPE) – -
ptrsize(int) –Pointer size in bytes
-
endian(EndianType) – -
platform(Platform) – -
attributes(list[ArchAttribute]) – -
ptrbits(int) –Pointer size in bits
-
ptrmask(int) – -
function_abi(ABI | None) – -
syscall_abi(SyscallABI | None) – -
sigreturn_abi(SyscallABI | None) – -
fmts(dict[int, str]) – -
fmt(str) –
update ¤
update(arch_definition: ArchDefinition) -> None
While debugging a process, certain aspects of the architecture can change.
For example: - Some architectures can change endianness dynamically.
ArmCortexArch ¤
Bases: PwndbgArchitecture
Cortex-M processors run the M-profile Arm architecture. This architecture is prevalent in bare-metal/embedded systems that lack operating systems. Only Thumb-2 instructions are supported, and the Thumb bit is always 1.
Methods:
-
get_capstone_constants– -
read_thumb_bit–On Cortex-M processors, the Thumb bit is architecturally defined to be 1.
-
update–While debugging a process, certain aspects of the architecture can change.
-
pack– -
unpack– -
pack_size– -
unpack_size–
Attributes:
-
max_instruction_size– -
instruction_alignment– -
name(PWNDBG_SUPPORTED_ARCHITECTURES_TYPE) – -
ptrsize(int) –Pointer size in bytes
-
endian(EndianType) – -
platform(Platform) – -
attributes(list[ArchAttribute]) – -
ptrbits(int) –Pointer size in bits
-
ptrmask(int) – -
function_abi(ABI | None) – -
syscall_abi(SyscallABI | None) – -
sigreturn_abi(SyscallABI | None) – -
fmts(dict[int, str]) – -
fmt(str) –
read_thumb_bit ¤
On Cortex-M processors, the Thumb bit is architecturally defined to be 1.
This is the (xpsr >> 24) & 1, which is always 1.
update ¤
update(arch_definition: ArchDefinition) -> None
While debugging a process, certain aspects of the architecture can change.
For example: - Some architectures can change endianness dynamically.
AArch64Arch ¤
Bases: PwndbgArchitecture
Methods:
-
get_capstone_constants– -
update–While debugging a process, certain aspects of the architecture can change.
-
pack– -
unpack– -
pack_size– -
unpack_size– -
read_thumb_bit–Return 0 or 1, representing the status of the Thumb bit in the current Arm architecture
Attributes:
-
max_instruction_size– -
instruction_alignment– -
name(PWNDBG_SUPPORTED_ARCHITECTURES_TYPE) – -
ptrsize(int) –Pointer size in bytes
-
endian(EndianType) – -
platform(Platform) – -
attributes(list[ArchAttribute]) – -
ptrbits(int) –Pointer size in bits
-
ptrmask(int) – -
function_abi(ABI | None) – -
syscall_abi(SyscallABI | None) – -
sigreturn_abi(SyscallABI | None) – -
fmts(dict[int, str]) – -
fmt(str) –
update ¤
update(arch_definition: ArchDefinition) -> None
While debugging a process, certain aspects of the architecture can change.
For example: - Some architectures can change endianness dynamically.
read_thumb_bit ¤
Return 0 or 1, representing the status of the Thumb bit in the current Arm architecture
Return None if the Thumb bit is not relevent to the current architecture
PowerPCArch ¤
Bases: PwndbgArchitecture
Methods:
-
get_capstone_constants– -
update–While debugging a process, certain aspects of the architecture can change.
-
pack– -
unpack– -
pack_size– -
unpack_size– -
read_thumb_bit–Return 0 or 1, representing the status of the Thumb bit in the current Arm architecture
Attributes:
-
max_instruction_size– -
instruction_alignment– -
name(PWNDBG_SUPPORTED_ARCHITECTURES_TYPE) – -
ptrsize(int) –Pointer size in bytes
-
endian(EndianType) – -
platform(Platform) – -
attributes(list[ArchAttribute]) – -
ptrbits(int) –Pointer size in bits
-
ptrmask(int) – -
function_abi(ABI | None) – -
syscall_abi(SyscallABI | None) – -
sigreturn_abi(SyscallABI | None) – -
fmts(dict[int, str]) – -
fmt(str) –
update ¤
update(arch_definition: ArchDefinition) -> None
While debugging a process, certain aspects of the architecture can change.
For example: - Some architectures can change endianness dynamically.
read_thumb_bit ¤
Return 0 or 1, representing the status of the Thumb bit in the current Arm architecture
Return None if the Thumb bit is not relevent to the current architecture
SparcArch ¤
Bases: PwndbgArchitecture
Methods:
-
get_capstone_constants– -
update–While debugging a process, certain aspects of the architecture can change.
-
pack– -
unpack– -
pack_size– -
unpack_size– -
read_thumb_bit–Return 0 or 1, representing the status of the Thumb bit in the current Arm architecture
Attributes:
-
max_instruction_size– -
instruction_alignment– -
name(PWNDBG_SUPPORTED_ARCHITECTURES_TYPE) – -
ptrsize(int) –Pointer size in bytes
-
endian(EndianType) – -
platform(Platform) – -
attributes(list[ArchAttribute]) – -
ptrbits(int) –Pointer size in bits
-
ptrmask(int) – -
function_abi(ABI | None) – -
syscall_abi(SyscallABI | None) – -
sigreturn_abi(SyscallABI | None) – -
fmts(dict[int, str]) – -
fmt(str) –
update ¤
update(arch_definition: ArchDefinition) -> None
While debugging a process, certain aspects of the architecture can change.
For example: - Some architectures can change endianness dynamically.
read_thumb_bit ¤
Return 0 or 1, representing the status of the Thumb bit in the current Arm architecture
Return None if the Thumb bit is not relevent to the current architecture
RISCV32Arch ¤
Bases: PwndbgArchitecture
Methods:
-
get_capstone_constants– -
update–While debugging a process, certain aspects of the architecture can change.
-
pack– -
unpack– -
pack_size– -
unpack_size– -
read_thumb_bit–Return 0 or 1, representing the status of the Thumb bit in the current Arm architecture
Attributes:
-
max_instruction_size– -
instruction_alignment– -
name(PWNDBG_SUPPORTED_ARCHITECTURES_TYPE) – -
ptrsize(int) –Pointer size in bytes
-
endian(EndianType) – -
platform(Platform) – -
attributes(list[ArchAttribute]) – -
ptrbits(int) –Pointer size in bits
-
ptrmask(int) – -
function_abi(ABI | None) – -
syscall_abi(SyscallABI | None) – -
sigreturn_abi(SyscallABI | None) – -
fmts(dict[int, str]) – -
fmt(str) –
update ¤
update(arch_definition: ArchDefinition) -> None
While debugging a process, certain aspects of the architecture can change.
For example: - Some architectures can change endianness dynamically.
read_thumb_bit ¤
Return 0 or 1, representing the status of the Thumb bit in the current Arm architecture
Return None if the Thumb bit is not relevent to the current architecture
RISCV64Arch ¤
Bases: PwndbgArchitecture
Methods:
-
get_capstone_constants– -
update–While debugging a process, certain aspects of the architecture can change.
-
pack– -
unpack– -
pack_size– -
unpack_size– -
read_thumb_bit–Return 0 or 1, representing the status of the Thumb bit in the current Arm architecture
Attributes:
-
max_instruction_size– -
instruction_alignment– -
name(PWNDBG_SUPPORTED_ARCHITECTURES_TYPE) – -
ptrsize(int) –Pointer size in bytes
-
endian(EndianType) – -
platform(Platform) – -
attributes(list[ArchAttribute]) – -
ptrbits(int) –Pointer size in bits
-
ptrmask(int) – -
function_abi(ABI | None) – -
syscall_abi(SyscallABI | None) – -
sigreturn_abi(SyscallABI | None) – -
fmts(dict[int, str]) – -
fmt(str) –
update ¤
update(arch_definition: ArchDefinition) -> None
While debugging a process, certain aspects of the architecture can change.
For example: - Some architectures can change endianness dynamically.
read_thumb_bit ¤
Return 0 or 1, representing the status of the Thumb bit in the current Arm architecture
Return None if the Thumb bit is not relevent to the current architecture
MipsArch ¤
Bases: PwndbgArchitecture
Methods:
-
get_capstone_constants– -
update–While debugging a process, certain aspects of the architecture can change.
-
pack– -
unpack– -
pack_size– -
unpack_size– -
read_thumb_bit–Return 0 or 1, representing the status of the Thumb bit in the current Arm architecture
Attributes:
-
max_instruction_size– -
instruction_alignment– -
name(PWNDBG_SUPPORTED_ARCHITECTURES_TYPE) – -
ptrsize(int) –Pointer size in bytes
-
endian(EndianType) – -
platform(Platform) – -
attributes(list[ArchAttribute]) – -
ptrbits(int) –Pointer size in bits
-
ptrmask(int) – -
function_abi(ABI | None) – -
syscall_abi(SyscallABI | None) – -
sigreturn_abi(SyscallABI | None) – -
fmts(dict[int, str]) – -
fmt(str) –
update ¤
update(arch_definition: ArchDefinition) -> None
While debugging a process, certain aspects of the architecture can change.
For example: - Some architectures can change endianness dynamically.
read_thumb_bit ¤
Return 0 or 1, representing the status of the Thumb bit in the current Arm architecture
Return None if the Thumb bit is not relevent to the current architecture
Loongarch64Arch ¤
Bases: PwndbgArchitecture
Methods:
-
get_capstone_constants– -
update–While debugging a process, certain aspects of the architecture can change.
-
pack– -
unpack– -
pack_size– -
unpack_size– -
read_thumb_bit–Return 0 or 1, representing the status of the Thumb bit in the current Arm architecture
Attributes:
-
max_instruction_size– -
instruction_alignment– -
name(PWNDBG_SUPPORTED_ARCHITECTURES_TYPE) – -
ptrsize(int) –Pointer size in bytes
-
endian(EndianType) – -
platform(Platform) – -
attributes(list[ArchAttribute]) – -
ptrbits(int) –Pointer size in bits
-
ptrmask(int) – -
function_abi(ABI | None) – -
syscall_abi(SyscallABI | None) – -
sigreturn_abi(SyscallABI | None) – -
fmts(dict[int, str]) – -
fmt(str) –
update ¤
update(arch_definition: ArchDefinition) -> None
While debugging a process, certain aspects of the architecture can change.
For example: - Some architectures can change endianness dynamically.
read_thumb_bit ¤
Return 0 or 1, representing the status of the Thumb bit in the current Arm architecture
Return None if the Thumb bit is not relevent to the current architecture
S390xArch ¤
Bases: PwndbgArchitecture
Methods:
-
get_capstone_constants– -
update–While debugging a process, certain aspects of the architecture can change.
-
pack– -
unpack– -
pack_size– -
unpack_size– -
read_thumb_bit–Return 0 or 1, representing the status of the Thumb bit in the current Arm architecture
Attributes:
-
max_instruction_size– -
instruction_alignment– -
name(PWNDBG_SUPPORTED_ARCHITECTURES_TYPE) – -
ptrsize(int) –Pointer size in bytes
-
endian(EndianType) – -
platform(Platform) – -
attributes(list[ArchAttribute]) – -
ptrbits(int) –Pointer size in bits
-
ptrmask(int) – -
function_abi(ABI | None) – -
syscall_abi(SyscallABI | None) – -
sigreturn_abi(SyscallABI | None) – -
fmts(dict[int, str]) – -
fmt(str) –
update ¤
update(arch_definition: ArchDefinition) -> None
While debugging a process, certain aspects of the architecture can change.
For example: - Some architectures can change endianness dynamically.
read_thumb_bit ¤
Return 0 or 1, representing the status of the Thumb bit in the current Arm architecture
Return None if the Thumb bit is not relevent to the current architecture
get_pwndbg_architecture ¤
get_pwndbg_architecture(
name: PWNDBG_SUPPORTED_ARCHITECTURES_TYPE,
) -> PwndbgArchitecture | None