toor-de-force / Ghidra-to-LLVM

An binary-to-LLVM IR lifter that leverages Ghidra's IR and analysis
MIT License
208 stars 19 forks source link

SOOO thanks if you can help me #5

Open Zddd97 opened 4 years ago

Zddd97 commented 4 years ago

Thank you for the tool, I encountered a problem while using it. I hope you can help me solve it, the error is as follows: INFO REPORT: Post-analysis succeeded for file: /home/zdd/Ghidra-to-LLVM-master/udhcpd (HeadlessAnalyzer)
INFO REPORT: Save succeeded for file: /udhcpd (HeadlessAnalyzer)
Traceback (most recent call last): File "g2llvm.py", line 42, in module = xmltollvm.lift(xmlfile) File "/home/zdd/Ghidra-to-LLVM-master/src/xmltollvm.py", line 70, in lift populate_func(ir_func, function) File "/home/zdd/Ghidra-to-LLVM-master/src/xmltollvm.py", line 79, in populate_func populate_cfg(function, builders, blocks) File "/home/zdd/Ghidra-to-LLVM-master/src/xmltollvm.py", line 110, in populate_cfg builder.store(stack_top, registers["RSP"]) KeyError: 'RSP' Then, if the imported binary file is too big, it will appear “ java out of memory” error,how can I solve this problem? thanks a lot!

h4sh5 commented 2 years ago

see https://github.com/toor-de-force/Ghidra-to-LLVM/issues/4, its the same issue (RSP is a 64 bit register, it should be ESP instead for 32 bit binaries)