aboutsummaryrefslogtreecommitdiff
path: root/frida_mode/src/asan
diff options
context:
space:
mode:
Diffstat (limited to 'frida_mode/src/asan')
-rw-r--r--frida_mode/src/asan/asan.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/frida_mode/src/asan/asan.c b/frida_mode/src/asan/asan.c
index 3a672d31..ad171337 100644
--- a/frida_mode/src/asan/asan.c
+++ b/frida_mode/src/asan/asan.c
@@ -36,6 +36,15 @@ static gboolean asan_exclude_module(const GumModuleDetails *details,
address = gum_module_find_export_by_name(details->name, symbol_name);
if (address == 0) { return TRUE; }
+ /* If the reported address of the symbol is outside of the range of the module
+ * then ignore it */
+ if (address < details->range->base_address) { return TRUE; }
+ if (address > (details->range->base_address + details->range->size)) {
+
+ return TRUE;
+
+ }
+
ranges_add_exclude((GumMemoryRange *)details->range);
return FALSE;