From aa30ff140f0f8a2997a175b5c0de1d640b85d7a6 Mon Sep 17 00:00:00 2001 From: xoffio <38369407+Xoffio@users.noreply.github.com> Date: Sun, 23 Nov 2025 22:25:47 -0500 Subject: [PATCH] Added is_debugger_attached to Process - Match js function Process.isDebuggerAttached() --- frida-gum/src/process.rs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/frida-gum/src/process.rs b/frida-gum/src/process.rs index 7cb8a534..fbf70cb5 100644 --- a/frida-gum/src/process.rs +++ b/frida-gum/src/process.rs @@ -163,6 +163,11 @@ impl<'a> Process<'a> { } } + /// Returns a boolean indicating whether a debugger is currently attached + pub fn is_debugger_attached(&self) -> bool { + unsafe { gum_sys::gum_process_is_debugger_attached() == 1 } + } + /// Get this thread’s OS-specific id as a number pub fn current_thread_id(&self) -> u32 { unsafe { gum_sys::gum_process_get_current_thread_id() as u32 }