Code Monkey home page Code Monkey logo

m68k_mac_reversing_tools's Introduction

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): Return value for syscalls that use pascal calling convention disappears (Ghidra Issue), 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
  • Figure out ghidra issue
  • Direct loader for Ghidra from binhex/derez

m68k_mac_reversing_tools's People

Contributors

ubuntor avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.