2012-01-04 18:33:27 +01:00
|
|
|
# drmserver - DRM service
|
|
|
|
type drmserver, domain;
|
|
|
|
type drmserver_exec, exec_type, file_type;
|
|
|
|
|
|
|
|
init_daemon_domain(drmserver)
|
2013-10-29 19:42:35 +01:00
|
|
|
typeattribute drmserver mlstrustedsubject;
|
|
|
|
|
2014-02-24 21:06:11 +01:00
|
|
|
net_domain(drmserver)
|
|
|
|
|
2013-10-29 19:42:35 +01:00
|
|
|
# Perform Binder IPC to system server.
|
|
|
|
binder_use(drmserver)
|
|
|
|
binder_call(drmserver, system_server)
|
|
|
|
binder_call(drmserver, appdomain)
|
|
|
|
binder_service(drmserver)
|
|
|
|
|
|
|
|
# Perform Binder IPC to mediaserver
|
|
|
|
binder_call(drmserver, mediaserver)
|
|
|
|
|
|
|
|
allow drmserver sdcard_type:dir search;
|
|
|
|
allow drmserver drm_data_file:dir create_dir_perms;
|
|
|
|
allow drmserver drm_data_file:file create_file_perms;
|
|
|
|
allow drmserver tee_device:chr_file rw_file_perms;
|
2014-02-04 17:36:41 +01:00
|
|
|
allow drmserver app_data_file:file { read write getattr };
|
2013-10-29 19:42:35 +01:00
|
|
|
allow drmserver sdcard_type:file { read write getattr };
|
2014-01-31 22:20:20 +01:00
|
|
|
r_dir_file(drmserver, efs_file)
|
2013-10-29 19:42:35 +01:00
|
|
|
|
2014-02-04 22:49:01 +01:00
|
|
|
type drmserver_socket, file_type;
|
|
|
|
|
|
|
|
# /data/app/tlcd_sock socket file.
|
|
|
|
# Clearly, /data/app is the most logical place to create a socket. Not.
|
|
|
|
allow drmserver apk_data_file:dir rw_dir_perms;
|
|
|
|
type_transition drmserver apk_data_file:sock_file drmserver_socket;
|
|
|
|
allow drmserver drmserver_socket:sock_file create_file_perms;
|
2013-10-29 19:42:35 +01:00
|
|
|
allow drmserver tee:unix_stream_socket connectto;
|
2014-02-04 22:49:01 +01:00
|
|
|
# Delete old socket file if present.
|
|
|
|
allow drmserver apk_data_file:sock_file unlink;
|
2014-01-06 21:39:19 +01:00
|
|
|
|
|
|
|
# After taking a video, drmserver looks at the video file.
|
|
|
|
r_dir_file(drmserver, media_rw_data_file)
|
2014-03-13 20:35:46 +01:00
|
|
|
|
|
|
|
# Read resources from open apk files passed over Binder.
|
|
|
|
allow drmserver apk_data_file:file { read getattr };
|
|
|
|
allow drmserver asec_apk_file:file { read getattr };
|
2014-03-27 14:45:26 +01:00
|
|
|
|
|
|
|
# Read /data/data/com.android.providers.telephony files passed over Binder.
|
|
|
|
allow drmserver radio_data_file:file { read getattr };
|
2014-06-06 00:52:02 +02:00
|
|
|
|
2014-09-16 19:00:50 +02:00
|
|
|
# /oem access
|
2014-10-11 01:11:03 +02:00
|
|
|
allow drmserver oemfs:dir search;
|
2014-09-16 19:00:50 +02:00
|
|
|
allow drmserver oemfs:file r_file_perms;
|
2014-09-16 22:04:06 +02:00
|
|
|
|
2014-12-12 01:01:27 +01:00
|
|
|
allow drmserver drmserver_service:service_manager { add find };
|
2014-12-17 00:45:26 +01:00
|
|
|
allow drmserver tmp_system_server_service:service_manager find;
|
2014-07-26 00:19:47 +02:00
|
|
|
|
2015-03-03 20:20:15 +01:00
|
|
|
service_manager_local_audit_domain(drmserver)
|
|
|
|
auditallow drmserver {
|
|
|
|
tmp_system_server_service
|
|
|
|
-permission_service
|
|
|
|
}:service_manager find;
|
|
|
|
|
2014-07-02 21:42:59 +02:00
|
|
|
selinux_check_access(drmserver)
|