1# ==============================================
2# MTK Policy Rule
3# ==============================================
4
5# Purpose : for access storage file
6allow netdiag sdcard_type:dir create_dir_perms;
7allow netdiag sdcard_type:file create_file_perms;
8allow netdiag net_data_file:file r_file_perms;
9allow netdiag net_data_file:dir search;
10allow netdiag storage_file:dir search;
11allow netdiag storage_file:lnk_file read;
12allow netdiag mnt_user_file:dir search;
13allow netdiag mnt_user_file:lnk_file read;
14allow netdiag platform_app:dir search;
15allow netdiag untrusted_app:dir search;
16allow netdiag mnt_media_rw_file:dir search;
17allow netdiag vfat:dir create_dir_perms;
18allow netdiag vfat:file create_file_perms;
19allow netdiag tmpfs:lnk_file read;
20
21# purpose: allow netdiag to access storage in new version
22allow netdiag media_rw_data_file:file  { create_file_perms };
23allow netdiag media_rw_data_file:dir { create_dir_perms };
24
25# purpose: read ip address
26allow netdiag self:netlink_route_socket nlmsg_readpriv;