Skip to content
Snippets Groups Projects
  • Stephen Smalley's avatar
    28afdd92
    Deduplicate binder_call rules. · 28afdd92
    Stephen Smalley authored
    
    A number of binder_call rules are duplicated by other rules
    written in terms of attributes/sets (e.g. appdomain, binderservicedomain).
    Get rid of the duplicates.
    
    Also use binder_use() in racoon.te rather than manually writing the
    base rule for communicating with the servicemanager.
    
    Change-Id: I5a459cc2154b1466bcde6eccef253dfcdcb44e0a
    Signed-off-by: default avatarStephen Smalley <sds@tycho.nsa.gov>
    28afdd92
    History
    Deduplicate binder_call rules.
    Stephen Smalley authored
    
    A number of binder_call rules are duplicated by other rules
    written in terms of attributes/sets (e.g. appdomain, binderservicedomain).
    Get rid of the duplicates.
    
    Also use binder_use() in racoon.te rather than manually writing the
    base rule for communicating with the servicemanager.
    
    Change-Id: I5a459cc2154b1466bcde6eccef253dfcdcb44e0a
    Signed-off-by: default avatarStephen Smalley <sds@tycho.nsa.gov>
racoon.te 786 B
# IKE key management daemon
type racoon, domain;
permissive_or_unconfined(racoon)
type racoon_exec, exec_type, file_type;

init_daemon_domain(racoon)
typeattribute racoon mlstrustedsubject;

net_domain(racoon)

binder_use(racoon)
binder_call(racoon, keystore)

allow racoon tun_device:chr_file r_file_perms;
allow racoon cgroup:dir { add_name create };
allow racoon kernel:system module_request;

allow racoon self:key_socket create_socket_perms;
allow racoon self:tun_socket create_socket_perms;
allow racoon self:capability { net_admin net_bind_service net_raw setuid };

# XXX: should we give ip-up-vpn its own label (currently racoon domain)
allow racoon system_file:file rx_file_perms;
allow racoon vpn_data_file:file create_file_perms;
allow racoon vpn_data_file:dir w_dir_perms;