blob: e740b23cadccc00d7f4b2d7a3e96124176491dc9 [file] [log] [blame]
Abir Ghosh2cd6e6e2017-02-08 15:08:55 +05301# Copyright (c) 2017 Linux Foundation. All rights reserved.
Biswajit Paul28439f92015-07-15 13:28:27 -07002#
3# Redistribution and use in source and binary forms, with or without
4# modification, are permitted provided that the following conditions are
5# met:
6# * Redistributions of source code must retain the above copyright
7# notice, this list of conditions and the following disclaimer.
8# * Redistributions in binary form must reproduce the above
9# copyright notice, this list of conditions and the following
10# disclaimer in the documentation and/or other materials provided
11# with the distribution.
12# * Neither the name of The Linux Foundation nor the names of its
13# contributors may be used to endorse or promote products derived
14# from this software without specific prior written permission.
15#
16# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED
17# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
18# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT
19# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS
20# BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
21# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
22# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
23# BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
24# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
25# OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
26# IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
27
28#qfp daemon for ultrasonic fingerprint sensor
Biswajit Paul6786a922017-03-16 11:53:53 -070029type qfp-daemon, domain;
Ravi Kumar Siddojigaric7def122017-06-13 00:49:19 +053030type qfp-daemon_exec, exec_type, vendor_file_type, file_type;
Biswajit Paul28439f92015-07-15 13:28:27 -070031
Abir Ghoshdcfb5572017-05-31 15:25:06 +053032hal_server_domain(qfp-daemon, hal_fingerprint)
Biswajit Paul28439f92015-07-15 13:28:27 -070033init_daemon_domain(qfp-daemon)
34
Ravi Kumar Siddojigaric7def122017-06-13 00:49:19 +053035#binder_call(qfp-daemon, servicemanager)
Biswajit Paul28439f92015-07-15 13:28:27 -070036binder_call(qfp-daemon, system_app)
Abir Ghosh2cd6e6e2017-02-08 15:08:55 +053037binder_call(qfp-daemon, fps_hal)
Ravi Kumar Siddojigaric7def122017-06-13 00:49:19 +053038#binder_use(qfp-daemon)
Biswajit Paul28439f92015-07-15 13:28:27 -070039
40allow qfp-daemon qfp-daemon_data_file:dir { rw_dir_perms setattr };
41allow qfp-daemon qfp-daemon_data_file:file create_file_perms;
42
43# Access to tee_device
44allow qfp-daemon tee_device:chr_file rw_file_perms;
45
Abir Ghosh2cd6e6e2017-02-08 15:08:55 +053046# Access QFP Android Proxy
Ravi Kumar Siddojigaric7def122017-06-13 00:49:19 +053047#allow qfp-daemon qfp_proxy_service:service_manager find;
Abir Ghosh2cd6e6e2017-02-08 15:08:55 +053048
Biswajit Paul28439f92015-07-15 13:28:27 -070049# Read system property
50allow qfp-daemon property_socket:sock_file write;
51
52# RW to device driver
Amal Paul6f621702015-07-19 22:43:13 -070053allow qfp-daemon qbt1000_device:chr_file rw_file_perms;
Biswajit Paul28439f92015-07-15 13:28:27 -070054
55# R dir perms for firmware dir
56r_dir_file(qfp-daemon, firmware_file)
Lior Barenboim77754242015-08-25 09:34:05 +030057
Abir Ghosh2cd6e6e2017-02-08 15:08:55 +053058# R dir perms for persist qc_senseid dir
59r_dir_file(qfp-daemon, persist_file)
60r_dir_file(qfp-daemon, persist_qti_fp_file)
61
Lior Barenboimffc507b2015-10-07 13:40:08 +030062# Allow listing input devices and sending input events
63allow qfp-daemon input_device:chr_file rw_file_perms;
64allow qfp-daemon input_device:dir r_dir_perms;
Biswajit Paul277acbb2016-07-20 12:02:14 -070065
66#diag
67userdebug_or_eng(`
68 diag_use(qfp-daemon)
69')