Home | History | Annotate | Download | only in sepolicy
      1 # goldfish-setup service: runs init.goldfish.sh script
      2 type goldfish_setup, domain, domain_deprecated;
      3 type goldfish_setup_exec, exec_type, file_type;
      4 
      5 init_daemon_domain(goldfish_setup)
      6 
      7 # Inherit open file to shell (interpreter) for script.
      8 allow goldfish_setup shell_exec:file rx_file_perms;
      9 
     10 # Run ifconfig, route commands to configure interfaces and routes.
     11 allow goldfish_setup system_file:file execute_no_trans;
     12 allow goldfish_setup toolbox_exec:file rx_file_perms;
     13 allow goldfish_setup self:capability { net_admin net_raw };
     14 allow goldfish_setup self:udp_socket create_socket_perms;
     15 
     16 net_domain(goldfish_setup)
     17 
     18 # Set net.eth0.dns*, debug.sf.nobootanimation
     19 set_prop(goldfish_setup, system_prop)
     20 set_prop(goldfish_setup, debug_prop)
     21 
     22 # Set ro.radio.noril
     23 set_prop(goldfish_setup, radio_noril_prop)
     24 
     25 # Stop ril-daemon service (by setting ctl.stop to ril-daemon, which
     26 # transforms to a permission check on ctl.ril-daemon).
     27 set_prop(goldfish_setup, ctl_rildaemon_prop)
     28