Add Solaris audit support; from Gary Winiger at Oracle.
This commit is contained in:
@@ -46,6 +46,9 @@
|
||||
#ifdef HAVE_LINUX_AUDIT
|
||||
# include "linux_audit.h"
|
||||
#endif
|
||||
#ifdef HAVE_SOLARIS_AUDIT
|
||||
# include "solaris_audit.h"
|
||||
#endif
|
||||
|
||||
int
|
||||
audit_success(int argc, char *argv[])
|
||||
@@ -61,6 +64,10 @@ audit_success(int argc, char *argv[])
|
||||
#ifdef HAVE_LINUX_AUDIT
|
||||
if (linux_audit_command(argv, 1) == -1)
|
||||
rc = -1;
|
||||
#endif
|
||||
#ifdef HAVE_SOLARIS_AUDIT
|
||||
if (solaris_audit_success(argc, argv) == -1)
|
||||
rc = -1;
|
||||
#endif
|
||||
}
|
||||
|
||||
@@ -93,6 +100,12 @@ audit_failure(int argc, char *argv[], char const *const fmt, ...)
|
||||
rc = -1;
|
||||
va_end(ap);
|
||||
#endif
|
||||
#ifdef HAVE_SOLARIS_AUDIT
|
||||
va_start(ap, fmt);
|
||||
if (solaris_audit_failure(argc, argv, _(fmt), ap) == -1)
|
||||
rc = -1;
|
||||
va_end(ap);
|
||||
#endif
|
||||
|
||||
sudoers_setlocale(oldlocale, NULL);
|
||||
}
|
||||
|
Reference in New Issue
Block a user