-1

I need to convert a lot of Machine code hex to Assembly. I'm using the free version of IDA. I'm confident it can do this, but whenever I input the machine code in formats raw, bin, hex, exe, dmp it opens like this:

seg000:00010  32 34 35 32 20 33 31 35  30 20 65...      2452 3150 e0ff 3

But I want something like:

seg000:00010   2452 3150 e0ff 3...moreHex           f..b...%..3k..

These questions are close but not specific enough for me. How to convert machine code to assembly code?
How might I convert Intel 80386 Machine Code to Assembly Language?

Community
  • 1
  • 1
Ponyisasquare
  • 189
  • 1
  • 2
  • 12
  • Are you typing the bytes into IDA? Or loading a file? You don't need IDA just to disassemble stuff. If you have a regular Windows exe, you can use objdump, available on Linux with apt-get binutils, and on Windows with cygwin. If you have a raw bin file with x86 code, you can use ndisasm, available on Linux with apt-get ndisasm, or on Windows with cygwin. – mattypiper Sep 05 '15 at 18:38
  • 1
    The sample output you want is not "assembly", so your question is unclear. – Dwayne Towell Sep 05 '15 at 18:41

1 Answers1

2

Your question is vague, and I'm not sure what OS you use, but I'll try my best.

Download a hex editor for Windows. A good free tool is HxD.

Create a new file and type your bytes in the left area. ASCII representation will show up on the right side, which may or may not mean anything. Save your file as something like code.bin. Then open that file in IDA Free, and specify "Binary File" as the file type and select the processor type, which I assume will be one of the Intel x86 variants, eg Intel Pentium 4. Once the file is loaded, IDA won't really do anything since this is a raw file, so you have to specify where the code is by selecting address 0 and then pressing the "c" key to convert the bytes into code.

mattypiper
  • 1,222
  • 8
  • 8
  • Good answer. Do I actually need the WHOLE program? What is the downside of only displaying one function? Excuse my ignorance, I'm pretty new to this low level stuff. (I was trying to save as bin it with a txt editor before) – Ponyisasquare Sep 05 '15 at 19:38