F
F
Flisto2017-08-26 18:50:15
Programming
Flisto, 2017-08-26 18:50:15

Compiler knowledge for Reverse Engineer?

What does Reverse Engineer need to know and understand about compilers? What does it mean to understand how the compiler generates code? And what can it give in reverse engineering? Now I study asm together with C, I write code in C, I study it through a debugger with a disassembler. I see the code on asma, I understand what and what, but I don’t understand at all, why is it so? Why does the compiler use some instructions and not use others. Is it important at all? how did he do it, but it is only important to understand what he did at all, do you mean to understand the asm code?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
L
Ltonid, 2017-08-27
@Flisto

With about the same message, I quit studying Delphi and sat down on assembler. Everything was simple there. What I wrote is what I saw in the debugger. the compiler only attached the necessary headers and assembled the file into a heap.
There was also a case with self-detection of a bug in the compiler of the old c++ builder, but here it’s my fault, don’t use junk.
It makes little sense to know how a particular compiler compiles, the more you reverse, the more you will know how compilers compile. All compilers (unless specially cut out) add their marks to the code. This will help you a lot when reversing and debugging standard pieces. You will see in advance the order of the stack and instructions, the order of functions, and simply by their order you will understand what the whole function does.
If you code at least a little in every popular language and then reverse the program, this will fully answer your question. This is especially noticeable in .NET, QT and other similar programs. The easiest way to reverse is what is closer to assembler.
Ideally, take hello world on different compilers and see the difference.
PS and for God's sake never reverse for the sake of reversing, you'll burn out quickly. Goal first, work later. There are special CrackMe exercises. For more interest, I reversed password stealing viruses...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question