enum-root-file-check
8 views
932a1be1...
Description
Possible root detection file check
How to Use
Download the script and run it with Frida CLI:
Download ScriptThen run with Frida:
frida -U -f YOUR_PACKAGE_NAME -l enum-root-file-check.js
Replace YOUR_PACKAGE_NAME with the target app's package name.
Source Code
JavaScript
Java.perform(function() {
console.log("[*] Frida script started for detect root binaries...");
try {
var File = Java.use("java.io.File");
File.exists.implementation = function() {
var path = this.getAbsolutePath();
if (path.includes("/su") || path.includes("/magisk") || path.includes("Superuser") || path.includes("frida") || path.includes("gdb") || path.includes("daemonsu") || path.includes("busybox")) {
console.log("[+] " + path);
// return false;
}
return this.exists();
};
} catch (e) {
console.log("[!] Error hooking root detection: " + e);
}
});
Comments