在x86上使用GDB而不调试符号? [英] Using GDB without debugging symbols on x86?

查看:164
本文介绍了在x86上使用GDB而不调试符号?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何使用GDB调试32位x86处理器上没有调试符号的程序?检查函数参数,局部变量,解析指针将有助于知道如何做。
意图不是真的用于逆向工程,因为我有时只是太懒了安装调试符号,很高兴知道如何从gdb中获取一些基本信息。

How do I use GDB to debug a program which do not have debugging symbols on a 32-bit x86 processor? Inspecting the function arguments, local variables, resolving pointers would be useful to know how to do. The intention is not really to use this for reverse engineering, as I'm sometimes just too lazy to install the debugging symbols and would be great to know how to get some basic information out of gdb.

推荐答案

开始,你可以做;

gdb "whatever"
break __libc_start_main
r

将设置断点在libc的crt0代码中,允许您在main之前断开,即使目标二进制文件被完全剥离。

that will setup a breakpoint in libc's crt0 code and allow you to break before main, even if the target binary is totally stripped.

这将使您在大多数用户之前的断点处处于运行状态码。然后,您可以单步执行,拆卸,转储等功能,以达到您心中的内容。

That will get you to a running state at a breakpoint before most user code. You can then single step, dissasemble, dump memory etc... to your heart's content.

这个功能适用于所有的平台,事实上你问IA-32 / x86无关紧要。

This works on all platforms, the fact your asking about IA-32 / x86 does not matter.

这篇关于在x86上使用GDB而不调试符号?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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