crash_dump: disallow ptrace of TCB components

Remove permissions and add neverallow assertion.

Bug: 110107376
Test: kill -6 <components excluded from ptrace>
Change-Id: If8b9c932af03a551e40e786d591544ecdd4e5c98
Merged-In: If8b9c932af03a551e40e786d591544ecdd4e5c98
(cherry picked from commit f1554f1588)
This commit is contained in:
Jeff Vander Stoep 2018-06-13 22:10:37 -07:00 committed by Jeffrey Vander Stoep
parent a401c9f9ca
commit f0e6a70ab5
2 changed files with 11 additions and 8 deletions

View file

@ -1 +1,12 @@
typeattribute crash_dump coredomain;
allow crash_dump {
domain
-crash_dump
-init
-kernel
-keystore
-logd
-ueventd
-vold
}:process { ptrace signal sigchld sigstop sigkill };

View file

@ -1,14 +1,6 @@
type crash_dump, domain;
type crash_dump_exec, exec_type, file_type;
allow crash_dump {
domain
-init
-crash_dump
-keystore
-logd
}:process { ptrace signal sigchld sigstop sigkill };
# crash_dump might inherit CAP_SYS_PTRACE from a privileged process,
# which will result in an audit log even when it's allowed to trace.
dontaudit crash_dump self:capability { sys_ptrace };