Thread: decompileing?

  1. #1
    Registered User
    Join Date
    Dec 2001
    Posts
    12

    decompileing?

    is there a program that will take an exe file and you can get the source code off of that???

  2. #2
    Registered User
    Join Date
    Sep 2001
    Posts
    4,912
    I doubt there is one that can directly do that, as there are many possible combinations in higher level languages to get the usual for lower level languages. For example, cin, gets, getc, etc.. all eventually lead down to 11001101. One other solution you might want to consider is trying to trace C back to its roots in assembler (as usual, I mean the original 370 assembler, not the common mnemonic for that. I suggest Bill Quall's books for this if you don't know much about this). There, you can look at the tables genearated a370 and l370 (compilers for Assembler), and you can eventually get the exact code. Again, Bill Qualls will be excellent on this topic.

    _______________________
    Sean Mackrory
    [email protected]

  3. #3
    Registered User
    Join Date
    Sep 2001
    Posts
    412
    Well, you can ALWAYS get the exact source code in x86 assembler, with a disassembler. Of course, being as no variable names, function names, etc. are preserved, it's not nearly as good as the source.

    BTW, unless he was disassembling mainframe code, why would he disassemble to 370? Although I bet you can probably compile System 370 assembler on a PC, why shouldn't he just use x86 assembly, the native assembly language for his processor?

  4. #4
    Registered User
    Join Date
    Dec 2001
    Posts
    4
    It's easy to convert a binary into assembler code, and it's even possible to convert it into C/C++ or any other programming language, yet the result won't be pretty and probably in no way resemble the original code. Some parts will even not be converted, making it very unlikely that you can just get the source code of any binary.

    I recommend that you start learning assembler

  5. #5
    Registered User
    Join Date
    Aug 2001
    Posts
    47
    I remember seeing a program that would take a DOS EXE file and output C source for it. I never tried it, but I do know that there was a bug in it such that it could only decompile small programs. In addition, there is a lot of information in the original source code that can never be put back in. Comments are gone. Variable names are gone; the new ones are arbitrary. In addition, it cannot convert all ASM to C, and therefore inserts __asm{...} blocks throughout your code that you need to figure out. In short, you're not going to be able to run Quake III through a decompiler and learn all of Carmack's deepest secrets!!

    It is, however, contrary to popular opinion, possible to decompile an EXE into C source code; it has been done.

    I just wouldn't recommend it!!!

Popular pages Recent additions subscribe to a feed