blob: 00caf25c9dad86d10af62fd82fbaa51a3ddf462e [file] [log] [blame]
Nick Kralevich9f6af082014-07-02 16:18:16 -07001# service flash_recovery in init.rc
Nick Kralevich0c8101b2017-01-06 16:54:25 -08002type install_recovery, domain;
Nick Kralevich5e372712018-09-27 10:21:37 -07003type install_recovery_exec, system_file_type, exec_type, file_type;
Nick Kralevich9f6af082014-07-02 16:18:16 -07004
Nick Kralevich9f6af082014-07-02 16:18:16 -07005# /system/bin/install-recovery.sh is a shell script.
6# Needs to execute /system/bin/sh
7allow install_recovery shell_exec:file rx_file_perms;
8
9# Execute /system/bin/applypatch
10allow install_recovery system_file:file rx_file_perms;
Jeff Vander Stoep2db1cd42017-04-21 09:33:39 -070011not_full_treble(`allow install_recovery vendor_file:file rx_file_perms;')
Nick Kralevich9f6af082014-07-02 16:18:16 -070012
Stephen Smalleya3c97a72015-08-25 11:38:29 -040013allow install_recovery toolbox_exec:file rx_file_perms;
Stephen Smalleya3c97a72015-08-25 11:38:29 -040014
Nick Kralevicha8e073c2015-02-27 17:39:09 -080015# Update the recovery block device based off a diff of the boot block device
Nick Kralevich9f6af082014-07-02 16:18:16 -070016allow install_recovery block_device:dir search;
Nick Kralevicha8e073c2015-02-27 17:39:09 -080017allow install_recovery boot_block_device:blk_file r_file_perms;
Stephen Smalley206b1a62014-09-30 12:53:12 -040018allow install_recovery recovery_block_device:blk_file rw_file_perms;
Nick Kralevich9f6af082014-07-02 16:18:16 -070019
Nick Kralevich9f6af082014-07-02 16:18:16 -070020# Write to /proc/sys/vm/drop_caches
Jeff Sharkeyc9605962015-05-14 20:55:31 -070021allow install_recovery proc_drop_caches:file w_file_perms;