Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
M
Magisk
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
Magisk
Commits
f98c68a2
Commit
f98c68a2
authored
Jul 22, 2021
by
vvb2060
Committed by
John Wu
Aug 29, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Clean up unneeded rules
parent
773bf0c6
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
20 deletions
+0
-20
rules.cpp
native/jni/magiskpolicy/rules.cpp
+0
-20
No files found.
native/jni/magiskpolicy/rules.cpp
View file @
f98c68a2
...
@@ -54,18 +54,6 @@ void sepolicy::magisk_rules() {
...
@@ -54,18 +54,6 @@ void sepolicy::magisk_rules() {
allow
(
SEPOL_CLIENT_DOMAIN
,
SEPOL_EXEC_TYPE
,
"file"
,
ALL
);
allow
(
SEPOL_CLIENT_DOMAIN
,
SEPOL_EXEC_TYPE
,
"file"
,
ALL
);
allow
(
SEPOL_CLIENT_DOMAIN
,
SEPOL_CLIENT_DOMAIN
,
ALL
,
ALL
);
allow
(
SEPOL_CLIENT_DOMAIN
,
SEPOL_CLIENT_DOMAIN
,
ALL
,
ALL
);
const
char
*
pts
[]
{
"devpts"
,
"untrusted_app_devpts"
,
"untrusted_app_25_devpts"
,
"untrusted_app_all_devpts"
};
for
(
auto
type
:
pts
)
{
allow
(
SEPOL_CLIENT_DOMAIN
,
type
,
"chr_file"
,
"open"
);
allow
(
SEPOL_CLIENT_DOMAIN
,
type
,
"chr_file"
,
"getattr"
);
allow
(
SEPOL_CLIENT_DOMAIN
,
type
,
"chr_file"
,
"read"
);
allow
(
SEPOL_CLIENT_DOMAIN
,
type
,
"chr_file"
,
"write"
);
allow
(
SEPOL_CLIENT_DOMAIN
,
type
,
"chr_file"
,
"ioctl"
);
allowxperm
(
SEPOL_CLIENT_DOMAIN
,
type
,
"chr_file"
,
"0x5400-0x54FF"
);
}
// Allow these processes to access MagiskSU
// Allow these processes to access MagiskSU
vector
<
const
char
*>
clients
{
"init"
,
"shell"
,
"update_engine"
,
"appdomain"
};
vector
<
const
char
*>
clients
{
"init"
,
"shell"
,
"update_engine"
,
"appdomain"
};
for
(
auto
type
:
clients
)
{
for
(
auto
type
:
clients
)
{
...
@@ -119,14 +107,6 @@ void sepolicy::magisk_rules() {
...
@@ -119,14 +107,6 @@ void sepolicy::magisk_rules() {
continue
;
continue
;
allow
(
type
,
SEPOL_PROC_DOMAIN
,
"unix_stream_socket"
,
"connectto"
);
allow
(
type
,
SEPOL_PROC_DOMAIN
,
"unix_stream_socket"
,
"connectto"
);
allow
(
type
,
SEPOL_PROC_DOMAIN
,
"unix_stream_socket"
,
"getopt"
);
allow
(
type
,
SEPOL_PROC_DOMAIN
,
"unix_stream_socket"
,
"getopt"
);
// Allow termios ioctl
const
char
*
pts
[]
{
"devpts"
,
"untrusted_app_devpts"
};
for
(
auto
pts_type
:
pts
)
{
allow
(
type
,
pts_type
,
"chr_file"
,
"ioctl"
);
if
(
db
->
policyvers
>=
POLICYDB_VERSION_XPERMS_IOCTL
)
allowxperm
(
type
,
pts_type
,
"chr_file"
,
"0x5400-0x54FF"
);
}
}
}
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment