dcashman | 2e00e63 | 2016-10-12 14:58:09 -0700 | [diff] [blame] | 1 | # TODO: deal with tmpfs_domain pub/priv split properly |
| 2 | # Read system properties managed by zygote. |
| 3 | allow appdomain zygote_tmpfs:file read; |
Nathan Harold | ee26864 | 2017-12-14 18:20:30 -0800 | [diff] [blame] | 4 | |
Benjamin Gordon | 360559e | 2018-09-06 14:41:34 -0600 | [diff] [blame] | 5 | # Read from (but not create) system_server buffers transferred through |
| 6 | # ashmem, e.g. battery stats. |
| 7 | allow appdomain system_server_tmpfs:file read; |
| 8 | |
ji, zhenlong z | fdfa42b | 2018-10-19 13:21:52 +0800 | [diff] [blame] | 9 | # Get info from priv_app through ashmem, such as contact |
| 10 | # info etc. |
| 11 | allow appdomain priv_app_tmpfs:file read; |
| 12 | |
Nathan Harold | ee26864 | 2017-12-14 18:20:30 -0800 | [diff] [blame] | 13 | neverallow appdomain system_server:udp_socket { |
Nathan Harold | 252b015 | 2018-03-27 06:34:54 -0700 | [diff] [blame] | 14 | accept append bind create ioctl listen lock name_bind |
| 15 | relabelfrom relabelto setattr shutdown }; |
Nick Kralevich | 1e5021c | 2018-11-28 17:50:24 -0800 | [diff] [blame] | 16 | |
| 17 | # Transition to a non-app domain. |
| 18 | # Exception for the shell and su domains, can transition to runas, etc. |
Nick Kralevich | 0eb0a16 | 2018-12-12 09:06:05 -0800 | [diff] [blame^] | 19 | # Exception for crash_dump to allow for app crash reporting. |
| 20 | # Exception for renderscript binaries (/system/bin/bcc, /system/bin/ld.mc) |
| 21 | # to allow renderscript to create privileged executable files. |
| 22 | neverallow { appdomain -shell userdebug_or_eng(`-su') } |
| 23 | { domain -appdomain -crash_dump -rs }:process { transition }; |
| 24 | neverallow { appdomain -shell userdebug_or_eng(`-su') } |
| 25 | { domain -appdomain }:process { dyntransition }; |