1*e4a36f41SAndroid Build Coastguard Workertypeattribute dhcp coredomain; 2*e4a36f41SAndroid Build Coastguard Worker 3*e4a36f41SAndroid Build Coastguard Workerinit_daemon_domain(dhcp) 4*e4a36f41SAndroid Build Coastguard Workertype_transition dhcp system_data_file:{ dir file } dhcp_data_file; 5*e4a36f41SAndroid Build Coastguard Worker 6*e4a36f41SAndroid Build Coastguard Workerset_prop(dhcp, dhcp_prop) 7*e4a36f41SAndroid Build Coastguard Workerset_prop(dhcp, pan_result_prop) 8*e4a36f41SAndroid Build Coastguard Worker 9*e4a36f41SAndroid Build Coastguard Workernet_domain(dhcp) 10*e4a36f41SAndroid Build Coastguard Worker 11*e4a36f41SAndroid Build Coastguard Workerallow dhcp cgroup:dir { create write add_name }; 12*e4a36f41SAndroid Build Coastguard Workerallow dhcp cgroup_v2:dir { create write add_name }; 13*e4a36f41SAndroid Build Coastguard Workerallow dhcp self:global_capability_class_set { setgid setuid net_admin net_raw net_bind_service }; 14*e4a36f41SAndroid Build Coastguard Workerallow dhcp self:packet_socket create_socket_perms_no_ioctl; 15*e4a36f41SAndroid Build Coastguard Workerallow dhcp self:netlink_route_socket nlmsg_write; 16*e4a36f41SAndroid Build Coastguard Workerallow dhcp shell_exec:file rx_file_perms; 17*e4a36f41SAndroid Build Coastguard Workerallow dhcp system_file:file rx_file_perms; 18*e4a36f41SAndroid Build Coastguard Workernot_full_treble(`allow dhcp vendor_file:file rx_file_perms;') 19*e4a36f41SAndroid Build Coastguard Worker 20*e4a36f41SAndroid Build Coastguard Worker# dhcpcd runs dhcpcd-hooks/*, which runs getprop / setprop (toolbox_exec) 21*e4a36f41SAndroid Build Coastguard Workerallow dhcp toolbox_exec:file rx_file_perms; 22*e4a36f41SAndroid Build Coastguard Worker 23*e4a36f41SAndroid Build Coastguard Worker# For /proc/sys/net/ipv4/conf/*/promote_secondaries 24*e4a36f41SAndroid Build Coastguard Workerallow dhcp proc_net_type:file write; 25*e4a36f41SAndroid Build Coastguard Worker 26*e4a36f41SAndroid Build Coastguard Workerallow dhcp dhcp_data_file:dir create_dir_perms; 27*e4a36f41SAndroid Build Coastguard Workerallow dhcp dhcp_data_file:file create_file_perms; 28*e4a36f41SAndroid Build Coastguard Worker 29*e4a36f41SAndroid Build Coastguard Worker# PAN connections 30*e4a36f41SAndroid Build Coastguard Workerallow dhcp netd:fd use; 31*e4a36f41SAndroid Build Coastguard Workerallow dhcp netd:fifo_file rw_file_perms; 32*e4a36f41SAndroid Build Coastguard Workerallow dhcp netd:{ dgram_socket_class_set unix_stream_socket } { read write }; 33*e4a36f41SAndroid Build Coastguard Workerallow dhcp netd:{ netlink_kobject_uevent_socket netlink_route_socket netlink_nflog_socket } { read write }; 34