2012-01-04 18:33:27 +01:00
|
|
|
# servicemanager - the Binder context manager
|
2016-11-26 02:37:30 +01:00
|
|
|
type servicemanager, domain, mlstrustedsubject;
|
2012-01-04 18:33:27 +01:00
|
|
|
type servicemanager_exec, exec_type, file_type;
|
|
|
|
|
2013-10-29 19:42:39 +01:00
|
|
|
# Note that we do not use the binder_* macros here.
|
|
|
|
# servicemanager is unique in that it only provides
|
|
|
|
# name service (aka context manager) for Binder.
|
|
|
|
# As such, it only ever receives and transfers other references
|
|
|
|
# created by other domains. It never passes its own references
|
|
|
|
# or initiates a Binder IPC.
|
|
|
|
allow servicemanager self:binder set_context_mgr;
|
2017-04-25 18:27:54 +02:00
|
|
|
allow servicemanager {
|
|
|
|
domain
|
|
|
|
-init
|
2018-02-09 20:31:56 +01:00
|
|
|
-vendor_init
|
2017-04-25 18:27:54 +02:00
|
|
|
-hwservicemanager
|
|
|
|
-vndservicemanager
|
|
|
|
}:binder transfer;
|
2014-06-06 00:52:02 +02:00
|
|
|
|
2017-03-24 20:24:43 +01:00
|
|
|
allow servicemanager service_contexts_file:file r_file_perms;
|
2017-09-26 21:58:29 +02:00
|
|
|
# nonplat_service_contexts only accessible on non full-treble devices
|
|
|
|
not_full_treble(`allow servicemanager nonplat_service_contexts_file:file r_file_perms;')
|
2016-09-10 01:27:17 +02:00
|
|
|
|
2014-06-06 00:52:02 +02:00
|
|
|
# Check SELinux permissions.
|
|
|
|
selinux_check_access(servicemanager)
|