mirror of
https://github.com/kvorschk/Magisk.git
synced 2026-12-05 11:30:47 -05:00
Refactor magiskrc
This commit is contained in:
@@ -64,7 +64,7 @@ void sepolicy::magisk_rules() {
|
||||
}
|
||||
|
||||
// Allow these processes to access MagiskSU
|
||||
vector<const char *> clients{ "init", "shell", "update_engine", "appdomain" };
|
||||
vector<const char *> clients{ "shell", "update_engine", "appdomain" };
|
||||
for (auto type : clients) {
|
||||
if (!exists(type))
|
||||
continue;
|
||||
@@ -137,6 +137,10 @@ void sepolicy::magisk_rules() {
|
||||
// Let init run stuffs
|
||||
allow("kernel", SEPOL_PROC_DOMAIN, "fd", "use");
|
||||
allow("init", SEPOL_PROC_DOMAIN, "process", ALL);
|
||||
allow("init", SEPOL_EXEC_TYPE, "file", "read");
|
||||
allow("init", SEPOL_EXEC_TYPE, "file", "open");
|
||||
allow("init", SEPOL_EXEC_TYPE, "file", "getattr");
|
||||
allow("init", SEPOL_EXEC_TYPE, "file", "execute");
|
||||
|
||||
// suRights
|
||||
allow("servicemanager", SEPOL_PROC_DOMAIN, "dir", "search");
|
||||
|
||||
Reference in New Issue
Block a user