2

Simple question that I coudn't find googling: if I'm in the middle of a function how can I jump to the start/end (prologue/epilogue) of this function in IDA's disassembly?

Thanks.

1 Answer 1

6

I don't believe there is a hotkey that will do it by default. One solution you could have is to add something like this to your .idapythonrc

# define functions to do the jumping
def jump_func_start():
    Jump(GetFunctionAttr(here(), FUNCATTR_START))

def jump_func_end():
    Jump(PrevHead(GetFunctionAttr(here(), FUNCATTR_END)))

# Compile IDC wrappers to call the python
idaapi.CompileLine('static j_f_start() { RunPythonStatement("jump_func_start()"); }')
idaapi.CompileLine('static j_f_end() { RunPythonStatement("jump_func_end()"); }')

# Add the hotkey
AddHotkey("Ctrl-Alt-K", 'j_f_start')
AddHotkey("Ctrl-Alt-J", 'j_f_end')

After that you can just type whatever hotkey you set and it should go to the start / end of the function

3
  • Hum that's odd. IDA is such a powerful tool but it kinda seems to have a lot of missing nice simple features. Other example of such is the sintax highlight, it doesn't even have the possibility of change the color of specific instructions. Sometimes I find myself wanting to generate a .dbg of the IDB and go to the olly/x64dbg to do static analysis due to the lack of these features. Thanks anyway :) Dec 24, 2017 at 10:08
  • Not sure about changing the syntax colors from the default. I know some people use themes in IDA. If you just want to color the instruction, there's a ColorInstruction command (Edit | Other | Color instruction) you can set a hotkey for it by searching for ColorInstruction in the shortcuts menu (Options | Shortcuts). I commonly use that when reversing along with GraphColor / GraphDefaultColor to markup IDBs with paths taken
    – Bambu
    Dec 25, 2017 at 13:11
  • 1
    Ctrl-P, Enter works for start.
    – Igor Skochinsky
    Dec 25, 2017 at 20:14

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.