Merge "Remove tests for removed legacy vpns" into main
diff --git a/OWNERS b/OWNERS
index 61eecb2..1f2ac9b 100644
--- a/OWNERS
+++ b/OWNERS
@@ -1,11 +1,9 @@
adamshih@google.com
alanstokes@google.com
bowgotsai@google.com
-cbrubaker@google.com
inseob@google.com
jbires@google.com
jeffv@google.com
jiyong@google.com
smoreland@google.com
-trong@google.com
tweek@google.com
diff --git a/contexts/plat_file_contexts_test b/contexts/plat_file_contexts_test
index 5fc5d29..2d48c37 100644
--- a/contexts/plat_file_contexts_test
+++ b/contexts/plat_file_contexts_test
@@ -365,6 +365,7 @@
/system/bin/mediatranscoding mediatranscoding_exec
/system/bin/mediatuner mediatuner_exec
/system/bin/mdnsd mdnsd_exec
+/system/bin/ot-ctl ot_ctl_exec
/system/bin/installd installd_exec
/system/bin/otapreopt_chroot otapreopt_chroot_exec
/system/bin/otapreopt_slot otapreopt_slot_exec
@@ -402,6 +403,7 @@
/system/bin/perfetto perfetto_exec
/system/bin/misctrl misctrl_exec
/system/bin/mtectrl mtectrl_exec
+/system/bin/kcmdlinectrl kcmdlinectrl_exec
/system/bin/traced traced_exec
/system/bin/traced_perf traced_perf_exec
/system/bin/traced_probes traced_probes_exec
@@ -437,6 +439,7 @@
/system/etc/ld.config. system_linker_config_file
/system/etc/ld.config.test system_linker_config_file
/system/etc/passwd system_passwd_file
+/system/etc/perfetto/persistent_cfg.pbtxt system_perfetto_config_file
/system/etc/seccomp_policy system_seccomp_policy_file
/system/etc/seccomp_policy/crash_dump.x86.policy system_seccomp_policy_file
/system/etc/security/cacerts system_security_cacerts_file
diff --git a/prebuilts/api/34.0/public/domain.te b/prebuilts/api/34.0/public/domain.te
index 1da3f51..d4be205 100644
--- a/prebuilts/api/34.0/public/domain.te
+++ b/prebuilts/api/34.0/public/domain.te
@@ -903,6 +903,9 @@
-crash_dump_exec
-netutils_wrapper_exec
userdebug_or_eng(`-tcpdump_exec')
+ # Vendor components still can invoke shell commands via /system/bin/sh
+ -shell_exec
+ -toolbox_exec
}:file { entrypoint execute execute_no_trans };
')
@@ -983,6 +986,9 @@
-task_profiles_api_file
-task_profiles_file
userdebug_or_eng(`-tcpdump_exec')
+ # Vendor components still can invoke shell commands via /system/bin/sh
+ -shell_exec
+ -toolbox_exec
}:file *;
')
diff --git a/prebuilts/api/34.0/public/hal_neverallows.te b/prebuilts/api/34.0/public/hal_neverallows.te
index e77ea9d..1aae9ee 100644
--- a/prebuilts/api/34.0/public/hal_neverallows.te
+++ b/prebuilts/api/34.0/public/hal_neverallows.te
@@ -83,7 +83,13 @@
halserverdomain
-hal_dumpstate_server
-hal_telephony_server
-} { file_type fs_type }:file execute_no_trans;
+} {
+ file_type
+ fs_type
+ # May invoke shell commands via /system/bin/sh
+ -shell_exec
+ -toolbox_exec
+}:file execute_no_trans;
# Do not allow a process other than init to transition into a HAL domain.
neverallow { domain -init } halserverdomain:process transition;
# Only allow transitioning to a domain by running its executable. Do not
diff --git a/private/app.te b/private/app.te
index 95b85db..b0b5dbb 100644
--- a/private/app.te
+++ b/private/app.te
@@ -464,6 +464,9 @@
# Allow apps to access shared memory file descriptor from the tuner HAL
allow {appdomain -isolated_app_all} hal_tv_tuner_server:fd use;
+# Allow app to access shared memory created by PowerHAL for FMQ use
+allow { appdomain -isolated_app_all } hal_power_server:fd use;
+
# RenderScript always-passthrough HAL
allow { appdomain -isolated_app_all } hal_renderscript_hwservice:hwservice_manager find;
allow appdomain same_process_hal_file:file { execute read open getattr map };
diff --git a/private/domain.te b/private/domain.te
index 66bce05..4692eda 100644
--- a/private/domain.te
+++ b/private/domain.te
@@ -227,6 +227,7 @@
-ueventd
-mtectrl
-misctrl
+ -kcmdlinectrl
} misc_block_device:blk_file { append link relabelfrom rename write open read ioctl lock };
# Limit ability to ptrace or read sensitive /proc/pid files of processes
@@ -806,6 +807,7 @@
} system_app_data_file:dir_file_class_set { create unlink open };
neverallow { domain -init } mtectrl:process { dyntransition transition };
+neverallow { domain -init } kcmdlinectrl:process { dyntransition transition };
# For now, don't allow processes other than gmscore to access /data/misc_ce/<userid>/checkin
neverallow { domain -gmscore_app -init -vold_prepare_subdirs } checkin_data_file:{dir file} *;
diff --git a/private/file.te b/private/file.te
index c4341af..fed98f6 100644
--- a/private/file.te
+++ b/private/file.te
@@ -31,6 +31,9 @@
# /data/misc/perfetto-configs for perfetto configs
type perfetto_configs_data_file, file_type, data_file_type, core_data_file_type;
+# /system/etc/perfetto for perfetto configs
+type system_perfetto_config_file, file_type, system_file_type;
+
# /data/misc/uprobestats-configs for uprobestats configs
type uprobestats_configs_data_file, file_type, data_file_type, core_data_file_type;
diff --git a/private/file_contexts b/private/file_contexts
index 63b3d1e..621e377 100644
--- a/private/file_contexts
+++ b/private/file_contexts
@@ -289,6 +289,7 @@
/system/bin/vold u:object_r:vold_exec:s0
/system/bin/netd u:object_r:netd_exec:s0
/system/bin/wificond u:object_r:wificond_exec:s0
+/system/bin/ot-ctl u:object_r:ot_ctl_exec:s0
/system/bin/audioserver u:object_r:audioserver_exec:s0
/system/bin/mediadrmserver u:object_r:mediadrmserver_exec:s0
/system/bin/mediaserver u:object_r:mediaserver_exec:s0
@@ -334,6 +335,7 @@
/system/bin/perfetto u:object_r:perfetto_exec:s0
/system/bin/mtectrl u:object_r:mtectrl_exec:s0
/system/bin/misctrl u:object_r:misctrl_exec:s0
+/system/bin/kcmdlinectrl u:object_r:kcmdlinectrl_exec:s0
/system/bin/traced u:object_r:traced_exec:s0
/system/bin/traced_perf u:object_r:traced_perf_exec:s0
/system/bin/traced_probes u:object_r:traced_probes_exec:s0
@@ -366,6 +368,7 @@
/system/etc/group u:object_r:system_group_file:s0
/system/etc/ld\.config.* u:object_r:system_linker_config_file:s0
/system/etc/passwd u:object_r:system_passwd_file:s0
+/system/etc/perfetto(/.*)? u:object_r:system_perfetto_config_file:s0
/system/etc/seccomp_policy(/.*)? u:object_r:system_seccomp_policy_file:s0
/system/etc/security/cacerts(/.*)? u:object_r:system_security_cacerts_file:s0
/system/etc/selinux/mapping/[0-9]+\.[0-9]+(\.compat)?\.cil u:object_r:sepolicy_file:s0
diff --git a/private/genfs_contexts b/private/genfs_contexts
index e4baeee..5dfec4b 100644
--- a/private/genfs_contexts
+++ b/private/genfs_contexts
@@ -185,14 +185,10 @@
genfscon debugfs /mmc0 u:object_r:debugfs_mmc:s0
genfscon debugfs /tracing u:object_r:debugfs_tracing_debug:s0
genfscon tracefs / u:object_r:debugfs_tracing_debug:s0
-genfscon debugfs /tracing/tracing_on u:object_r:debugfs_tracing:s0
genfscon tracefs /tracing_on u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/trace u:object_r:debugfs_tracing:s0
genfscon tracefs /trace u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/per_cpu/cpu u:object_r:debugfs_tracing:s0
genfscon tracefs /per_cpu/cpu u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/hyp u:object_r:debugfs_tracing:s0
genfscon tracefs /hyp u:object_r:debugfs_tracing:s0
genfscon debugfs /tracing/instances u:object_r:debugfs_tracing_instances:s0
@@ -209,23 +205,6 @@
genfscon debugfs /tracing/printk_formats u:object_r:debugfs_tracing_printk_formats:s0
genfscon tracefs /printk_formats u:object_r:debugfs_tracing_printk_formats:s0
-genfscon debugfs /tracing/events/header_page u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/f2fs/f2fs_get_data_block/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/f2fs/f2fs_iget/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/f2fs/f2fs_sync_file_enter/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/f2fs/f2fs_sync_file_exit/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/f2fs/f2fs_write_begin/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/f2fs/f2fs_write_end/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/ext4/ext4_da_write_begin/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/ext4/ext4_da_write_end/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/ext4/ext4_es_lookup_extent_enter/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/ext4/ext4_es_lookup_extent_exit/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/ext4/ext4_load_inode/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/ext4/ext4_sync_file_enter/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/ext4/ext4_sync_file_exit/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/block/block_rq_issue/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/block/block_rq_complete/ u:object_r:debugfs_tracing:s0
-
genfscon tracefs /events/header_page u:object_r:debugfs_tracing:s0
genfscon tracefs /events/f2fs/f2fs_get_data_block/ u:object_r:debugfs_tracing:s0
genfscon tracefs /events/f2fs/f2fs_iget/ u:object_r:debugfs_tracing:s0
@@ -244,14 +223,12 @@
genfscon tracefs /events/block/block_rq_complete/ u:object_r:debugfs_tracing:s0
genfscon tracefs /synthetic_events u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/synthetic_events u:object_r:debugfs_tracing:s0
genfscon tracefs /events/synthetic/rss_stat_throttled u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/synthetic/rss_stat_throttled u:object_r:debugfs_tracing:s0
genfscon tracefs /events/synthetic/suspend_resume_minimal u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/synthetic/suspend_resume_minimal u:object_r:debugfs_tracing:s0
genfscon tracefs /trace_clock u:object_r:debugfs_tracing:s0
+genfscon tracefs /buffer_percent u:object_r:debugfs_tracing:s0
genfscon tracefs /buffer_size_kb u:object_r:debugfs_tracing:s0
genfscon tracefs /options/overwrite u:object_r:debugfs_tracing:s0
genfscon tracefs /options/print-tgid u:object_r:debugfs_tracing:s0
@@ -318,72 +295,6 @@
genfscon tracefs /events/clk/clk_disable/ u:object_r:debugfs_tracing:s0
genfscon tracefs /events/clk/clk_set_rate/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/trace_clock u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/buffer_size_kb u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/options/overwrite u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/options/print-tgid u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/options/record-tgid u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/saved_cmdlines_size u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/sched/sched_switch/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/sched/sched_wakeup/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/sched/sched_wakeup_new/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/sched/sched_waking/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/sched/sched_blocked_reason/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/sched/sched_cpu_hotplug/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/sched/sched_process_exit/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/sched/sched_process_free/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/sched/sched_pi_setprio/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/cgroup/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/power/cpu_frequency/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/power/cpu_idle/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/power/clock_enable/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/power/clock_disable/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/power/clock_set_rate/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/power/cpu_frequency_limits/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/power/gpu_frequency/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/power/gpu_work_period/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/power/suspend_resume/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/cpufreq_interactive/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/vmscan/mm_vmscan_direct_reclaim_begin/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/vmscan/mm_vmscan_direct_reclaim_end/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/vmscan/mm_vmscan_kswapd_wake/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/vmscan/mm_vmscan_kswapd_sleep/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/binder/binder_transaction/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/binder/binder_transaction_received/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/binder/binder_lock/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/binder/binder_locked/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/binder/binder_unlock/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/binder/binder_transaction_alloc_buf/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/binder/binder_set_priority/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/binder/binder_command/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/binder/binder_return/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/lowmemorykiller/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/sync/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/fence/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/dma_fence/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/filemap/mm_filemap_add_to_page_cache/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/filemap/mm_filemap_delete_from_page_cache/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/kmem/rss_stat/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/kmem/ion_heap_grow/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/kmem/ion_heap_shrink/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/ion/ion_stat/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/mm_event/mm_event_record/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/oom/oom_score_adj_update/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/oom/mark_victim/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/task/task_rename/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/task/task_newtask/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/ftrace/print/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/gpu_mem/gpu_mem_total u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/thermal/thermal_temperature/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/thermal/cdev_update/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/cpuhp/cpuhp_enter/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/cpuhp/cpuhp_exit/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/ipi/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/irq/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/clk/clk_enable/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/clk/clk_disable/ u:object_r:debugfs_tracing:s0
-genfscon debugfs /tracing/events/clk/clk_set_rate/ u:object_r:debugfs_tracing:s0
-
genfscon debugfs /kcov u:object_r:debugfs_kcov:s0
genfscon securityfs / u:object_r:securityfs:s0
diff --git a/private/kcmdlinectrl.te b/private/kcmdlinectrl.te
new file mode 100644
index 0000000..d569dc0
--- /dev/null
+++ b/private/kcmdlinectrl.te
@@ -0,0 +1,22 @@
+# kcmdlinectrl is a tool to have the bootloader send kernel commandline flags
+# for enabling dogfood features in the kernel
+type kcmdlinectrl, domain, coredomain;
+type kcmdlinectrl_exec, system_file_type, exec_type, file_type;
+
+init_daemon_domain(kcmdlinectrl)
+
+# for setting kcmdline properties to match the bootloader state.
+set_prop(kcmdlinectrl, kcmdline_prop)
+
+# kcmdlinectrl communicates the request to the bootloader via the misc partition.
+# needs to write to update the request in misc partition, and read to sync
+# back to the property.
+allow kcmdlinectrl misc_block_device:blk_file rw_file_perms;
+allow kcmdlinectrl block_device:dir r_dir_perms;
+read_fstab(kcmdlinectrl)
+
+# bootloader_message tries to find the fstab in the device config path first,
+# but because we've already booted up we can use the ro.boot properties instead,
+# so we can just ignore the SELinux denial.
+dontaudit kcmdlinectrl sysfs_dt_firmware_android:dir search;
+dontaudit kcmdlinectrl vendor_property_type:file read;
diff --git a/private/ot_ctl.te b/private/ot_ctl.te
new file mode 100644
index 0000000..7325ce5
--- /dev/null
+++ b/private/ot_ctl.te
@@ -0,0 +1,12 @@
+#
+# ot-ctl is a command line tool for controlling ot-daemon
+#
+
+type ot_ctl, domain, coredomain;
+type ot_ctl_exec, exec_type, file_type, system_file_type;
+
+# ot-ctl is available in only userdebug or eng build
+userdebug_or_eng(`
+ # ot-ctl connects to ot-daemon via the socket
+ allow ot_ctl ot_daemon_socket:sock_file rw_file_perms;
+')
diff --git a/private/ot_daemon.te b/private/ot_daemon.te
index 341fa9c..2fc74b5 100644
--- a/private/ot_daemon.te
+++ b/private/ot_daemon.te
@@ -39,3 +39,12 @@
# For collecting bugreports.
allow ot_daemon dumpstate:fd use;
allow ot_daemon dumpstate:fifo_file write;
+
+# ot-daemon socket is for only ot-daemon and ot-ctl
+neverallow {
+ domain
+ -ot_daemon
+ userdebug_or_eng(`-ot_ctl')
+ -init
+ -vendor_init
+} ot_daemon_socket:sock_file *;
diff --git a/private/perfetto.te b/private/perfetto.te
index d0088ef..616da39 100644
--- a/private/perfetto.te
+++ b/private/perfetto.te
@@ -40,6 +40,10 @@
allow perfetto perfetto_configs_data_file:dir r_dir_perms;
allow perfetto perfetto_configs_data_file:file r_file_perms;
+# Allow perfetto to read the trace config from /system/etc/perfetto.
+allow perfetto system_perfetto_config_file:dir r_dir_perms;
+allow perfetto system_perfetto_config_file:file r_file_perms;
+
# Allow perfetto to read the trace config from statsd, mm_events and shell
# (both root and non-root) on stdin and also to write the resulting trace to
# stdout.
diff --git a/private/platform_app.te b/private/platform_app.te
index cd95353..eb1a7c7 100644
--- a/private/platform_app.te
+++ b/private/platform_app.te
@@ -64,10 +64,24 @@
auditallow platform_app proc_net_type:{ dir file lnk_file } { getattr open read };
')
+# Allow sharing traces to betterbug from /data/misc/wmtrace.
+userdebug_or_eng(`
+ allow platform_app trace_data_file:file create_file_perms;
+ allow platform_app trace_data_file:dir rw_dir_perms;
+')
+
# Allow writing and removing wmshell protolog in /data/misc/wmtrace.
userdebug_or_eng(`
allow platform_app wm_trace_data_file:dir rw_dir_perms;
- allow platform_app wm_trace_data_file:file { getattr setattr create unlink w_file_perms };
+ allow platform_app wm_trace_data_file:file { getattr setattr create unlink rw_file_perms };
+')
+
+
+# To exec the perfetto cmdline client and pass it the trace config on
+# stdint through a pipe. Allow to access traced's privileged consumer socket.
+userdebug_or_eng(`
+ allow platform_app perfetto_exec:file rx_file_perms;
+ unix_socket_connect(platform_app, traced_consumer, traced);
')
allow platform_app audioserver_service:service_manager find;
diff --git a/private/postinstall.te b/private/postinstall.te
index 7060c59..92ddbbf 100644
--- a/private/postinstall.te
+++ b/private/postinstall.te
@@ -3,3 +3,6 @@
domain_auto_trans(postinstall, otapreopt_chroot_exec, otapreopt_chroot)
allow postinstall rootfs:dir r_dir_perms;
+
+# Allow invoking `pm` shell commands.
+allow postinstall package_service:service_manager find;
diff --git a/private/property.te b/private/property.te
index 2d030ab..e06c7e7 100644
--- a/private/property.te
+++ b/private/property.te
@@ -24,6 +24,7 @@
system_internal_prop(init_service_status_private_prop)
system_internal_prop(init_storage_prop)
system_internal_prop(init_svc_debug_prop)
+system_internal_prop(kcmdline_prop)
system_internal_prop(keystore_crash_prop)
system_internal_prop(keystore_listen_prop)
system_internal_prop(last_boot_reason_prop)
@@ -492,6 +493,15 @@
neverallow {
domain
-init
+ -shell
+ -kcmdlinectrl
+} {
+ kcmdline_prop
+}:property_service set;
+
+neverallow {
+ domain
+ -init
-system_server
-vendor_init
} zram_control_prop:property_service set;
diff --git a/private/property_contexts b/private/property_contexts
index 7e31dd7..cb22d64 100644
--- a/private/property_contexts
+++ b/private/property_contexts
@@ -893,6 +893,11 @@
arm64.memtag. u:object_r:arm64_memtag_prop:s0 prefix string
persist.arm64.memtag. u:object_r:arm64_memtag_prop:s0 prefix string
+# kcmdline props for dogfood experiments
+# All kcmdline properties share the kcmdline_prop context
+kcmdline.loaded u:object_r:kcmdline_prop:s0 exact bool
+kcmdline.binder u:object_r:kcmdline_prop:s0 exact enum c rust
+
net.redirect_socket_calls.hooked u:object_r:socket_hook_prop:s0 exact bool
# Settings system properties containing mutable "global" device settings.
diff --git a/private/shell.te b/private/shell.te
index 60684f4..2b7bd88 100644
--- a/private/shell.te
+++ b/private/shell.te
@@ -228,6 +228,9 @@
# Allow shell to write MTE properties even on user builds.
set_prop(shell, arm64_memtag_prop)
+# Allow shell to write kcmdline properties even on user builds.
+set_prop(shell, kcmdline_prop)
+
# Allow shell to read the dm-verity props on user builds.
get_prop(shell, verity_status_prop)
diff --git a/private/traced.te b/private/traced.te
index d4e5bec..796095f 100644
--- a/private/traced.te
+++ b/private/traced.te
@@ -28,6 +28,7 @@
# Allow traceur to pass open file descriptors to traced, so traced can directly
# write into the output file without doing roundtrips over IPC.
allow traced traceur_app:fd use;
+allow traced platform_app:fd use;
allow traced trace_data_file:file { read write };
# Allow perfetto to access the proxy service for notifying Traceur.
@@ -119,6 +120,7 @@
-traced
-dumpstate
-traceur_app
+ -platform_app
-shell
-system_server
-perfetto
diff --git a/private/virtual_camera.te b/private/virtual_camera.te
index dde98c0..45dc8a1 100644
--- a/private/virtual_camera.te
+++ b/private/virtual_camera.te
@@ -38,6 +38,9 @@
allow virtual_camera gpu_device:chr_file rw_file_perms;
allow virtual_camera gpu_device:dir r_dir_perms;
+# Allow virtual camera to use graphics composer fd-s (fences).
+allow virtual_camera hal_graphics_composer:fd use;
+
# For collecting bugreports.
allow virtual_camera dumpstate:fd use;
allow virtual_camera dumpstate:fifo_file write;
diff --git a/public/hal_drm.te b/public/hal_drm.te
index 0ee0c5f..211fbb7 100644
--- a/public/hal_drm.te
+++ b/public/hal_drm.te
@@ -29,10 +29,8 @@
allow hal_drm cgroup_v2:file w_file_perms;
# Allow dumpsys Widevine without root
-userdebug_or_eng(`
- allow hal_drm_server shell:fd use;
- allow hal_drm_server shell:fifo_file write;
-')
+allow hal_drm_server shell:fd use;
+allow hal_drm_server shell:fifo_file write;
# Allow access to ion memory allocation device
allow hal_drm ion_device:chr_file rw_file_perms;