如何反汇编 Pro*C/C++ 程序?

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/560344/
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-27 15:57:46  来源:igfitidea点击:

How does one disassemble Pro*C/C++ programs?

c++creverse-engineeringdecompiling

提问by Ahmed Atia

Is there a way to disassemble Pro*C/C++ executable files?

有没有办法反汇编 Pro*C/C++ 可执行文件?

回答by Kosi2801

In general there should be disassemblers available for executables, regardless how they have been created (gcc, proC, handwritten, etc.) but decompiling an optimized binary most probably leads to unreadable or source.

一般来说,应该有可用于可执行文件的反汇编程序,无论它们是如何创建的(gcc、proC、手写等),但反编译优化的二进制文件很可能会导致不可读或源代码。

Also, Pro C/C++ is not directly a compiler but outputs C/C++ code which then in turn is compiled by a platform native compiler (gcc, xlc, vc++, etc.).

此外,Pro C/C++ 不是直接的编译器,而是输出 C/C++ 代码,然后由平台本机编译器(gcc、xlc、vc++ 等)编译。

Furthermore the generated code is often not directly compilable again without lots of manual corrections.

此外,如果没有大量手动更正,生成的代码通常无法直接再次编译。

If you still want to try your luck, have a look at this list of x86 disassemblersfor a start.

如果您仍然想试试运气,请先查看此x86 反汇编程序列表。

回答by Wylder

Try PE Explorer Disassembler, a very decent disassembler for 32-bit executable files.

试试PE Explorer Disassembler,这是一个非常适合 32 位可执行文件的反汇编程序。

回答by Pablo Santa Cruz

You should try disassembling with disassembler tool of your choice. At the end of the day, executables compiled with PRO C/C++ preprocessor are just plain C/C++ executables.

您应该尝试使用您选择的反汇编工具进行反汇编。归根结底,使用 PRO C/C++ 预处理器编译的可执行文件只是普通的 C/C++ 可执行文件。

If what you're looking for is SQL sentences within your code, you might want to take a look at:

如果您要查找的是代码中的 SQL 语句,您可能需要查看:

$ strings your_executable_file

It will give you a list of all constants strings present in your executable, and chances are that you are going to get SQL sentences with that.

它将为您提供可执行文件中存在的所有常量字符串的列表,并且您可能会得到 SQL 语句。

Good luck.

祝你好运。