disassembler

Does anyone know where to find a "how to" on coding your own disassembler?

Comments

  • I made a disassembler few years ago (it's funny because I didn't know assembly language).

    1. First you must find out if the input file is a COM or an EXE program
    2. Get the entry point in the file (for COMs it will be the first char, for EXE you must get it from it's header)
    3. It would be also nice to know the initial IP (for COMs it will be 100h, for EXE you must find in the header)
    4. You must have a main loop which take one byte from the file and check it.

    You must always check each byte until you identify a command and then you must know how many of the next bytes are it's arguments and convert it to text and save it to a file.

    I learned the hex numbers of command using Turbo Debuger and I disassembled it to a file and I checked line by line if there are hex numbers where a command should be, the I had only to add it.
  • : Does anyone know where to find a "how to" on coding your
    : own disassembler?

    - it's easy, I made my first disassembler in C++,
    you just need some tables, try searching for
    "Assembly and Disassembly tables" by Tenie Remmel,
    if you want I can send it to you.
    Or I can even send you a Disassembler DLL that
    I wrote for my emulator.

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories