diff --git a/policy/modules/system/systemd-homed.fc b/policy/modules/system/systemd-homed.fc index f626271e39..9c417e9e03 100644 --- a/policy/modules/system/systemd-homed.fc +++ b/policy/modules/system/systemd-homed.fc @@ -21,4 +21,5 @@ /var/lib/systemd/home -d gen_context(system_u:object_r:systemd_homed_library_dir_t,s0) HOME_DIR/\.identity -- gen_context(system_u:object_r:systemd_homed_record_t,s0) +HOME_DIR/\.identity-blob(/.*)? gen_context(system_u:object_r:systemd_homed_record_t,s0) HOME_ROOT/(.+)\.home -- gen_context(system_u:object_r:systemd_homed_crypto_luks_t,s0) diff --git a/policy/modules/system/systemd-homed.te b/policy/modules/system/systemd-homed.te index 461597e338..0cf5a2c47b 100644 --- a/policy/modules/system/systemd-homed.te +++ b/policy/modules/system/systemd-homed.te @@ -75,8 +75,11 @@ files_manage_isid_type_files(systemd_homed_t) fs_getattr_tmpfs(systemd_homed_t) # /var/cache/systemd/home +create_dirs_pattern(systemd_homed_t, systemd_homed_cache_t, systemd_homed_cache_t) +delete_dirs_pattern(systemd_homed_t, systemd_homed_cache_t, systemd_homed_cache_t) list_dirs_pattern(systemd_homed_t, systemd_homed_cache_t, systemd_homed_cache_t) -read_files_pattern(systemd_homed_t, systemd_homed_cache_t, systemd_homed_cache_t) +rename_dirs_pattern(systemd_homed_t, systemd_homed_cache_t, systemd_homed_cache_t) +delete_files_pattern(systemd_homed_t, systemd_homed_cache_t, systemd_homed_cache_t) # /var/lib/systemd/home manage_files_pattern(systemd_homed_t, systemd_homed_library_dir_t, systemd_homed_record_t) @@ -138,8 +141,8 @@ optional_policy(` ') optional_policy(` - systemd_manage_userdbd_runtime_sock_files(systemd_homed_t) - systemd_search_cache_dirs(systemd_homed_t) + systemd_manage_userdbd_runtime_sock_files(systemd_homed_t) + systemd_search_cache_dirs(systemd_homed_t) ') optional_policy(` @@ -147,13 +150,13 @@ optional_policy(` ') optional_policy(` - # labeled home directories - userdom_home_manager(systemd_homed_t) - userdom_manage_home_role(system_r, systemd_homed_t) + # labeled home directories + userdom_home_manager(systemd_homed_t) + userdom_manage_home_role(system_r, systemd_homed_t) ') optional_policy(` - usermanage_read_crack_db(systemd_homed_t) + usermanage_read_crack_db(systemd_homed_t) ') ####################################### @@ -183,8 +186,10 @@ files_manage_isid_type_files(systemd_homework_t) files_mounton_isid(systemd_homework_t) # /var/cache/systemd/home -list_dirs_pattern(systemd_homework_t, systemd_homed_cache_t, systemd_homed_cache_t) -read_files_pattern(systemd_homework_t, systemd_homed_cache_t, systemd_homed_cache_t) +create_dirs_pattern(systemd_homework_t, systemd_homed_cache_t, systemd_homed_cache_t) +delete_dirs_pattern(systemd_homework_t, systemd_homed_cache_t, systemd_homed_cache_t) +rename_dirs_pattern(systemd_homework_t, systemd_homed_cache_t, systemd_homed_cache_t) +manage_files_pattern(systemd_homework_t, systemd_homed_cache_t, systemd_homed_cache_t) # /run/systemd/home/notify write_sock_files_pattern(systemd_homework_t, systemd_homed_runtime_dir_t, systemd_homed_runtime_socket_t) @@ -255,7 +260,8 @@ optional_policy(` ') optional_policy(` - systemd_search_cache_dirs(systemd_homework_t) + systemd_cache_filetrans(systemd_homework_t, systemd_homed_cache_t, dir, "home") + systemd_search_cache_dirs(systemd_homework_t) ') optional_policy(`