FrenchYeti / dexcalibur

[Official] Android reverse engineering tool focused on dynamic instrumentation automation leveraging Frida. It disassembles dex, analyzes it statically, generates hooks, discovers reflected methods, stores intercepted data and does new things from it. Its aim is to be an all-in-one Android reverse engineering platform.
Apache License 2.0
1.06k stars 126 forks source link

Error when run dexcalibur #53

Closed visualsayed closed 3 years ago

visualsayed commented 3 years ago

Given this command:

node --max-old-space-size=8192 ./dexcalibur

I get the following error:

\AppData\Roaming\npm\node_modules\dexcalibur\dexcalibur:5 if [ $# = 2 ] && [ $1 = "--max-heap" ] && [ $2 -ge 1024 ] ^

SyntaxError: Unexpected token '['  at wrapSafe (internal/modules/cjs/loader.js:979:16)  at Module._compile (internal/modules/cjs/loader.js:1027:27)  at Object.Module._extensions..js (internal/modules/cjs/loader.js:1092:10)  at Module.load (internal/modules/cjs/loader.js:928:32)  at Function.Module._load (internal/modules/cjs/loader.js:769:14)  at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:72:12)  at internal/main/run_main_module.js:17:47

visualsayed commented 3 years ago

My OS: is windows 10 64

FrenchYeti commented 3 years ago

Hi,

./dexcaliburis a bash script wrapping 'node ...'.

So, on Windows, you should execute ./dexcalibur.jsinstead of ./dexcalibur.

Be aware, Dexcalibur has not been tested on windows.

visualsayed commented 3 years ago

Thanks @FrenchYeti :-)

I got this error:

Error: Cannot find module '../build/Release/node_xz.node' Require stack:

FrenchYeti commented 3 years ago

Actually, you cannot use Dexcalibur as-is on Windows.

For Windows users, node_xzis the main issue but it exists a simple workaround : By following this comment https://github.com/FrenchYeti/dexcalibur/issues/35#issuecomment-783363513 you could be able to make change and install Dexcalibur properly on Windows.

FrenchYeti commented 3 years ago

Windows is now supported by version >= 0.7.10 However, dexcalibur must be launched directly by calling it with "node" like that node <FULL_PATH>/dexcalibur.js.