逆向工程的C程序 [英] reverse engineering c programs

查看:136
本文介绍了逆向工程的C程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

每一个C程序转换为机器code,如果这个二进制分发。由于计算机的指令集是众所周知的,是有可能得到回来的C原程序?

every c program is converted to machine code, if this binary is distributed. Since the instruction set of a computer is well known, is it possible to get back the C original program?

推荐答案

您永远无法找回完全相同的来源,因为有关于保存编译code无元数据。

You can never get back to the exact same source since there is no meta-data about that saved with the compiled code.

但是你可以出从总成 - code重新创建code。

But you can re-create code out from the assembly-code.

看看这本书,如果你有兴趣在这些事情:逆转:逆向工程的秘密

Check out this book if you are interested in these things: Reversing: Secrets of Reverse Engineering.

修改

一些编译器-101在这里,如果你定义一个编译器与另一个词,而不是技术为编译,那会是什么?

Some compilers-101 here, if you were to define a compiler with another word and not as technical as "compiler", what would it be?

答:翻译

一个编译器把你写成其他语言的C编译器翻译成汇编,甚至机 - code语法/短语。 C#code被翻译成IL等等。

A compiler translates the syntax / phrases you have written into another language a C compiler translates to Assembly or even Machine-code. C# Code is translated to IL and so forth.

您有可执行文件仅仅是一个原始的文字/语法翻译,如果你想扭转这种局面,因此它翻译回为你必须在一开始,你将最有可能不会得到相同的结构。

The executable you have is just a translation of your original text / syntax and if you want to "reverse it" hence "translate it back" you will most likely not get the same structure as you had at the start.

如果您从英语翻译成德语和德国回到英语中,森泰斯结构将最有可能是不同的一个更为现实生活中的例子是,可能会使用其他的话,但意思,上下文,将最有可能不已经改变了。

A more real life example would be if you Translate from English to German and the from German back to English, the sentance structure will most likely be different, other words might be used but the meaning, the context, will most likely not have changed.

也是一样的编译器/转换器,如果你从C到ASM去了,道理是一样的,它是阅读它(当然它的优化)。

The same goes for a compiler / translator if you go from C to ASM, the logic is the same, it's just a different way of reading it ( and of course its optimized ).

这篇关于逆向工程的C程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆