summaryrefslogtreecommitdiffstats
path: root/sys/bsm
diff options
context:
space:
mode:
authorwsalamon <wsalamon@FreeBSD.org>2006-09-01 11:45:40 +0000
committerwsalamon <wsalamon@FreeBSD.org>2006-09-01 11:45:40 +0000
commitc62317c442340f5e4627b6020679dc03d49a3918 (patch)
tree17f9a899743e9577c2e64080d7c7f0a957fbe0f4 /sys/bsm
parente279989d710de9f19f0e36445d579caea48bf429 (diff)
downloadFreeBSD-src-c62317c442340f5e4627b6020679dc03d49a3918.zip
FreeBSD-src-c62317c442340f5e4627b6020679dc03d49a3918.tar.gz
Audit the argv and env vectors passed in on exec:
Add the argument auditing functions for argv and env. Add kernel-specific versions of the tokenizer functions for the arg and env represented as a char array. Implement the AUDIT_ARGV and AUDIT_ARGE audit policy commands to enable/disable argv/env auditing. Call the argument auditing from the exec system calls. Obtained from: TrustedBSD Project Approved by: rwatson (mentor)
Diffstat (limited to 'sys/bsm')
-rw-r--r--sys/bsm/audit_record.h9
1 files changed, 7 insertions, 2 deletions
diff --git a/sys/bsm/audit_record.h b/sys/bsm/audit_record.h
index 18235e2..b1c975b 100644
--- a/sys/bsm/audit_record.h
+++ b/sys/bsm/audit_record.h
@@ -319,8 +319,13 @@ token_t *au_to_subject32_ex(au_id_t auid, uid_t euid, gid_t egid, uid_t ruid,
gid_t rgid, pid_t pid, au_asid_t sid, au_tid_addr_t *tid);
token_t *au_to_subject64_ex(au_id_t auid, uid_t euid, gid_t egid, uid_t ruid,
gid_t rgid, pid_t pid, au_asid_t sid, au_tid_addr_t *tid);
-token_t *au_to_exec_args(const char **);
-token_t *au_to_exec_env(const char **);
+#if defined(_KERNEL) || defined(KERNEL)
+token_t *au_to_exec_args(char *args, int argc);
+token_t *au_to_exec_env(char *envs, int envc);
+#else
+token_t *au_to_exec_args(char **argv);
+token_t *au_to_exec_env(char **envp);
+#endif
token_t *au_to_text(char *text);
token_t *au_to_kevent(struct kevent *kev);
token_t *au_to_trailer(int rec_size);
OpenPOWER on IntegriCloud