Skip to content

Commit

Permalink
Fix the files_manage_all_files() interface
Browse files Browse the repository at this point in the history
The auth_*() and seutil_*() calls need to be inside an optional block.

Signed-off-by: Ondrej Mosnacek <omosnace@redhat.com>
  • Loading branch information
WOnder93 authored and zpytela committed Jan 30, 2023
1 parent 71d551b commit f5ad795
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions policy/modules/kernel/files.if
Original file line number Diff line number Diff line change
Expand Up @@ -1788,10 +1788,14 @@ interface(`files_manage_all_files',`
manage_sock_files_pattern($1, { file_type $2 }, { file_type $2 })

# satisfy the assertions:
seutil_create_bin_policy($1)
files_manage_kernel_modules($1)
auth_reader_shadow($1)
auth_writer_shadow($1)
optional_policy(`
seutil_create_bin_policy($1)
')
optional_policy(`
auth_reader_shadow($1)
auth_writer_shadow($1)
')
')

########################################
Expand Down

0 comments on commit f5ad795

Please sign in to comment.