kernel: Add CONFIG_KSU_MANUAL_SU configuration

- Use random passphrase protection for manual su functionality
This commit is contained in:
ShirkNeko
2025-09-29 06:50:39 +08:00
parent 1281fa70d7
commit 51e6a1b6c7
7 changed files with 49 additions and 6 deletions

View File

@@ -527,6 +527,7 @@ void ksu_allowlist_exit(void)
mutex_unlock(&allowlist_mutex);
}
#ifdef CONFIG_KSU_MANUAL_SU
bool ksu_temp_grant_root_once(uid_t uid)
{
struct app_profile profile = {
@@ -602,3 +603,4 @@ void ksu_temp_revoke_root_once(uid_t uid)
persistent_allow_list();
pr_info("pending_root: UID=%d removed and persist updated\n", uid);
}
#endif