75806ef3c5
Ideally, public should only contain APIs (types / attributes) for vendor. The other statements like allow/neverallow/typeattributes are regarded as implementation detail for platform and should be in private. Bug: 232023812 Test: m selinux_policy Test: diff <(git diff --staged | grep "^-" | cut -b2- | sort) \ <(git diff --staged | grep "^+" | cut -b2- | sort) Test: remove comments on plat_sepolicy.cil, replace base_typeattr_* to base_typeattr and then compare old and new plat_sepolicy.cil Change-Id: I5e7d2da4465ab0216de6bacdf03077d37f6ffe12
47 lines
2.2 KiB
Text
47 lines
2.2 KiB
Text
# HwBinder IPC from client to server, and callbacks
|
|
binder_call(hal_telephony_client, hal_telephony_server)
|
|
binder_call(hal_telephony_server, hal_telephony_client)
|
|
|
|
hal_attribute_hwservice(hal_telephony, hal_telephony_hwservice)
|
|
hal_attribute_service(hal_telephony, hal_radio_service)
|
|
|
|
allowxperm hal_telephony_server self:udp_socket ioctl priv_sock_ioctls;
|
|
|
|
allow hal_telephony_server self:netlink_route_socket nlmsg_write;
|
|
allow hal_telephony_server self:global_capability_class_set { setpcap setgid setuid net_admin net_raw };
|
|
allow hal_telephony_server cgroup:dir create_dir_perms;
|
|
allow hal_telephony_server cgroup:{ file lnk_file } r_file_perms;
|
|
allow hal_telephony_server cgroup_v2:dir create_dir_perms;
|
|
allow hal_telephony_server cgroup_v2:{ file lnk_file } r_file_perms;
|
|
allow hal_telephony_server radio_device:chr_file rw_file_perms;
|
|
allow hal_telephony_server radio_device:blk_file r_file_perms;
|
|
allow hal_telephony_server efs_file:dir create_dir_perms;
|
|
allow hal_telephony_server efs_file:file create_file_perms;
|
|
allow hal_telephony_server vendor_shell_exec:file rx_file_perms;
|
|
allow hal_telephony_server bluetooth_efs_file:file r_file_perms;
|
|
allow hal_telephony_server bluetooth_efs_file:dir r_dir_perms;
|
|
|
|
# property service
|
|
get_prop(hal_telephony_server, telephony_config_prop)
|
|
set_prop(hal_telephony_server, radio_control_prop)
|
|
set_prop(hal_telephony_server, radio_prop)
|
|
set_prop(hal_telephony_server, telephony_status_prop)
|
|
|
|
allow hal_telephony_server tty_device:chr_file rw_file_perms;
|
|
|
|
# Allow hal_telephony_server to create and use netlink sockets.
|
|
allow hal_telephony_server self:netlink_socket create_socket_perms_no_ioctl;
|
|
allow hal_telephony_server self:netlink_generic_socket create_socket_perms_no_ioctl;
|
|
allow hal_telephony_server self:netlink_kobject_uevent_socket create_socket_perms_no_ioctl;
|
|
|
|
# Access to wake locks
|
|
wakelock_use(hal_telephony_server)
|
|
|
|
r_dir_file(hal_telephony_server, proc_net_type)
|
|
r_dir_file(hal_telephony_server, sysfs_type)
|
|
|
|
# granting the ioctl permission for hal_telephony_server should be device specific
|
|
allow hal_telephony_server self:socket create_socket_perms_no_ioctl;
|
|
|
|
# Allow AIDL HAL shim to call HIDL HAL implementation
|
|
binder_call(hal_telephony_server, hal_telephony_server)
|