一開始需要dump文件中一段數據,但是突然發現自己沒有接觸過這種東西…真TM菜逼…搞到現在居然dump文件都不會…然後簡單總結一下,利用得IDA。
首先從File選項中找到script command這個選項
然後我們主要可以利用兩種語言實現,一種是IDC,是一種IDA強大得擴展語言,另一種是IDApython了
IDC
直接上腳本,這只是dump文件得部分,IDC還有很多厲害得功能,具體可以參考一些博客
https://introspelliam.github.io/2017/09/18/IDA%E7%9A%84%E8%B0%83%E8%AF%95%E8%84%9A%E6%9C%ACidc/
腳本應用得場景是reverse.kr得ImagePrc題目
static main()
{
auto i,fp;
fp = fopen("d:\\dump","wb");
auto start = 0x47e060;
auto size = 90000;
for(i=start;i<start+size;i++)
{
fputc(Byte(i),fp);
}
fp.close();
}
IDApython
import idaapi
start_address = 0x47e060
data_length = 90000
data = idaapi.dbg_read_memory(start_address , data_length)
fp = open('d:\\dump1', 'wb')
fp.write(data)
fp.close()
簡單記錄一下吧…主要確實是太菜了…