Skip to content
Snippets Groups Projects
Commit 41ddb80c authored by Lalit Maganti's avatar Lalit Maganti Committed by Gerrit Code Review
Browse files

Merge "sepolicy: add rules for traced_probes to capture stderr and kill atrace on timeout"

parents 0f3decf2 d6ae1a5e
No related branches found
No related tags found
No related merge requests found
...@@ -13,6 +13,11 @@ allow atrace debugfs_tracing:dir r_dir_perms; ...@@ -13,6 +13,11 @@ allow atrace debugfs_tracing:dir r_dir_perms;
allow atrace debugfs_tracing:file rw_file_perms; allow atrace debugfs_tracing:file rw_file_perms;
allow atrace debugfs_trace_marker:file getattr; allow atrace debugfs_trace_marker:file getattr;
# Allow atrace to write data when a pipe is used for stdout/stderr
# This is used by Perfetto to capture the output on error in atrace.
allow atrace traced_probes:fd use;
allow atrace traced_probes:fifo_file write;
# atrace sets debug.atrace.* properties # atrace sets debug.atrace.* properties
set_prop(atrace, debug_prop) set_prop(atrace, debug_prop)
......
...@@ -53,9 +53,8 @@ allow traced_probes user_profile_data_file:dir { getattr open read search }; ...@@ -53,9 +53,8 @@ allow traced_probes user_profile_data_file:dir { getattr open read search };
# their userspace TRACE macros. # their userspace TRACE macros.
domain_auto_trans(traced_probes, atrace_exec, atrace); domain_auto_trans(traced_probes, atrace_exec, atrace);
# This is needed for: path="/system/bin/linker64" # Allow traced_probes to kill atrace on timeout.
# scontext=u:r:atrace:s0 tcontext=u:r:traced_probes:s0 tclass=fd allow traced_probes atrace:process sigkill;
allow atrace traced_probes:fd use;
# Allow traced_probes to access /proc files for system stats. # Allow traced_probes to access /proc files for system stats.
# Note: trace data is NOT exposed to anything other than shell and privileged # Note: trace data is NOT exposed to anything other than shell and privileged
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment