blob: 6cf8e491183b6a1fab99939a87d22a32f2f9fef5 [file] [log] [blame]
David Anderson9bae5152024-09-19 20:36:11 -07001### ADB daemon common rules.
2### Put things here that are needed for both adbd proper and adbd in trade-in mode.
3
4# Connect to mdnsd via mdnsd socket.
5unix_socket_connect(adbd, mdnsd, mdnsd)
6
7# adbd probes for vsock support. Do not generate denials when
8# this occurs. (b/123569840)
9dontaudit { adbd } self:{ socket vsock_socket } create;
10
11# Allow adbd inside vm to forward vm's vsock.
12allow { adbd } self:vsock_socket { create_socket_perms_no_ioctl listen accept };
13
14# Access device logging gating property
15get_prop(adbd, device_logging_prop)
16
17# Use a pseudo tty.
18allow { adbd } devpts:chr_file rw_file_perms;
19
20# adb push/pull /data/local/tmp.
21allow { adbd } shell_data_file:dir create_dir_perms;
22allow { adbd } shell_data_file:file create_file_perms;
23
24# Read persist.adb.tls_server.enable property
25get_prop(adbd, system_adbd_prop)
26
27# Read whether or not Test Harness Mode is enabled
28get_prop(adbd, test_harness_prop)
29
30# Set service.adb.tcp.port, service.adb.tls.port, persist.adb.wifi.* properties
31set_prop(adbd, adbd_prop)
32set_prop(adbd, adbd_config_prop)
33
34# Read device's serial number from system properties
35get_prop(adbd, serialno_prop)