Skip to content

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

get ¤

get(instruction: PwndbgInstruction) -> list[tuple[Argument, int]]

Returns an array containing the arguments to the current function, if $pc is a 'call', 'bl', or 'jalr' type instruction.

Otherwise, returns None.

argname ¤

argname(n: int, abi: ABI | None = None) -> str

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.

arguments ¤

arguments(abi: ABI | None = None)

Yields (arg_name, arg_value) tuples for arguments from a given ABI. Works only for ABIs that use registers for arguments.

format_args ¤

format_args(instruction: PwndbgInstruction) -> list[str]