aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/audit.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux/audit.h')
-rw-r--r--include/linux/audit.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/include/linux/audit.h b/include/linux/audit.h
index 8cfb9feb2a05..6fbebac7b1bf 100644
--- a/include/linux/audit.h
+++ b/include/linux/audit.h
@@ -100,6 +100,7 @@
100#define AUDIT_TTY 1319 /* Input on an administrative TTY */ 100#define AUDIT_TTY 1319 /* Input on an administrative TTY */
101#define AUDIT_EOE 1320 /* End of multi-record event */ 101#define AUDIT_EOE 1320 /* End of multi-record event */
102#define AUDIT_BPRM_FCAPS 1321 /* Information about fcaps increasing perms */ 102#define AUDIT_BPRM_FCAPS 1321 /* Information about fcaps increasing perms */
103#define AUDIT_CAPSET 1322 /* Record showing argument to sys_capset */
103 104
104#define AUDIT_AVC 1400 /* SE Linux avc denial or grant */ 105#define AUDIT_AVC 1400 /* SE Linux avc denial or grant */
105#define AUDIT_SELINUX_ERR 1401 /* Internal SE Linux Errors */ 106#define AUDIT_SELINUX_ERR 1401 /* Internal SE Linux Errors */
@@ -454,6 +455,7 @@ extern int __audit_mq_timedreceive(mqd_t mqdes, size_t msg_len, unsigned int __u
454extern int __audit_mq_notify(mqd_t mqdes, const struct sigevent __user *u_notification); 455extern int __audit_mq_notify(mqd_t mqdes, const struct sigevent __user *u_notification);
455extern int __audit_mq_getsetattr(mqd_t mqdes, struct mq_attr *mqstat); 456extern int __audit_mq_getsetattr(mqd_t mqdes, struct mq_attr *mqstat);
456extern void __audit_log_bprm_fcaps(struct linux_binprm *bprm, kernel_cap_t *pP, kernel_cap_t *pE); 457extern void __audit_log_bprm_fcaps(struct linux_binprm *bprm, kernel_cap_t *pP, kernel_cap_t *pE);
458extern int __audit_log_capset(pid_t pid, kernel_cap_t *eff, kernel_cap_t *inh, kernel_cap_t *perm);
457 459
458static inline int audit_ipc_obj(struct kern_ipc_perm *ipcp) 460static inline int audit_ipc_obj(struct kern_ipc_perm *ipcp)
459{ 461{
@@ -526,6 +528,13 @@ static inline void audit_log_bprm_fcaps(struct linux_binprm *bprm, kernel_cap_t
526 __audit_log_bprm_fcaps(bprm, pP, pE); 528 __audit_log_bprm_fcaps(bprm, pP, pE);
527} 529}
528 530
531static inline int audit_log_capset(pid_t pid, kernel_cap_t *eff, kernel_cap_t *inh, kernel_cap_t *perm)
532{
533 if (unlikely(!audit_dummy_context()))
534 return __audit_log_capset(pid, eff, inh, perm);
535 return 0;
536}
537
529extern int audit_n_rules; 538extern int audit_n_rules;
530extern int audit_signals; 539extern int audit_signals;
531#else 540#else
@@ -558,6 +567,7 @@ extern int audit_signals;
558#define audit_mq_notify(d,n) ({ 0; }) 567#define audit_mq_notify(d,n) ({ 0; })
559#define audit_mq_getsetattr(d,s) ({ 0; }) 568#define audit_mq_getsetattr(d,s) ({ 0; })
560#define audit_log_bprm_fcaps(b, p, e) do { ; } while (0) 569#define audit_log_bprm_fcaps(b, p, e) do { ; } while (0)
570#define audit_log_capset(pid, e, i, p) ({ 0; })
561#define audit_ptrace(t) ((void)0) 571#define audit_ptrace(t) ((void)0)
562#define audit_n_rules 0 572#define audit_n_rules 0
563#define audit_signals 0 573#define audit_signals 0