diff options
author | Marek Pospisil <Marek.Pospisil@Sun.COM> | 2010-03-05 13:16:08 -0800 |
---|---|---|
committer | Marek Pospisil <Marek.Pospisil@Sun.COM> | 2010-03-05 13:16:08 -0800 |
commit | 005d3feb53a9a10272d4a24b03991575d6a9bcb3 (patch) | |
tree | 3c239c5ec7be3de4c1719c4539033149da56a799 /usr/src/uts/common/syscall/open.c | |
parent | 83d7a2524bdbf7b1da1c47b52bc20eee0f12c60e (diff) | |
download | illumos-joyent-005d3feb53a9a10272d4a24b03991575d6a9bcb3.tar.gz |
PSARC/2009/354 Always on / no reboot Solaris Audit
6192139 Solaris auditing should be able to start collecting audit records without a reboot
Diffstat (limited to 'usr/src/uts/common/syscall/open.c')
-rw-r--r-- | usr/src/uts/common/syscall/open.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/usr/src/uts/common/syscall/open.c b/usr/src/uts/common/syscall/open.c index e4fc89f3ec..3f5f484f6d 100644 --- a/usr/src/uts/common/syscall/open.c +++ b/usr/src/uts/common/syscall/open.c @@ -48,7 +48,6 @@ #include <sys/uio.h> #include <sys/debug.h> #include <c2/audit.h> -#include <sys/cmn_err.h> /* * Common code for openat(). Check permissions, allocate an open @@ -68,6 +67,7 @@ copen(int startfd, char *fname, int filemode, int createmode) proc_t *p = curproc; uio_seg_t seg = UIO_USERSPACE; char *open_filename = fname; + uint32_t auditing = AU_AUDITING(); if (startfd == AT_FDCWD) { /* @@ -101,7 +101,7 @@ copen(int startfd, char *fname, int filemode, int createmode) * Handle openattrdirat request */ if (filemode & FXATTRDIROPEN) { - if (audit_active) + if (auditing) audit_setfsat_path(1); if (error = lookupnameat(fname, seg, FOLLOW, @@ -185,7 +185,7 @@ copen(int startfd, char *fname, int filemode, int createmode) filemode &= ~FNDELAY; error = falloc((vnode_t *)NULL, filemode, &fp, &fd); if (error == 0) { - if (audit_active) + if (auditing) audit_setfsat_path(1); /* * Last arg is a don't-care term if @@ -200,7 +200,7 @@ copen(int startfd, char *fname, int filemode, int createmode) if (startvp != NULL) VN_RELE(startvp); if (error == 0) { - if (audit_active) + if (auditing) audit_copen(fd, fp, vp); if ((vp->v_flag & VDUP) == 0) { fp->f_vnode = vp; |