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;
|
|
|
|
|
|
|
|
# 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 self:{ tcp_socket udp_socket } *;
|
|
|
|
allow drmserver port:tcp_socket name_connect;
|
|
|
|
allow drmserver tee_device:chr_file rw_file_perms;
|
|
|
|
allow drmserver platform_app_data_file:file { read write getattr };
|
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)
|