From c60a077821ab80e640bac175a4ceb3098fb82ce0 Mon Sep 17 00:00:00 2001 From: Iddo Date: Sun, 3 Jun 2018 12:02:44 +0300 Subject: [PATCH] print thread backtrace --- README.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 4b9a145..bb30f44 100644 --- a/README.md +++ b/README.md @@ -71,7 +71,10 @@ Interceptor.attach(Module.findExportByName(null, "dlopen"), { var offset = Module.findBaseAddress("libfoo.so"); // Process.findModuleByName("libfoo.so").base) will also work Interceptor.attach(offset.add(funcAddr), { onEnter: function(args) { - console.log('hooked !'); + console.log('hooked !'); + Thread.backtrace(this.context, Backtracer.ACCURATE).forEach(function(addr) { + console.log('\t' + addr + ' : ' + DebugSymbol.fromAddress(addr)); + }); } }); }