inp_ida.py 文件源码

python
阅读 24 收藏 0 点赞 0 评论 0

项目:ropf 作者: kevinkoo001 项目源码 文件源码
def dump_data():
    """Extracts and dumps useful data from the file being processed.
    The output is written using pickle and it consists of a set with all the
    code heads followed by func.Function objects (ended with a None)."""

    def __dump(out, type, lb=0, ub=0):
        if type == 'code_head':
            cPickle.dump(get_code_heads(), out, cPickle.HIGHEST_PROTOCOL)
            for f in functions_iter():
                cPickle.dump(f, out, cPickle.HIGHEST_PROTOCOL)
        if type == 'code_blk':
            for bc in _get_blocks_codes_per_func_iter():
                cPickle.dump(bc, out, cPickle.HIGHEST_PROTOCOL)
        cPickle.dump(None, out)
        out.close()

    __dump(util.open_dump(idaapi.get_input_file_path(), 'wb', 'dmp'), 'code_head')
    __dump(util.open_dump(idaapi.get_input_file_path(), 'wb', 'code_blk'), 'code_blk')
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号