# Copyright (c) 2024 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. developer_only(` allow mediatool sh:fd { use }; allow mediatool medialibrary_hap:fd { use }; allow mediatool chip_prod_file:dir { search }; allow mediatool debug_param:file { read open map }; allow mediatool dev_unix_socket:dir { search }; allow mediatool hdcd:fd { use }; allow mediatool persist_param:file { read open map }; allow mediatool persist_sys_param:file { read open map }; allow mediatool samgr:binder { call transfer }; allow mediatool sys_prod_file:dir { search }; allow mediatool system_usr_file:dir { search getattr }; allow mediatool tty_device:chr_file { read write }; allow mediatool dev_ptmx:chr_file { read write }; allow mediatool devpts:chr_file { read write }; allow mediatool system_usr_file:file { read getattr open map }; allow mediatool sa_storage_manager_service:samgr_class { get }; allow mediatool storage_manager:binder { call }; allow mediatool mediatool:unix_dgram_socket { getopt setopt }; allow mediatool hiview:unix_dgram_socket { sendto }; allow mediatool sa_foundation_abilityms:samgr_class { get }; allow mediatool foundation:binder { call transfer }; allow mediatool medialibrary_hap:binder { call transfer }; allow mediatool mimetype_file:file { read open getattr }; allow mediatool devpts:chr_file { ioctl }; allow mediatool hdcd:fifo_file { read write }; allow mediatool data_file:dir { search }; allow mediatool data_local:dir { search }; allow mediatool data_local_tmp:dir { search getattr write add_name create }; allow mediatool data_local_tmp:file { write create open }; allow mediatool data_user_file:file { getattr read }; allow mediatool sys_param:file { read open }; allow mediatool samgr:file { read open write }; allow mediatool hmdfs:file { read getattr }; allowxperm mediatool devpts:chr_file ioctl 0x5413; allow foundation mediatool:binder { call transfer }; allow samgr mediatool:dir { search }; allow samgr mediatool:file { read open }; allow samgr mediatool:process { getattr }; allow samgr mediatool:binder { call transfer }; allow medialibrary_hap mediatool:binder { transfer }; domain_auto_transition_pattern(sh, mediatool_exec, mediatool); ')