bmax121 / APatch

The patching of Android kernel and Android system
GNU General Public License v3.0
3.46k stars 276 forks source link

Renaming/hiding of APatch mounts #477

Closed cawidtu closed 1 month ago

cawidtu commented 1 month ago

Is your feature request related to a problem?/你的请求是否与某个问题相关?

After activating Android Patch (version 10762, on Android 14, kernel 5.10.209-gki-ga53be4b1411a), the following mounts or similar are visible in a non-root shell:

APatch on /debug_ramdisk type tmpfs (rw,seclabel,relatime,size=5688992k,nr_inodes=1422248)
APatch on /data/adb/modules/zygisksu/module.prop type tmpfs (rw,seclabel,relatime,size=5688992k,nr_inodes=1422248)

Describe the solution you'd like/描述你想要的解决方案

I would like to hide these mounts (e.g. rename "APatch" to something random) to avoid root detection by certain apps.

Describe alternatives you've considered/描述您考虑过的备选方案

After deactivating APatch, the two lines were no longer produced by mount and the affected apps did no longer report a rooted device.

Additional context/其他信息

No response

pomelohan commented 1 month ago

Renaming APatch mounts made no effort because it was overlay mount, easy to be detected.

However, hiding is not a task that APatch should do. You can use Zygisk Next's Enforce Denylist feature or developing a KPM which has the ability of hiding mountinfo to make it disappeared from mountinfo.

cawidtu commented 1 month ago

Thank you. Just an observation: ZygiskNext does not consider the "DenyList" of APatch at the moment. However, I was able to use KernelSU + ZygiskNext to hide the mountinfo.