使用 hexdump 查看静态变量
我正在准备参加有关软件开发安全方面的讲座考试。我想知道是否总是可以使用 hexdump 从二进制文件中读取静态字符数组的值?
如果不是,那取决于什么因素,我是否可以用十六进制编辑器读取它的值?
谢谢,
I am preparing myself for a lecture exam on security aspects of software development. I would like to know if it is always possible to read the value of a static char array from a binary with hexdump?
If not on what factors does it depend whether I can read the value of it or not with a hexeditor??
thanks,
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
如果您可以在内存中找到该变量,则可以使用 hexdump 读取它 - 这就是 hexdump 程序的用途。查找的容易程度取决于您对二进制文件有多少信息以及您对其预期内容的了解。
If you can locate the variable in the memory, you can read it with a hexdump - that's what hexdump programs are for. How easy it is to locate depends on how much information you have about the binary and on what you know about its expected contents.
假设 C,是的,在简单的情况下。然而,有一些方法可以混淆这些变量以限制逆向工程。
Assuming C, yes, in the simple case. However, there are methods to obfuscate such variables to limit reverse engineering.
是的,但前提是它在编译时初始化。您可以从核心转储或调试器中获得更多信息。
Yes, but only if it is initialized at compile time. You could get more from a core dump or a debugger.