When I want to define a new class in frida-CLI, error occurs.
My frida commands of register a class is:
const testCls = Java.registerClass({
name: 'com.testCls',
methods: {
$init: function () {
console.log('Constructor of testCls is called');
},
}
});
The error message is
Error: java.io.IOException: Permission denied
at <anonymous> (frida/node_modules/frida-java-bridge/lib/env.js:124)
at value (frida/node_modules/frida-java-bridge/lib/class-factory.js:1065)
at e (frida/node_modules/frida-java-bridge/lib/class-factory.js:586)
at apply (native)
at value (frida/node_modules/frida-java-bridge/lib/class-factory.js:970)
at e (frida/node_modules/frida-java-bridge/lib/class-factory.js:553)
at ue (frida/node_modules/frida-java-bridge/lib/class-factory.js:1197)
at fromBuffer (frida/node_modules/frida-java-bridge/lib/class-factory.js:1175)
at registerClass (frida/node_modules/frida-java-bridge/lib/class-factory.js:216)
at registerClass (frida/node_modules/frida-java-bridge/index.js:283)
at <eval> (<input>:11)
at eval (native)
I'm testing on:
Pixel 3a, Android 12 (Magisk 25.2 Rooted but without adb root)
App to be hooked has been granted permission.WRITE_EXTERNAL_STORAGE and permission.READ_EXTERNAL_STORAGE
frida-server-15.2.2-android-arm64
Any way to help me solve this problem or register a java class?
When I want to define a new class in frida-CLI, error occurs.
My frida commands of register a class is:
The error message is
I'm testing on:
adb root
)Any way to help me solve this problem or register a java class?