示例#1
0
def main(argv=None):
    if argv is None:
        argv = sys.argv[1:]

    parser = argparse.ArgumentParser(
        description=
        "Parse and display type information from an IDA Pro database.")
    parser.add_argument("idb",
                        type=argparse.FileType("rb"),
                        help="Path to input idb file")
    args = parser.parse_args(args=argv)

    til = idb.from_buffer(args.idb.read()).til
    # for _def in til.syms.defs:
    #     print(_def.type.get_typestr())
    for _def in til.types.defs:
        print(_def.type.get_typestr())
    return 0
示例#2
0
def load_idb(path):
    with open(path, 'rb') as f:
        return idb.from_buffer(f.read())
示例#3
0
 def get_db(self, current_idb):
     h_idb = open(current_idb, "rb")
     idb_data = h_idb.read()
     h_idb.close()
     return idb.from_buffer(idb_data)
示例#4
0
文件: vbin.py 项目: Rafiot/viper
 def get_db(self, current_idb):
     h_idb = open(current_idb, "rb")
     idb_data = h_idb.read()
     h_idb.close()
     return idb.from_buffer(idb_data)