Ida 插件批量分析问题。

逆向工程 艾达 idapro插件 idapro-sdk
2021-07-05 11:22:21

我通过重新定义克服了最近的问题并完成了我的插件。

简而言之,这个插件使用 Hex-Rays Decompiler 来反编译给定的文件,分析伪代码的属性,然后将结果附加到一个 .csv

现在我尝试在批处理模式下使用它,但由于发生以下情况而被难住了:

调用 IDA 的 Cmd 输入:

idaw -A -c -Srecompile.idc input_file

recompile.idc文件:

#include <idc.idc>
static main() {
Wait();
Message("Hello world from IDC!\n");
RunPlugin("REcompile vs Hexrays",0); 
//Exit(0);
}

我显然需要Wait()自动分析。Exit()被评论是因为它是在这一切都修复后使用的。

现在我在执行时得到以下输出:

The initial autoanalysis has been finished.
Hello world from IDC!

LoadLibrary(C:\Program Files (x86)\IDA\plugins\REcompile vs Hexrays.plw) error: Das angegebene Modul wurde nicht gefunden.
C:\Program Files (x86)\IDA\plugins\REcompile vs Hexrays.plw: can't load file
Hex-Rays Decompiler plugin has been loaded (v1.6.0.111005)
Hex-rays version 1.6.0.111005 has been detected, REcompile vs Hexrays ready to use

如您所见,脚本是在加载插件之前执行的。我认为这就是我收到LoadLibrary错误的原因

如果您对插件批处理有任何其他输入或经验,我很高兴收到您的来信。

你好,维克多

1个回答

在加载插件之前,您是否尝试过手动加载 Hex-Rays 插件?

例如:

#include <idc.idc>
static main() {
    Wait();
    Message("Hello world from IDC!\n");
    RunPlugin("hexrays",0);
    RunPlugin("REcompile vs Hexrays",0); 
    //Exit(0);
}