ttrss.te 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. policy_module(ttrss, 0.0.5)
  2. require {
  3. type etc_t;
  4. type httpd_sys_content_t;
  5. type shell_exec_t;
  6. }
  7. ########################################
  8. #
  9. # Declarations
  10. #
  11. attribute_role ttrss_roles;
  12. type ttrss_t;
  13. type ttrss_exec_t;
  14. init_system_domain(ttrss_t, ttrss_exec_t)
  15. ########################################
  16. #
  17. # Local policy
  18. #
  19. allow ttrss_t self:netlink_route_socket { bind create getattr nlmsg_read read write };
  20. allow ttrss_t self:tcp_socket { connect create getattr getopt read setopt write };
  21. allow ttrss_t self:udp_socket { connect create getattr read write setopt };
  22. allow ttrss_t self:unix_stream_socket { connect create read write };
  23. corenet_tcp_connect_generic_port(ttrss_t)
  24. corenet_tcp_connect_http_port(ttrss_t)
  25. files_read_etc_files(ttrss_t)
  26. miscfiles_read_generic_certs(ttrss_t)
  27. apache_manage_sys_content(ttrss_t)
  28. corecmd_check_exec_shell(ttrss_t)
  29. corecmd_exec_bin(ttrss_t)
  30. sysnet_read_config(ttrss_t)
  31. miscfiles_read_localization(ttrss_t)
  32. mysql_tcp_connect(ttrss_t)
  33. mysql_stream_connect(ttrss_t)
  34. allow ttrss_t etc_t:file map;
  35. allow ttrss_t httpd_sys_content_t:file map;
  36. corecmd_exec_shell(ttrss_t)
  37. allow ttrss_t shell_exec_t:file map;
  38. optional_policy(`
  39. cron_system_entry(ttrss_t, ttrss_exec_t)
  40. ')