diff options
Diffstat (limited to 'include/linux/audit.h')
-rw-r--r-- | include/linux/audit.h | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/include/linux/audit.h b/include/linux/audit.h index bdd6f5de5fc4..97153027207a 100644 --- a/include/linux/audit.h +++ b/include/linux/audit.h | |||
@@ -98,6 +98,7 @@ | |||
98 | #define AUDIT_FD_PAIR 1317 /* audit record for pipe/socketpair */ | 98 | #define AUDIT_FD_PAIR 1317 /* audit record for pipe/socketpair */ |
99 | #define AUDIT_OBJ_PID 1318 /* ptrace target */ | 99 | #define AUDIT_OBJ_PID 1318 /* ptrace target */ |
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 | 102 | ||
102 | #define AUDIT_AVC 1400 /* SE Linux avc denial or grant */ | 103 | #define AUDIT_AVC 1400 /* SE Linux avc denial or grant */ |
103 | #define AUDIT_SELINUX_ERR 1401 /* Internal SE Linux Errors */ | 104 | #define AUDIT_SELINUX_ERR 1401 /* Internal SE Linux Errors */ |
@@ -409,7 +410,8 @@ extern unsigned int audit_serial(void); | |||
409 | extern void auditsc_get_stamp(struct audit_context *ctx, | 410 | extern void auditsc_get_stamp(struct audit_context *ctx, |
410 | struct timespec *t, unsigned int *serial); | 411 | struct timespec *t, unsigned int *serial); |
411 | extern int audit_set_loginuid(struct task_struct *task, uid_t loginuid); | 412 | extern int audit_set_loginuid(struct task_struct *task, uid_t loginuid); |
412 | extern uid_t audit_get_loginuid(struct audit_context *ctx); | 413 | #define audit_get_loginuid(t) ((t)->loginuid) |
414 | #define audit_get_sessionid(t) ((t)->sessionid) | ||
413 | extern void audit_log_task_context(struct audit_buffer *ab); | 415 | extern void audit_log_task_context(struct audit_buffer *ab); |
414 | extern int __audit_ipc_obj(struct kern_ipc_perm *ipcp); | 416 | extern int __audit_ipc_obj(struct kern_ipc_perm *ipcp); |
415 | extern int __audit_ipc_set_perm(unsigned long qbytes, uid_t uid, gid_t gid, mode_t mode); | 417 | extern int __audit_ipc_set_perm(unsigned long qbytes, uid_t uid, gid_t gid, mode_t mode); |
@@ -488,7 +490,8 @@ extern int audit_signals; | |||
488 | #define audit_inode_child(d,i,p) do { ; } while (0) | 490 | #define audit_inode_child(d,i,p) do { ; } while (0) |
489 | #define audit_core_dumps(i) do { ; } while (0) | 491 | #define audit_core_dumps(i) do { ; } while (0) |
490 | #define auditsc_get_stamp(c,t,s) do { BUG(); } while (0) | 492 | #define auditsc_get_stamp(c,t,s) do { BUG(); } while (0) |
491 | #define audit_get_loginuid(c) ({ -1; }) | 493 | #define audit_get_loginuid(t) (-1) |
494 | #define audit_get_sessionid(t) (-1) | ||
492 | #define audit_log_task_context(b) do { ; } while (0) | 495 | #define audit_log_task_context(b) do { ; } while (0) |
493 | #define audit_ipc_obj(i) ({ 0; }) | 496 | #define audit_ipc_obj(i) ({ 0; }) |
494 | #define audit_ipc_set_perm(q,u,g,m) ({ 0; }) | 497 | #define audit_ipc_set_perm(q,u,g,m) ({ 0; }) |
@@ -522,9 +525,11 @@ extern void audit_log_end(struct audit_buffer *ab); | |||
522 | extern void audit_log_hex(struct audit_buffer *ab, | 525 | extern void audit_log_hex(struct audit_buffer *ab, |
523 | const unsigned char *buf, | 526 | const unsigned char *buf, |
524 | size_t len); | 527 | size_t len); |
525 | extern const char * audit_log_untrustedstring(struct audit_buffer *ab, | 528 | extern int audit_string_contains_control(const char *string, |
529 | size_t len); | ||
530 | extern void audit_log_untrustedstring(struct audit_buffer *ab, | ||
526 | const char *string); | 531 | const char *string); |
527 | extern const char * audit_log_n_untrustedstring(struct audit_buffer *ab, | 532 | extern void audit_log_n_untrustedstring(struct audit_buffer *ab, |
528 | size_t n, | 533 | size_t n, |
529 | const char *string); | 534 | const char *string); |
530 | extern void audit_log_d_path(struct audit_buffer *ab, | 535 | extern void audit_log_d_path(struct audit_buffer *ab, |