The Samba-Bugzilla – Attachment 14266 Details for
Bug 13436
Not every facility works in vfs_*_audit modules...
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Recognize all valid syslog facilities
0001-Make-sure-that-vfs-audit-modules-recognize-and-accep.patch (text/plain), 5.05 KB, created by
Timur Bakeyev
on 2018-07-02 03:49:59 UTC
(
hide
)
Description:
Recognize all valid syslog facilities
Filename:
MIME Type:
Creator:
Timur Bakeyev
Created:
2018-07-02 03:49:59 UTC
Size:
5.05 KB
patch
obsolete
>From 8d9a9dcd018c0bd82656bc00fde63150be70662f Mon Sep 17 00:00:00 2001 >From: "Timur I. Bakeyev" <timur@iXsystems.com> >Date: Mon, 2 Jul 2018 01:05:36 +0200 >Subject: [PATCH] Make sure that vfs*audit modules recognize and accept all the > syslog facilities. > >Bug: https://bugzilla.samba.org/show_bug.cgi?id=13436 > >Signed-off-by: Timur I. Bakeyev <timur@iXsystems.com> >--- > source3/modules/vfs_audit.c | 38 +++++++++++++++++++++++++++----------- > source3/modules/vfs_extd_audit.c | 38 +++++++++++++++++++++++++++----------- > source3/modules/vfs_full_audit.c | 38 +++++++++++++++++++++++++++----------- > 3 files changed, 81 insertions(+), 33 deletions(-) > >diff --git a/source3/modules/vfs_audit.c b/source3/modules/vfs_audit.c >index 24bc1e8db5f..95a595bd92c 100644 >--- a/source3/modules/vfs_audit.c >+++ b/source3/modules/vfs_audit.c >@@ -33,16 +33,32 @@ > static int audit_syslog_facility(vfs_handle_struct *handle) > { > static const struct enum_list enum_log_facilities[] = { >- { LOG_USER, "USER" }, >- { LOG_LOCAL0, "LOCAL0" }, >- { LOG_LOCAL1, "LOCAL1" }, >- { LOG_LOCAL2, "LOCAL2" }, >- { LOG_LOCAL3, "LOCAL3" }, >- { LOG_LOCAL4, "LOCAL4" }, >- { LOG_LOCAL5, "LOCAL5" }, >- { LOG_LOCAL6, "LOCAL6" }, >- { LOG_LOCAL7, "LOCAL7" }, >- { -1, NULL} >+ { LOG_AUTH, "AUTH" }, >+ { LOG_CRON, "CRON" }, >+ { LOG_DAEMON, "DAEMON" }, >+ { LOG_FTP, "FTP" }, >+ { LOG_KERN, "KERN" }, >+ { LOG_LPR, "LPR" }, >+ { LOG_MAIL, "MAIL" }, >+ { LOG_NEWS, "NEWS" }, >+#ifdef LOG_NTP >+ { LOG_NTP, "NTP" }, >+#endif >+#ifdef LOG_SECURITY >+ { LOG_SECURITY, "SECURITY" }, >+#endif >+ { LOG_SYSLOG, "SYSLOG" }, >+ { LOG_USER, "USER" }, >+ { LOG_UUCP, "UUCP" }, >+ { LOG_LOCAL0, "LOCAL0" }, >+ { LOG_LOCAL1, "LOCAL1" }, >+ { LOG_LOCAL2, "LOCAL2" }, >+ { LOG_LOCAL3, "LOCAL3" }, >+ { LOG_LOCAL4, "LOCAL4" }, >+ { LOG_LOCAL5, "LOCAL5" }, >+ { LOG_LOCAL6, "LOCAL6" }, >+ { LOG_LOCAL7, "LOCAL7" }, >+ { -1, NULL } > }; > > int facility; >@@ -64,7 +80,7 @@ static int audit_syslog_priority(vfs_handle_struct *handle) > { LOG_NOTICE, "NOTICE" }, > { LOG_INFO, "INFO" }, > { LOG_DEBUG, "DEBUG" }, >- { -1, NULL} >+ { -1, NULL } > }; > > int priority; >diff --git a/source3/modules/vfs_extd_audit.c b/source3/modules/vfs_extd_audit.c >index 50bd6f8f758..a76bb781c21 100644 >--- a/source3/modules/vfs_extd_audit.c >+++ b/source3/modules/vfs_extd_audit.c >@@ -36,16 +36,32 @@ static int vfs_extd_audit_debug_level = DBGC_VFS; > static int audit_syslog_facility(vfs_handle_struct *handle) > { > static const struct enum_list enum_log_facilities[] = { >- { LOG_USER, "USER" }, >- { LOG_LOCAL0, "LOCAL0" }, >- { LOG_LOCAL1, "LOCAL1" }, >- { LOG_LOCAL2, "LOCAL2" }, >- { LOG_LOCAL3, "LOCAL3" }, >- { LOG_LOCAL4, "LOCAL4" }, >- { LOG_LOCAL5, "LOCAL5" }, >- { LOG_LOCAL6, "LOCAL6" }, >- { LOG_LOCAL7, "LOCAL7" }, >- { -1, NULL} >+ { LOG_AUTH, "AUTH" }, >+ { LOG_CRON, "CRON" }, >+ { LOG_DAEMON, "DAEMON" }, >+ { LOG_FTP, "FTP" }, >+ { LOG_KERN, "KERN" }, >+ { LOG_LPR, "LPR" }, >+ { LOG_MAIL, "MAIL" }, >+ { LOG_NEWS, "NEWS" }, >+#ifdef LOG_NTP >+ { LOG_NTP, "NTP" }, >+#endif >+#ifdef LOG_SECURITY >+ { LOG_SECURITY, "SECURITY" }, >+#endif >+ { LOG_SYSLOG, "SYSLOG" }, >+ { LOG_USER, "USER" }, >+ { LOG_UUCP, "UUCP" }, >+ { LOG_LOCAL0, "LOCAL0" }, >+ { LOG_LOCAL1, "LOCAL1" }, >+ { LOG_LOCAL2, "LOCAL2" }, >+ { LOG_LOCAL3, "LOCAL3" }, >+ { LOG_LOCAL4, "LOCAL4" }, >+ { LOG_LOCAL5, "LOCAL5" }, >+ { LOG_LOCAL6, "LOCAL6" }, >+ { LOG_LOCAL7, "LOCAL7" }, >+ { -1, NULL } > }; > > int facility; >@@ -67,7 +83,7 @@ static int audit_syslog_priority(vfs_handle_struct *handle) > { LOG_NOTICE, "NOTICE" }, > { LOG_INFO, "INFO" }, > { LOG_DEBUG, "DEBUG" }, >- { -1, NULL} >+ { -1, NULL } > }; > > int priority; >diff --git a/source3/modules/vfs_full_audit.c b/source3/modules/vfs_full_audit.c >index d76ec407759..5a7af1b7d47 100644 >--- a/source3/modules/vfs_full_audit.c >+++ b/source3/modules/vfs_full_audit.c >@@ -350,16 +350,32 @@ static struct { > static int audit_syslog_facility(vfs_handle_struct *handle) > { > static const struct enum_list enum_log_facilities[] = { >- { LOG_USER, "USER" }, >- { LOG_LOCAL0, "LOCAL0" }, >- { LOG_LOCAL1, "LOCAL1" }, >- { LOG_LOCAL2, "LOCAL2" }, >- { LOG_LOCAL3, "LOCAL3" }, >- { LOG_LOCAL4, "LOCAL4" }, >- { LOG_LOCAL5, "LOCAL5" }, >- { LOG_LOCAL6, "LOCAL6" }, >- { LOG_LOCAL7, "LOCAL7" }, >- { -1, NULL} >+ { LOG_AUTH, "AUTH" }, >+ { LOG_CRON, "CRON" }, >+ { LOG_DAEMON, "DAEMON" }, >+ { LOG_FTP, "FTP" }, >+ { LOG_KERN, "KERN" }, >+ { LOG_LPR, "LPR" }, >+ { LOG_MAIL, "MAIL" }, >+ { LOG_NEWS, "NEWS" }, >+#ifdef LOG_NTP >+ { LOG_NTP, "NTP" }, >+#endif >+#ifdef LOG_SECURITY >+ { LOG_SECURITY, "SECURITY" }, >+#endif >+ { LOG_SYSLOG, "SYSLOG" }, >+ { LOG_USER, "USER" }, >+ { LOG_UUCP, "UUCP" }, >+ { LOG_LOCAL0, "LOCAL0" }, >+ { LOG_LOCAL1, "LOCAL1" }, >+ { LOG_LOCAL2, "LOCAL2" }, >+ { LOG_LOCAL3, "LOCAL3" }, >+ { LOG_LOCAL4, "LOCAL4" }, >+ { LOG_LOCAL5, "LOCAL5" }, >+ { LOG_LOCAL6, "LOCAL6" }, >+ { LOG_LOCAL7, "LOCAL7" }, >+ { -1, NULL } > }; > > int facility; >@@ -380,7 +396,7 @@ static int audit_syslog_priority(vfs_handle_struct *handle) > { LOG_NOTICE, "NOTICE" }, > { LOG_INFO, "INFO" }, > { LOG_DEBUG, "DEBUG" }, >- { -1, NULL} >+ { -1, NULL } > }; > > int priority; >-- >2.16.3 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 13436
: 14266