在 ROM 转储中查找 API(DOS 调试)

逆向工程 x86 只读存储器
2021-06-28 14:00:59

使用以下说明HP 200LX转储 ROM

debug #Enters the debug mode
r bx #Reads the bx register and prompts you to enter a new value
30 #The new value for bx
r cx #Reads the cx register and prompts you to enter a new value
0000 #The new value for cx
n 3M.bin #The name of the dump file
w 0:0 #Write out the data, starting at offset 0:0

并在数据中看到一些有趣的字符串,但想以技术上更复杂的方式进行调查。

查找 API(即过程入口点)的最简单方法是什么?我对 cc:Mail Vendor Independent Messaging API 特别感兴趣,我怀疑它隐藏在某个地方。

磁盘上至少还有一个似乎相关的二进制文件,所以理想情况下,我想要一个工具来同时读取 ROM 转储和这个文件。

1个回答

在 DOS 程序中,要查找的常见序列是一系列push指令,以sub sp,<size-of-local-vars>. 这是一个典型的函数入口。如果没有更多信息,很难确定这是否是 API 入口点。您可以使用能够处理 MS-DOS 映像的反汇编工具(如 Reko,https://github.com/uxmal/reko)对二进制文件执行启发式扫描,然后查看具有 0 个调用方的过程。这为您提供了一个起点。