1type cnd, domain; 2type cnd_exec, exec_type, vendor_file_type, file_type; 3file_type_auto_trans(cnd, socket_device, cnd_socket); 4 5# cnd is started by init, type transit from init domain to cnd domain 6init_daemon_domain(cnd) 7 8allow cnd self:capability { net_bind_service }; 9wakelock_use(cnd) 10 11allow cnd self:udp_socket create_socket_perms; 12allowxperm cnd self:udp_socket ioctl SIOCGIFMTU; 13 14allow cnd sysfs_timestamp_switch:file r_file_perms; 15r_dir_file(cnd, sysfs_msm_subsys) 16r_dir_file(cnd, sysfs_diag) 17r_dir_file(cnd, sysfs_soc) 18 19allow cnd proc_meminfo:file r_file_perms; 20 21set_prop(cnd, cnd_prop) 22 23allow cnd self:socket create_socket_perms; 24allowxperm cnd self:socket ioctl msm_sock_ipc_ioctls; 25 26# To register cnd to hwbinder 27add_hwservice(cnd, hal_cne_hwservice) 28hwbinder_use(cnd) 29get_prop(cnd, hwservicemanager_prop) 30binder_call(cnd, dataservice_app) 31binder_call(cnd, ims) 32 33userdebug_or_eng(` 34 allow cnd diag_device:chr_file rw_file_perms; 35') 36dontaudit cnd diag_device:chr_file rw_file_perms; 37 38get_prop(cnd, wifi_hal_prop) 39