Skip to content

Binary Ninja and Ghidra tools for reversing M68k Mac binaries

Notifications You must be signed in to change notification settings

ubuntor/m68k_mac_reversing_tools

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

34 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

M68k Mac Reversing Tools (Binary Ninja and Ghidra)

Binary Ninja Instructions

Advantage(s): Correct calling convention for syscalls, stack-based syscalls are nice

Disadvantage(s): Thunks in the jumptable don't automatically update name/function prototype

  1. Make a dump using dump.py.
  2. Add binary_ninja/loader and https://github.com/ubuntor/binaryninja-m68k to Binary Ninja plugins.
  3. Open the dump. The loader should run automatically and start disassembling.

Ghidra Instructions

Advantage(s): Syscalls are functions (so xrefs work), nicer handling of thunks

Disadvantage(s): Stack-based syscall arguments are ugly

  1. Make a dump using dump.py.
  2. Put the files in ghidra/processor in $GHIDRA_INSTALL/Ghidra/Processors/68000/data/languages/.
  3. Put the files in ghidra/data in $GHIDRA_INSTALL/Ghidra/Features/Base/data/.
  4. Add the scripts in ghidra/scripts to Ghidra scripts. These will be in the Analysis/M68k category.
  5. Open the dump as processor 68000, variant Mac.
  6. Run M68kMacJankLoader.java (find functions from jumptable), M68kMacSymbols.java (find symbols), M68kMacPropagateThunks.java (propagate thunk calls), and M68kMacSyscallScript.java (markup syscalls) in that order.

TODO

  • _FP68K (and _*Dispatch, _Pack*, etc.) routine number labelling
  • Finish all syscalls
  • Direct loader for Ghidra from binhex/derez

About

Binary Ninja and Ghidra tools for reversing M68k Mac binaries

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published