Tri Vo | bc8dc3a | 2019-05-26 13:17:08 -0700 | [diff] [blame^] | 1 | typeattribute traceur_app coredomain; |
| 2 | |
| 3 | app_domain(traceur_app); |
| 4 | allow traceur_app debugfs_tracing:file rw_file_perms; |
| 5 | allow traceur_app debugfs_tracing_debug:dir r_dir_perms; |
| 6 | |
| 7 | userdebug_or_eng(` |
| 8 | allow traceur_app debugfs_tracing_debug:file rw_file_perms; |
| 9 | ') |
| 10 | |
| 11 | allow traceur_app trace_data_file:file create_file_perms; |
| 12 | allow traceur_app trace_data_file:dir rw_dir_perms; |
| 13 | allow traceur_app atrace_exec:file rx_file_perms; |
| 14 | |
| 15 | # To exec the perfetto cmdline client and pass it the trace config on |
| 16 | # stdint through a pipe. |
| 17 | allow traceur_app perfetto_exec:file rx_file_perms; |
| 18 | |
| 19 | # Allow to access traced's privileged consumer socket. |
| 20 | unix_socket_connect(traceur_app, traced_consumer, traced) |
| 21 | |
| 22 | dontaudit traceur_app debugfs_tracing_debug:file audit_access; |