1type subsystem_ramdump_exec, exec_type, vendor_file_type, file_type;
2
3userdebug_or_eng(`
4  type subsystem_ramdump, domain;
5
6  init_daemon_domain(subsystem_ramdump);
7
8  allow subsystem_ramdump device:dir r_dir_perms;
9  allow subsystem_ramdump ramdump_device:chr_file r_file_perms;
10
11  r_dir_file(subsystem_ramdump, sysfs_type);
12
13  allow subsystem_ramdump ramdump_vendor_data_file:dir rw_dir_perms;
14  allow subsystem_ramdump ramdump_vendor_data_file:file create_file_perms;
15
16  allow subsystem_ramdump wifidump_vendor_data_file:dir { r_dir_perms remove_name write };
17  allow subsystem_ramdump wifidump_vendor_data_file:file { r_file_perms rename setattr unlink };
18  allow subsystem_ramdump diag_device:chr_file rw_file_perms;
19  allow subsystem_ramdump self:socket create_socket_perms;
20  allowxperm subsystem_ramdump self:socket ioctl msm_sock_ipc_ioctls;
21  allow subsystem_ramdump self:capability { fowner };
22
23  allow subsystem_ramdump ssr_log_file:dir rw_dir_perms;
24  allow subsystem_ramdump ssr_log_file:file create_file_perms;
25
26  allow subsystem_ramdump proc_sysrq:file w_file_perms;
27
28  set_prop(subsystem_ramdump, vendor_ssr_prop);
29  get_prop(subsystem_ramdump, vendor_ramdump_prop);
30
31  dontaudit subsystem_ramdump kernel:system module_request;
32')
33