diff --git a/magiskpolicy.c b/magiskpolicy.c index d49904a39..28311e1e7 100644 --- a/magiskpolicy.c +++ b/magiskpolicy.c @@ -3,19 +3,7 @@ * Includes all the parsing logic for the policy statements */ -#ifdef INDEP_BINARY -int magiskpolicy_main(int argc, char *argv[]); -int main(int argc, char *argv[]) { - return magiskpolicy_main(argc, argv); -} -#define SELINUX_PATH "/sys/fs/selinux/" -#define SELINUX_ENFORCE SELINUX_PATH "enforce" -#define SELINUX_POLICY SELINUX_PATH "policy" -#define SELINUX_LOAD SELINUX_PATH "load" -#else #include "magisk.h" -#endif - #include "magiskpolicy.h" #include "sepolicy.h" diff --git a/rules.c b/rules.c index 12b90ee9e..c33f651c1 100644 --- a/rules.c +++ b/rules.c @@ -227,6 +227,9 @@ void sepol_min_rules() { sepol_allow("su", "labeledfs", "filesystem", "unmount"); sepol_allow("kernel", "system_data_file", "file", "read"); + // For changing attributes + sepol_allow("rootfs", "tmpfs", "filesystem", "associate"); + // Xposed sepol_allow("untrusted_app", "untrusted_app", "capability", "setgid"); sepol_allow("system_server", "dex2oat_exec", "file", ALL);