Ida pro gragh output batch mode

前端 未结 2 1193
别跟我提以往
别跟我提以往 2020-12-21 23:06

Can anyone let me know how we are going to output all the subroutine\'s graphs in batch mode suing IDC. i.e. I have 447 subroutine\'s and wanna be output them a

2条回答
  •  一个人的身影
    2020-12-22 00:00

    I needed a CFG of my whole program,the base example I started from was: https://code.google.com/p/idapython/source/browse/trunk/examples/ex_gdl_qflow_chart.py

    It uses the flow chart class: https://www.hex-rays.com/products/ida/support/idapython_docs/idaapi.FlowChart-class.html

    also worth noting to trigger in batch mode, you'll want something like this

    idal64 -A -S{yourscriptname}.py {yourbinary}

    Tips:

    • Prototype the script in the IDAPro gui first
    • Opening of the graph processor can cause timing issues, its hacky, but something like delaying execution of the script seemed to help, e.g.

      idaapi.autoWait() Timer(2, idacfg).start()

      where idacfg is your python function from the example

    • print to stdout doesn't seem to work in batch mode, so you'll want to set stdout to a file for your debugging.

    • Closing the GUI in batch mode is still an issue for me.

    Hope that helps.

提交回复
热议问题