logging.if: Added interfaces for watching all and audit logs.

Signed-off-by: Jonathan Davies <jd+github@upthedownstair.com>
This commit is contained in:
Jonathan Davies 2021-04-25 17:50:43 +01:00
parent ffdefbeb62
commit 5873a528a9
1 changed files with 38 additions and 0 deletions

View File

@ -146,6 +146,25 @@ interface(`logging_read_audit_log',`
dontaudit $1 auditd_log_t:file map;
')
########################################
## <summary>
## Watch the audit log.
## </summary>
## <param name="domain">
## <summary>
## Domain allowed access.
## </summary>
## </param>
## <rolecap/>
#
interface(`logging_watch_audit_log',`
gen_require(`
type auditd_log_t;
')
allow $1 auditd_log_t:file watch;
')
########################################
## <summary>
## Execute auditctl in the auditctl domain.
@ -1072,6 +1091,25 @@ interface(`logging_read_all_logs',`
read_files_pattern($1, logfile, logfile)
')
########################################
## <summary>
## Watch all log files.
## </summary>
## <param name="domain">
## <summary>
## Domain allowed access.
## </summary>
## </param>
## <rolecap/>
#
interface(`logging_watch_all_logs',`
gen_require(`
attribute logfile;
')
allow $1 logfile:file watch;
')
########################################
## <summary>
## Execute all log files in the caller domain.