Ghidra breaks when importing x86-16 target
See original GitHub issueDescribe the bug The provided target (shareware version of an old game) breaks Ghidra when importing with the following errors:
After just selecting the file to import: (NTHeader$$EnhancerByCGLIB$$5309bf04) Invalid NtHeader c50004
After selecting the language and format (using the defaults that Ghidra has detected):
java.lang.IllegalArgumentException: Block must contain split address
at ghidra.program.database.mem.MemoryMapDB.split(MemoryMapDB.java:785)
at ghidra.app.util.opinion.MzLoader.adjustSegmentStarts(MzLoader.java:220)
at ghidra.app.util.opinion.MzLoader.load(MzLoader.java:118)
at ghidra.app.util.opinion.AbstractLibrarySupportLoader.doLoad(AbstractLibrarySupportLoader.java:346)
at ghidra.app.util.opinion.AbstractLibrarySupportLoader.loadProgram(AbstractLibrarySupportLoader.java:83)
at ghidra.app.util.opinion.AbstractProgramLoader.load(AbstractProgramLoader.java:112)
at ghidra.plugin.importer.ImporterUtilities.importSingleFile(ImporterUtilities.java:401)
at ghidra.plugin.importer.ImporterDialog.lambda$okCallback$7(ImporterDialog.java:351)
at ghidra.util.task.TaskLauncher$1.run(TaskLauncher.java:90)
at ghidra.util.task.Task.monitoredRun(Task.java:126)
at ghidra.util.task.TaskRunner.lambda$startTaskThread$1(TaskRunner.java:94)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.lang.Thread.run(Thread.java:834)
Attachments target.zip
Environment (please complete the following information):
- OS: macOS 10.14
- Java Version: 11.0
- Ghidra Version: 9.1-DEV (b5498c96)
Issue Analytics
- State:
- Created 4 years ago
- Comments:5
Top Results From Across the Web
Ghidra stickied thread : r/ReverseEngineering - Reddit
If I have to maintain a copy of the structure in a text file outside of my Ghidra instance, or export it to...
Read more >How to import x86asm into Ghidra?
I originally started with a .COM file, but I couldn't successfully import into Ghidra. My end goal is to compile it up to...
Read more >Ghidra Change History
Fixed importing of non-Microsoft COFF files when any section crosses address ... Fixed the target of JUMP and JSR for the 6809 to...
Read more >GhidraTips - Ctrl_Alt_Del-generator
Right click, then select "Set External Name Association " and link it to the >library (which you must have previously imported into Ghidra)....
Read more >Ghidra Software Reverse Engineering for Beginners
playing Capture the Flag, and making and breaking things. I would like to thank my dad, ... Figure 1.10 – Ghidra project file...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
We still have to debug the exception, but the message about the invalid NtHeader is simply the PeLoader figuring out that it doesn’t support loading this binary. This binary gets loaded by the MzLoader.
Not sure when exactly this got fixed but it’s working now for 9.1.