1# Copyright (c) 2024 Huawei Device Co., Ltd.
2# Licensed under the Apache License, Version 2.0 (the "License");
3# you may not use this file except in compliance with the License.
4# You may obtain a copy of the License at
5#
6#     http://www.apache.org/licenses/LICENSE-2.0
7#
8# Unless required by applicable law or agreed to in writing, software
9# distributed under the License is distributed on an "AS IS" BASIS,
10# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11# See the License for the specific language governing permissions and
12# limitations under the License.
13
14type sharing_service, sadomain, domain;
15allow sharing_service foundation:binder { call transfer };
16allow sharing_service hilog_param:file { map read open };
17allow sharing_service media_service:binder { call };
18allow sharing_service net_param:file { map open read };
19allow sharing_service net_tcp_param:file { map open read };
20allow sharing_service ohos_param:file { map open read };
21allow sharing_service sa_accesstoken_manager_service:samgr_class { get };
22allow sharing_service sa_sharing_service:samgr_class { add };
23allow sharing_service sa_device_service_manager:samgr_class { get };
24allow sharing_service sa_foundation_dms:samgr_class { get };
25allow sharing_service security_param:file { map open read };
26allow sharing_service startup_param:file { map open read };
27allow sharing_service dev_unix_socket:dir { search };
28allow sharing_service debug_param:file { map open read };
29allow sharing_service sys_param:file { map open read };
30allow sharing_service persist_param:file { map open read };
31allow sharing_service persist_sys_param:file { map open read };
32allow sharing_service system_bin_file:dir { search };
33allow sharing_service system_core_hap_attr:binder { call transfer };
34allow sharing_service tracefs:dir { search };
35allow sharing_service dev_console_file:chr_file { read write };
36allow sharing_service tracefs_trace_marker_file:file { open write };
37allow sharing_service sa_memory_manager_service:samgr_class { get };
38allow sharing_service sa_audio_policy_service:samgr_class { get };
39allow sharing_service sa_media_service:samgr_class { get };
40allow sharing_service sa_softbus_service:samgr_class { get };
41allow sharing_service sa_foundation_devicemanager_service:samgr_class { get };
42allow sharing_service device_manager:binder { call transfer };
43allow sharing_service softbus_server:binder { call transfer };
44allow sharing_service softbus_server:fd { use };
45allow sharing_service softbus_server:tcp_socket { read write setopt shutdown };
46allow sharing_service media_service:binder { call transfer };
47allow sharing_service sharing_service:unix_dgram_socket { getopt setopt };
48allow sharing_service sysfs_devices_system_cpu:file { getattr read open };
49allow sharing_service sharing_service:udp_socket { write read bind create setopt getattr connect shutdown};
50allow sharing_service sharing_service:tcp_socket { write read bind create setopt getattr connect listen accept shutdown };
51allow sharing_service node:udp_socket { node_bind };
52allow sharing_service node:tcp_socket { node_bind };
53allow sharing_service  wifi_manager_service:binder { call transfer};
54allow wifi_manager_service sharing_service:binder { call transfer };
55allow sharing_service  resource_schedule_service:binder { call };
56allow sharing_service  sa_resource_schedule:samgr_class { get };
57allow sharing_service av_codec_service:binder { call transfer };
58allow sharing_service av_codec_service:fd { use };
59allow sharing_service codec_host:fd { use };
60allow sharing_service sa_av_codec_service:samgr_class { get };
61allow sharing_service sa_wifi_p2p_ability:samgr_class { get };
62allow sharing_service sa_sharing_service:samgr_class { get add };
63allow sharing_service sa_sharing_service_domain:samgr_class { get add };
64allow sharing_service arkcompiler_param:file { map open read };
65allow sharing_service dev_kmsg_file:chr_file { open read write };
66allow sharing_service tty_device:chr_file { open read write };
67allow sharing_service chip_prod_file:dir { search };
68allow sharing_service dev_ashmem_file:chr_file { open };
69allow foundation sharing_service:binder { call };
70allow sharing_service sa_pulseaudio_audio_service:samgr_class { get };
71allow sharing_service sa_media_monitor:samgr_class { get };
72allow sharing_service sa_foundation_bms:samgr_class { get };
73allow sharing_service audio_server:fd { use };
74allow sharing_service audio_server:binder { call transfer };
75allow sharing_service sa_render_service:samgr_class { get };
76allow sharing_service sa_powermgr_powermgr_service:samgr_class { get };
77allow sharing_service powermgr:binder { call };
78allow sharing_service render_service:binder { call };
79allow sharing_service render_service:fd { use };
80allow sharing_service sa_render_service:samgr_class { get };
81allow sharing_service render_service:binder { transfer };
82allow render_service sharing_service:binder { call };
83allow render_service sharing_service:binder { transfer };
84