This isn't strictly a Mac/Apple programming question, but there's no "generic" category!
I was introduced to Ghidra a few days ago. If I understand correctly, it can take a binary (whether for Windows, Mac OS, Linux or a handful of others) and disassemble it. It can then produce a C representation of the code. While the resulting code isn't particularly readable (since it's missing all the function and variable names, among other things) it's apparently possible to recompile the result back into a working binary.
I do have a couple of questions though. First and foremost, does anyone know whether it can produce C versions of binaries that weren't originally written in C? If something was originally produced in assembly, is Ghidra able to create equivalent C code? Or is it limited to binaries that came from a C compiler?
Secondly, is it possible to feed in an existing plain-text assembly file? From what I've seen so far, it'll produce an assembly listing from a binary, but what if I already have a listing?
I'm probably a little over my head here
I was introduced to Ghidra a few days ago. If I understand correctly, it can take a binary (whether for Windows, Mac OS, Linux or a handful of others) and disassemble it. It can then produce a C representation of the code. While the resulting code isn't particularly readable (since it's missing all the function and variable names, among other things) it's apparently possible to recompile the result back into a working binary.
I do have a couple of questions though. First and foremost, does anyone know whether it can produce C versions of binaries that weren't originally written in C? If something was originally produced in assembly, is Ghidra able to create equivalent C code? Or is it limited to binaries that came from a C compiler?
Secondly, is it possible to feed in an existing plain-text assembly file? From what I've seen so far, it'll produce an assembly listing from a binary, but what if I already have a listing?
I'm probably a little over my head here