Whitelist vendor-init-settable bluetooth_prop and wifi_prop

Values of the following properties are set by SoC vendors on some
devices including Pixels.
- persist.bluetooth.a2dp_offload.cap
- persist.bluetooth.a2dp_offload.enable
- persist.vendor.bluetooth.a2dp_offload.enable
- ro.bt.bdaddr_path
- wlan.driver.status

So they should be whitelisted for compatibility.

Bug: 77633703
Test: succeeded building and tested with Pixels
Change-Id: Ib2b81bcc1fd70ddd571dc7fb2b923b576d62b7d5
diff --git a/private/audioserver.te b/private/audioserver.te
index 471fcbe..a82cfec 100644
--- a/private/audioserver.te
+++ b/private/audioserver.te
@@ -37,7 +37,9 @@
 allow audioserver scheduling_policy_service:service_manager find;
 
 # Allow read/write access to bluetooth-specific properties
+set_prop(audioserver, bluetooth_a2dp_offload_prop)
 set_prop(audioserver, bluetooth_prop)
+set_prop(audioserver, exported_bluetooth_prop)
 
 # Grant access to audio files to audioserver
 allow audioserver audio_data_file:dir ra_dir_perms;
diff --git a/private/bluetooth.te b/private/bluetooth.te
index fec9494..d419855 100644
--- a/private/bluetooth.te
+++ b/private/bluetooth.te
@@ -39,7 +39,9 @@
 allow bluetooth proc_bluetooth_writable:file rw_file_perms;
 
 # Allow write access to bluetooth specific properties
+set_prop(bluetooth, bluetooth_a2dp_offload_prop)
 set_prop(bluetooth, bluetooth_prop)
+set_prop(bluetooth, exported_bluetooth_prop)
 set_prop(bluetooth, pan_result_prop)
 
 allow bluetooth audioserver_service:service_manager find;
diff --git a/private/compat/26.0/26.0.ignore.cil b/private/compat/26.0/26.0.ignore.cil
index 3e22734..ab58dda 100644
--- a/private/compat/26.0/26.0.ignore.cil
+++ b/private/compat/26.0/26.0.ignore.cil
@@ -11,6 +11,7 @@
     blank_screen
     blank_screen_exec
     blank_screen_tmpfs
+    bluetooth_a2dp_offload_prop
     bpfloader
     bpfloader_exec
     broadcastradio_service
@@ -18,6 +19,7 @@
     crossprofileapps_service
     e2fs
     e2fs_exec
+    exported_bluetooth_prop
     exported_config_prop
     exported_dalvik_prop
     exported_default_prop
@@ -31,6 +33,7 @@
     exported_system_prop
     exported_system_radio_prop
     exported_vold_prop
+    exported_wifi_prop
     exported2_config_prop
     exported2_default_prop
     exported2_radio_prop
diff --git a/private/compat/27.0/27.0.ignore.cil b/private/compat/27.0/27.0.ignore.cil
index efc0166..493ac31 100644
--- a/private/compat/27.0/27.0.ignore.cil
+++ b/private/compat/27.0/27.0.ignore.cil
@@ -10,6 +10,7 @@
     blank_screen_exec
     blank_screen_tmpfs
     bootloader_boot_reason_prop
+    bluetooth_a2dp_offload_prop
     bpfloader
     bpfloader_exec
     cgroup_bpf
@@ -22,6 +23,7 @@
     exported3_default_prop
     exported3_radio_prop
     exported3_system_prop
+    exported_bluetooth_prop
     exported_config_prop
     exported_dalvik_prop
     exported_default_prop
@@ -35,6 +37,7 @@
     exported_system_prop
     exported_system_radio_prop
     exported_vold_prop
+    exported_wifi_prop
     fingerprint_vendor_data_file
     fs_bpf
     hal_authsecret_hwservice
diff --git a/private/priv_app.te b/private/priv_app.te
index 0841c41..99397a5 100644
--- a/private/priv_app.te
+++ b/private/priv_app.te
@@ -149,6 +149,7 @@
 dontaudit priv_app sysfs:dir read;
 dontaudit priv_app sysfs_android_usb:file read;
 dontaudit priv_app wifi_prop:file read;
+dontaudit priv_app { wifi_prop exported_wifi_prop }:file read;
 
 # allow privileged apps to use UDP sockets provided by the system server but not
 # modify them other than to connect
diff --git a/private/system_app.te b/private/system_app.te
index b2f8376..eb7e050 100644
--- a/private/system_app.te
+++ b/private/system_app.te
@@ -31,9 +31,11 @@
 allow system_app icon_file:file r_file_perms;
 
 # Write to properties
+set_prop(system_app, bluetooth_a2dp_offload_prop)
 set_prop(system_app, bluetooth_prop)
 set_prop(system_app, debug_prop)
 set_prop(system_app, system_prop)
+set_prop(system_app, exported_bluetooth_prop)
 set_prop(system_app, exported_system_prop)
 set_prop(system_app, exported2_system_prop)
 set_prop(system_app, exported3_system_prop)
diff --git a/private/webview_zygote.te b/private/webview_zygote.te
index c9a401a..c41f9cb 100644
--- a/private/webview_zygote.te
+++ b/private/webview_zygote.te
@@ -131,4 +131,8 @@
 
 # Do not allow access to Bluetooth-related system properties.
 # neverallow rules for Bluetooth-related data files are listed above.
-neverallow webview_zygote bluetooth_prop:file create_file_perms;
+neverallow webview_zygote {
+  bluetooth_a2dp_offload_prop
+  bluetooth_prop
+  exported_bluetooth_prop
+}:file create_file_perms;
diff --git a/private/zygote.te b/private/zygote.te
index 0a1a7c6..4f26bd0 100644
--- a/private/zygote.te
+++ b/private/zygote.te
@@ -136,4 +136,8 @@
 }:file no_x_file_perms;
 
 # Do not allow access to Bluetooth-related system properties and files
-neverallow zygote bluetooth_prop:file create_file_perms;
+neverallow zygote {
+  bluetooth_a2dp_offload_prop
+  bluetooth_prop
+  exported_bluetooth_prop
+}:file create_file_perms;