Module pywraps :: Class IDP_Hooks
[frames] | no frames]

Class IDP_Hooks

object --+
         |
        IDP_Hooks

Instance Methods
 
custom_ana(self)
Analyzes and decodes an instruction at idaapi.cmd.ea
 
custom_out(self)
Outputs the instruction defined in idaapi.cmd
 
custom_emu(self)
Emulate instruction, create cross-references, plan to analyze subsequent instructions, modify flags etc.
 
custom_outop(self, op)
Notification to generate operand text.
 
custom_mnem(self)
Prints the mnemonic of the instruction defined in idaapi.cmd
 
is_sane_insn(self, no_crefs)
can a function start here?

Inherited from object: __delattr__, __getattribute__, __hash__, __init__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __str__

Properties

Inherited from object: __class__

Method Details

custom_ana(self)

 

Analyzes and decodes an instruction at idaapi.cmd.ea

  • cmd.itype must be set >= idaapi.CUSTOM_CMD_ITYPE
  • cmd.size must be set to the instruction length
Returns:
Boolean
  • False if the instruction is not recognized
  • True if the instruction was decoded. idaapi.cmd should be filled in that case.

custom_out(self)

 

Outputs the instruction defined in idaapi.cmd

Returns:
Boolean (whether this instruction can be outputted or not)

custom_emu(self)

 

Emulate instruction, create cross-references, plan to analyze subsequent instructions, modify flags etc. Upon entrance to this function all information about the instruction is in 'cmd' structure.

Returns:
Boolean (whether this instruction has been emulated or not)

custom_outop(self, op)

 

Notification to generate operand text. If False was returned, then the standard operand output function will be called. The output buffer is inited with init_output_buffer() and this notification may use out_...() functions to form the operand text

Returns:
Boolean (whether the operand has been outputted or not)

custom_mnem(self)

 

Prints the mnemonic of the instruction defined in idaapi.cmd

Returns:
  • None: No mnemonic. IDA will use the default mnemonic value if present
  • String: The desired mnemonic string

is_sane_insn(self, no_crefs)

 

can a function start here?

Parameters:
  • state - autoanalysis phase 0: creating functions 1: creating chunks
Returns:
integer (probability 0..100)