1*2d543d20SAndroid Build Coastguard Workermodule my_module 1.0; 2*2d543d20SAndroid Build Coastguard Worker 3*2d543d20SAndroid Build Coastguard Workerrequire { 4*2d543d20SAndroid Build Coastguard Worker bool secure_mode; 5*2d543d20SAndroid Build Coastguard Worker type system_t, sysadm_t, file_t; 6*2d543d20SAndroid Build Coastguard Worker attribute domain; 7*2d543d20SAndroid Build Coastguard Worker role system_r; 8*2d543d20SAndroid Build Coastguard Worker class file {read write}; 9*2d543d20SAndroid Build Coastguard Worker 10*2d543d20SAndroid Build Coastguard Worker} 11*2d543d20SAndroid Build Coastguard Worker 12*2d543d20SAndroid Build Coastguard Workertype new_t, domain; 13*2d543d20SAndroid Build Coastguard Workerrole system_r types new_t; 14*2d543d20SAndroid Build Coastguard Worker 15*2d543d20SAndroid Build Coastguard Workerallow system_t file_t : file { read write }; 16*2d543d20SAndroid Build Coastguard Worker 17*2d543d20SAndroid Build Coastguard Workerif (secure_mode) 18*2d543d20SAndroid Build Coastguard Worker{ 19*2d543d20SAndroid Build Coastguard Worker allow sysadm_t file_t : file { read write }; 20*2d543d20SAndroid Build Coastguard Worker} 21