Brent Hronik | ccc2903 | 2013-12-17 12:45:57 -0700 | [diff] [blame] | 1 | #must be defined for file_contexts |
| 2 | type qmi_ping_exec, exec_type, file_type; |
| 3 | |
| 4 | userdebug_or_eng(` |
| 5 | type qmi_ping, domain; |
| 6 | domain_auto_trans(shell, qmi_ping_exec, qmi_ping) |
Brent Hronik | ccc2903 | 2013-12-17 12:45:57 -0700 | [diff] [blame] | 7 | domain_auto_trans(adbd, qmi_ping_exec, qmi_ping) |
| 8 | #test launched from pseudo terminal, so output goes there |
| 9 | allow qmi_ping devpts:chr_file {read write ioctl getattr}; |
| 10 | #to access smem logs |
| 11 | allow qmi_ping smem_log_device:chr_file {read write open ioctl}; |
| 12 | #to enable qmuxd interface apis to access diag |
| 13 | allow qmi_ping diag_device:chr_file {read write open ioctl}; |
| 14 | #enable accessing the path where qmuxds named sockets are present |
Brent Hronik | ccc2903 | 2013-12-17 12:45:57 -0700 | [diff] [blame] | 15 | #to interface with qmuxd through unix sockets |
Brent Hronik | ccc2903 | 2013-12-17 12:45:57 -0700 | [diff] [blame] | 16 | #to use socket interface to ipc router |
| 17 | allow qmi_ping qmi_ping:socket {create bind read write ioctl setopt}; |
| 18 | #enable running test as root user => privileged process |
| 19 | #enable privileged processes to bypass permission checks |
| 20 | allow qmi_ping qmi_ping:capability {dac_override dac_read_search setgid setuid fsetid}; |
| 21 | #QCCI calls qmuxd API. The API will internally require this |
Biswajit Paul | 64f83f6 | 2014-10-13 14:36:16 -0700 | [diff] [blame] | 22 | qmux_socket(qmi_ping); |
Brent Hronik | ccc2903 | 2013-12-17 12:45:57 -0700 | [diff] [blame] | 23 | ') |