arguments ¤
Allows describing functions, specifically enumerating arguments which may be passed in a combination of registers and stack values.
Functions:
-
get
–Returns an array containing the arguments to the current function,
-
argname
– -
argument
–Returns the nth argument, as if $pc were a 'call' or 'bl' type
-
arguments
–Yields (arg_name, arg_value) tuples for arguments from a given ABI.
-
format_args
–
Attributes:
FILE_DESCRIPTOR_ARG_NAMES module-attribute
¤
FILE_DESCRIPTOR_ARG_NAMES = {
"fd",
"in_fd",
"out_fd",
"fdin",
"fdout",
"oldfd",
"fildes",
"newfd",
"epfd",
"dfd",
"dirfd",
"mountdirfd",
}
get ¤
get(instruction: PwndbgInstruction) -> list[tuple[Argument, int]]
Returns an array containing the arguments to the current function, if $pc is a function call or syscall instruction.
Otherwise, returns None.
argument ¤
argument(n: int, abi: ABI | None = None) -> int
Returns the nth argument, as if $pc were a 'call' or 'bl' type instruction. Works only for ABIs that use registers for arguments.