C# 如何反编译c++ dll?

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/19087775/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-08-10 14:03:00  来源:igfitidea点击:

How to decompile c++ dll?

c#c++.netreverse-engineeringdecompiling

提问by Praveen Kumar

I am doing research on reverse engineering. I am able to decompile .net dll files with reflector. But in reflector we can't decompile c++ dll files. Is there any other decompiler available to decompile c++ dll Files?

我正在研究逆向工程。我能够使用反射器反编译 .net dll 文件。但是在反射器中我们不能反编译 c++ dll 文件。是否有其他反编译器可用于反编译 c++ dll 文件?

回答by Jensen

It's not that easy. C++ gets translated into (sometimes) very optimized machine code.

那并没那么简单。C++ 被翻译成(有时)非常优化的机器代码。

There's a detailed article on http://www.codeproject.com/Articles/4210/C-Reverse-Disassemblycontaining more information.

http://www.codeproject.com/Articles/4210/C-Reverse-Disassembly上有一篇详细的文章,其中包含更多信息。

Edit: or indeed, check out the links posted in comments by other people.

编辑:或者确实,查看其他人在评论中发布的链接。

回答by Roman Zavalov

Unlike CLR languages, C++ does not compile into CIL or any sort of bytecode. Moreover, C++ compilers do not store metadata so it's almost impossible to restore original code (custom types, classes, etc). Native code might be heavily optimized as well. However, you can try to recreate pure C code with HexRays for IDA Pro (it's not free though).

与 CLR 语言不同,C++ 不会编译为 CIL 或任何类型的字节码。此外,C++ 编译器不存储元数据,因此几乎不可能恢复原始代码(自定义类型、类等)。本机代码也可能进行了大量优化。但是,您可以尝试使用 HexRays for IDA Pro 重新创建纯 C 代码(虽然它不是免费的)。