Fix unknown lvalue in auditd.service (#969345)
This commit is contained in:
parent
b672a0e2cb
commit
17ff0f9536
82
audit-2.3.2-restart.patch
Normal file
82
audit-2.3.2-restart.patch
Normal file
@ -0,0 +1,82 @@
|
||||
diff -urN audit-2.3.1/init.d/auditd.condrestart audit-2.3.2/init.d/auditd.condrestart
|
||||
--- audit-2.3.1/init.d/auditd.condrestart 1969-12-31 19:00:00.000000000 -0500
|
||||
+++ audit-2.3.2/init.d/auditd.condrestart 2013-05-31 11:03:00.000000000 -0400
|
||||
@@ -0,0 +1,7 @@
|
||||
+#!/bin/sh
|
||||
+# Helper script to provide legacy auditd service options not
|
||||
+# directly supported by systemd.
|
||||
+
|
||||
+/usr/libexec/initscripts/legacy-actions/auditd/restart
|
||||
+RETVAL="$?"
|
||||
+exit $RETVAL
|
||||
diff -urN audit-2.3.1/init.d/auditd.restart audit-2.3.2/init.d/auditd.restart
|
||||
--- audit-2.3.1/init.d/auditd.restart 1969-12-31 19:00:00.000000000 -0500
|
||||
+++ audit-2.3.2/init.d/auditd.restart 2013-05-31 11:03:00.000000000 -0400
|
||||
@@ -0,0 +1,13 @@
|
||||
+#!/bin/sh
|
||||
+# Helper script to provide legacy auditd service options not
|
||||
+# directly supported by systemd.
|
||||
+
|
||||
+test -f /etc/audit/auditd.conf || exit 6
|
||||
+
|
||||
+/usr/libexec/initscripts/legacy-actions/auditd/stop
|
||||
+
|
||||
+echo "Redirecting start to /bin/systemctl start auditd.service"
|
||||
+/bin/systemctl start auditd.service
|
||||
+RETVAL="$?"
|
||||
+
|
||||
+exit $RETVAL
|
||||
diff -urN audit-2.3.1/init.d/auditd.service audit-2.3.2/init.d/auditd.service
|
||||
--- audit-2.3.1/init.d/auditd.service 2013-05-16 07:00:00.000000000 -0400
|
||||
+++ audit-2.3.2/init.d/auditd.service 2013-05-31 11:03:00.000000000 -0400
|
||||
@@ -4,6 +4,7 @@
|
||||
After=local-fs.target
|
||||
Conflicts=shutdown.target
|
||||
Before=sysinit.target shutdown.target
|
||||
+RefuseManualStop=yes
|
||||
|
||||
[Service]
|
||||
ExecStart=/sbin/auditd -n
|
||||
@@ -14,7 +15,6 @@
|
||||
#ExecStartPost=-/sbin/augenrules --load
|
||||
ExecStartPost=-/sbin/auditctl -R /etc/audit/audit.rules
|
||||
ExecReload=/bin/kill -HUP $MAINPID
|
||||
-RefuseManualStop=yes
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
diff -urN audit-2.3.1/init.d/Makefile.am audit-2.3.2/init.d/Makefile.am
|
||||
--- audit-2.3.1/init.d/Makefile.am 2013-05-16 07:00:00.000000000 -0400
|
||||
+++ audit-2.3.2/init.d/Makefile.am 2013-05-31 11:03:00.000000000 -0400
|
||||
@@ -22,8 +22,8 @@
|
||||
|
||||
CONFIG_CLEAN_FILES = *.rej *.orig
|
||||
EXTRA_DIST = auditd.init auditd.service auditd.sysconfig auditd.conf \
|
||||
- audit.rules auditd.cron libaudit.conf audispd.conf \
|
||||
- auditd.resume auditd.rotate auditd.stop augenrules
|
||||
+ audit.rules auditd.cron libaudit.conf audispd.conf auditd.condrestart \
|
||||
+ auditd.restart auditd.resume auditd.rotate auditd.stop augenrules
|
||||
libconfig = libaudit.conf
|
||||
dispconfig = audispd.conf
|
||||
dispconfigdir = $(sysconfdir)/audisp
|
||||
@@ -57,6 +57,8 @@
|
||||
$(INSTALL_SCRIPT) -D -m 750 ${srcdir}/auditd.rotate ${DESTDIR}${legacydir}/rotate
|
||||
$(INSTALL_SCRIPT) -D -m 750 ${srcdir}/auditd.resume ${DESTDIR}${legacydir}/resume
|
||||
$(INSTALL_SCRIPT) -D -m 750 ${srcdir}/auditd.stop ${DESTDIR}${legacydir}/stop
|
||||
+ $(INSTALL_SCRIPT) -D -m 750 ${srcdir}/auditd.restart ${DESTDIR}${legacydir}/restart
|
||||
+ $(INSTALL_SCRIPT) -D -m 750 ${srcdir}/auditd.condrestart ${DESTDIR}${legacydir}/condrestart
|
||||
else
|
||||
$(INSTALL_SCRIPT) -D ${srcdir}/auditd.init ${DESTDIR}${initdir}/auditd
|
||||
endif
|
||||
@@ -68,6 +70,11 @@
|
||||
rm ${DESTDIR}${sysconfdir}/${libconfig}
|
||||
if ENABLE_SYSTEMD
|
||||
rm ${DESTDIR}${initdir}/auditd.service
|
||||
+ rm ${DESTDIR}${legacydir}/rotate
|
||||
+ rm ${DESTDIR}${legacydir}/resume
|
||||
+ rm ${DESTDIR}${legacydir}/stop
|
||||
+ rm ${DESTDIR}${legacydir}/restart
|
||||
+ rm ${DESTDIR}${legacydir}/condrestart
|
||||
else
|
||||
rm ${DESTDIR}${sysconfigdir}/auditd
|
||||
rm ${DESTDIR}${initdir}/auditd
|
16
audit.spec
16
audit.spec
@ -6,15 +6,17 @@
|
||||
Summary: User space tools for 2.6 kernel auditing
|
||||
Name: audit
|
||||
Version: 2.3.1
|
||||
Release: 1%{?dist}
|
||||
Release: 2%{?dist}
|
||||
License: GPLv2+
|
||||
Group: System Environment/Daemons
|
||||
URL: http://people.redhat.com/sgrubb/audit/
|
||||
Source0: http://people.redhat.com/sgrubb/audit/%{name}-%{version}.tar.gz
|
||||
Patch1: audit-2.3.2-restart.patch
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
||||
BuildRequires: swig python-devel
|
||||
BuildRequires: tcp_wrappers-devel krb5-devel libcap-ng-devel
|
||||
BuildRequires: kernel-headers >= 2.6.29
|
||||
BuildRequires: autoconf
|
||||
Requires: %{name}-libs = %{version}-%{release}
|
||||
%if %{WITH_SYSTEMD}
|
||||
BuildRequires: systemd-units
|
||||
@ -89,6 +91,8 @@ behavior.
|
||||
|
||||
%prep
|
||||
%setup -q
|
||||
%patch1 -p1
|
||||
autoreconf -fv
|
||||
|
||||
%build
|
||||
%configure --sbindir=/sbin --libdir=/%{_lib} --with-python=yes --with-prelude --with-libwrap --enable-gssapi-krb5=yes --with-libcap-ng=yes --with-armeb \
|
||||
@ -161,6 +165,7 @@ fi
|
||||
|
||||
%preun
|
||||
%if %{WITH_SYSTEMD}
|
||||
/sbin/service auditd stop > /dev/null 2>&1
|
||||
%systemd_preun auditd.service
|
||||
%else
|
||||
if [ $1 -eq 0 ]; then
|
||||
@ -172,13 +177,9 @@ fi
|
||||
%postun libs -p /sbin/ldconfig
|
||||
|
||||
%postun
|
||||
%if %{WITH_SYSTEMD}
|
||||
%systemd_postun_with_restart auditd.service
|
||||
%else
|
||||
if [ $1 -ge 1 ]; then
|
||||
/sbin/service auditd condrestart > /dev/null 2>&1 || :
|
||||
fi
|
||||
%endif
|
||||
|
||||
%files libs
|
||||
%defattr(-,root,root,-)
|
||||
@ -243,6 +244,8 @@ fi
|
||||
%attr(750,root,root) %{_libexecdir}/initscripts/legacy-actions/auditd/resume
|
||||
%attr(750,root,root) %{_libexecdir}/initscripts/legacy-actions/auditd/rotate
|
||||
%attr(750,root,root) %{_libexecdir}/initscripts/legacy-actions/auditd/stop
|
||||
%attr(750,root,root) %{_libexecdir}/initscripts/legacy-actions/auditd/restart
|
||||
%attr(750,root,root) %{_libexecdir}/initscripts/legacy-actions/auditd/condrestart
|
||||
%else
|
||||
%attr(755,root,root) /etc/rc.d/init.d/auditd
|
||||
%config(noreplace) %attr(640,root,root) /etc/sysconfig/auditd
|
||||
@ -278,6 +281,9 @@ fi
|
||||
%attr(644,root,root) %{_mandir}/man8/audisp-remote.8.gz
|
||||
|
||||
%changelog
|
||||
* Fri May 31 2013 Steve Grubb <sgrubb@redhat.com> 2.3.1-2
|
||||
- Fix unknown lvalue in auditd.service (#969345)
|
||||
|
||||
* Thu May 30 2013 Steve Grubb <sgrubb@redhat.com> 2.3.1-1
|
||||
- New upstream bugfix/enhancement release
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user