From 63e4c571bfa5b91bbea8c0b1dfc81a8e2dd14718 Mon Sep 17 00:00:00 2001 From: Chris Renshaw Date: Sun, 21 Jan 2024 00:50:27 -0400 Subject: [PATCH] Hide adbd service state since DroidGuard looks at it - not currently enforced, but play it safe and spoof it by default like with USB state --- app/src/main/cpp/main.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/app/src/main/cpp/main.cpp b/app/src/main/cpp/main.cpp index 555b0d7..1e317bc 100644 --- a/app/src/main/cpp/main.cpp +++ b/app/src/main/cpp/main.cpp @@ -30,8 +30,10 @@ static void modify_callback(void *cookie, const char *name, const char *value, u std::string prop(name); // Spoof specific property values - if (prop == "sys.usb.state") { - value = "mtp"; // Hide USB Debugging + if (prop == "init.svc.adbd") { + value = "stopped"; + } else if (prop == "sys.usb.state") { + value = "mtp"; } if (jsonProps.count(prop)) {