首页 文章

如何实现IDA GenFuncGdl?

提问于
浏览
0

如何完成GenFuncGdl?我的意思是,用什么idc函数来完成GenFuncGdl?我查了idc.py,关于这个函数:

def GenFuncGdl(outfile, title, ea1, ea2, flags):
"""
Generate a flow chart GDL file

@param outfile: output file name. GDL extension will be used
@param title: graph title
@param ea1: beginning of the area to flow chart
@param ea2: end of the area to flow chart.
@param flags: combination of CHART_... constants

@note: If ea2 == BADADDR then ea1 is treated as an address within a function.
       That function will be flow charted.
"""
return idaapi.gen_flow_graph(outfile, title, None, ea1, ea2, flags)

从那里,我们只知道只需调用idaapi.gen_flow_graph .

实际上,我需要反转一个函数流,因为这个函数中有很多分支,我不知道如何识别分支块 . 只检查跳转指令,也许?

1 回答

  • 0

    如您所见, idaapi.gen_flow_graph 将只调用本机c IDA函数 .

    您的问题并不清楚您要完全实现的目标(在GDL文件中查找块?)

    如果你只想找到一个函数块,那么你可以使用idautils.Chunks()函数返回一个python生成器,它包含函数中所有块的起始和结束地址 .

相关问题