nm long flags

This commit is contained in:
Iddo 2018-05-30 18:47:02 +03:00 committed by GitHub
parent 7494864aed
commit 930258606c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -70,7 +70,7 @@ Interceptor.attach(Module.findExportByName(null, "dlopen"), {
console.log("dlopen called exit with: " + this.lib);
if (this.lib.endsWith("libfoo.so")) {
console.log("ret: " + retval);
var funcAddr = 0x0021e5b4; // find function address with $ nm -CD libfoo.so | grep "SomeClass::someFunction"
var funcAddr = 0x0021e5b4; // find function address with $ nm --demangle --dynamic libfoo.so | grep "SomeClass::someFunction"
var offset = Module.findBaseAddress("libfoo.so"); // Process.findModuleByName("libfoo.so").base) will also work
Interceptor.attach(offset.add(funcAddr), {
onEnter: function(args) {