kernel & KernelSU & ksu_susfs: Temp fix for avc log message being leaked by...
kernel & KernelSU & ksu_susfs: Temp fix for avc log message being leaked by logd and added new toggle for enabling or disabling avc log spoofing - See full details: https://android-review.googlesource.com/c/platform/system/logging/+/3725346/2 https://github.com/aviraxp/ZN-AuditPatch - Since spoofing avc log in kernel may make things harder when users trying to debug with some permission issues or selinux issues, so thats why the toggle is created here and this is just a temp fix implemented in kernel side - usage: ksu_susfs enable_avc_log_spoofing <0|1> Co-authored-by: simonpunk <simonpunk2016@gmail.com>
This commit is contained in:
@@ -1010,6 +1010,17 @@ int ksu_handle_prctl(int option, unsigned long arg2, unsigned long arg3,
|
||||
return 0;
|
||||
}
|
||||
#endif // #ifdef CONFIG_KSU_SUSFS_SUS_SU
|
||||
if (arg2 == CMD_SUSFS_ENABLE_AVC_LOG_SPOOFING) {
|
||||
int error = 0;
|
||||
if (arg3 != 0 && arg3 != 1) {
|
||||
pr_err("susfs: CMD_SUSFS_ENABLE_AVC_LOG_SPOOFING -> arg3 can only be 0 or 1\n");
|
||||
return 0;
|
||||
}
|
||||
susfs_set_avc_log_spoofing(arg3);
|
||||
if (copy_to_user((void __user*)arg5, &error, sizeof(error)))
|
||||
pr_info("susfs: copy_to_user() failed\n");
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
#endif //#ifdef CONFIG_KSU_SUSFS
|
||||
|
||||
|
||||
Reference in New Issue
Block a user