diff options
Diffstat (limited to 'include/linux/audit.h')
-rw-r--r-- | include/linux/audit.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/include/linux/audit.h b/include/linux/audit.h index e24afabc548f..9d339eb27881 100644 --- a/include/linux/audit.h +++ b/include/linux/audit.h | |||
@@ -102,6 +102,9 @@ | |||
102 | #define AUDIT_EOE 1320 /* End of multi-record event */ | 102 | #define AUDIT_EOE 1320 /* End of multi-record event */ |
103 | #define AUDIT_BPRM_FCAPS 1321 /* Information about fcaps increasing perms */ | 103 | #define AUDIT_BPRM_FCAPS 1321 /* Information about fcaps increasing perms */ |
104 | #define AUDIT_CAPSET 1322 /* Record showing argument to sys_capset */ | 104 | #define AUDIT_CAPSET 1322 /* Record showing argument to sys_capset */ |
105 | #define AUDIT_MMAP 1323 /* Record showing descriptor and flags in mmap */ | ||
106 | #define AUDIT_NETFILTER_PKT 1324 /* Packets traversing netfilter chains */ | ||
107 | #define AUDIT_NETFILTER_CFG 1325 /* Netfilter chain modifications */ | ||
105 | 108 | ||
106 | #define AUDIT_AVC 1400 /* SE Linux avc denial or grant */ | 109 | #define AUDIT_AVC 1400 /* SE Linux avc denial or grant */ |
107 | #define AUDIT_SELINUX_ERR 1401 /* Internal SE Linux Errors */ | 110 | #define AUDIT_SELINUX_ERR 1401 /* Internal SE Linux Errors */ |
@@ -371,6 +374,7 @@ struct audit_buffer; | |||
371 | struct audit_context; | 374 | struct audit_context; |
372 | struct inode; | 375 | struct inode; |
373 | struct netlink_skb_parms; | 376 | struct netlink_skb_parms; |
377 | struct path; | ||
374 | struct linux_binprm; | 378 | struct linux_binprm; |
375 | struct mq_attr; | 379 | struct mq_attr; |
376 | struct mqstat; | 380 | struct mqstat; |
@@ -478,6 +482,7 @@ extern int __audit_log_bprm_fcaps(struct linux_binprm *bprm, | |||
478 | const struct cred *new, | 482 | const struct cred *new, |
479 | const struct cred *old); | 483 | const struct cred *old); |
480 | extern void __audit_log_capset(pid_t pid, const struct cred *new, const struct cred *old); | 484 | extern void __audit_log_capset(pid_t pid, const struct cred *new, const struct cred *old); |
485 | extern void __audit_mmap_fd(int fd, int flags); | ||
481 | 486 | ||
482 | static inline void audit_ipc_obj(struct kern_ipc_perm *ipcp) | 487 | static inline void audit_ipc_obj(struct kern_ipc_perm *ipcp) |
483 | { | 488 | { |
@@ -531,6 +536,12 @@ static inline void audit_log_capset(pid_t pid, const struct cred *new, | |||
531 | __audit_log_capset(pid, new, old); | 536 | __audit_log_capset(pid, new, old); |
532 | } | 537 | } |
533 | 538 | ||
539 | static inline void audit_mmap_fd(int fd, int flags) | ||
540 | { | ||
541 | if (unlikely(!audit_dummy_context())) | ||
542 | __audit_mmap_fd(fd, flags); | ||
543 | } | ||
544 | |||
534 | extern int audit_n_rules; | 545 | extern int audit_n_rules; |
535 | extern int audit_signals; | 546 | extern int audit_signals; |
536 | #else | 547 | #else |
@@ -564,6 +575,7 @@ extern int audit_signals; | |||
564 | #define audit_mq_getsetattr(d,s) ((void)0) | 575 | #define audit_mq_getsetattr(d,s) ((void)0) |
565 | #define audit_log_bprm_fcaps(b, ncr, ocr) ({ 0; }) | 576 | #define audit_log_bprm_fcaps(b, ncr, ocr) ({ 0; }) |
566 | #define audit_log_capset(pid, ncr, ocr) ((void)0) | 577 | #define audit_log_capset(pid, ncr, ocr) ((void)0) |
578 | #define audit_mmap_fd(fd, flags) ((void)0) | ||
567 | #define audit_ptrace(t) ((void)0) | 579 | #define audit_ptrace(t) ((void)0) |
568 | #define audit_n_rules 0 | 580 | #define audit_n_rules 0 |
569 | #define audit_signals 0 | 581 | #define audit_signals 0 |