From 33d42c2e3df650378d6fd6ce8694b5fb0243a451 Mon Sep 17 00:00:00 2001 From: Daniel J Walsh Date: Tue, 27 Feb 2007 16:37:10 +0000 Subject: [PATCH] * Tue Feb 27 2007 Dan Walsh 2.0.6-3 - Update to upstream -sepolgen * Merged support for enabling parser debugging from Karl MacMillan. - Add sgrupp cleanup of restorcon init script --- .cvsignore | 1 + policycoreutils-rhat.patch | 109 +++++++++++++++++++++++++++++++++---- policycoreutils.spec | 11 +++- sources | 4 +- 4 files changed, 111 insertions(+), 14 deletions(-) diff --git a/.cvsignore b/.cvsignore index 33c43f1..efcbbd7 100644 --- a/.cvsignore +++ b/.cvsignore @@ -137,3 +137,4 @@ policycoreutils-2.0.3.tgz sepolgen-1.0.1.tgz policycoreutils-2.0.6.tgz sepolgen-1.0.2.tgz +sepolgen-1.0.3.tgz diff --git a/policycoreutils-rhat.patch b/policycoreutils-rhat.patch index f5c6526..984bd85 100644 --- a/policycoreutils-rhat.patch +++ b/policycoreutils-rhat.patch @@ -1,15 +1,15 @@ -diff --exclude-from=exclude --exclude=sepolgen-1.0.0 --exclude=gui --exclude=po -N -u -r nsapolicycoreutils/Makefile policycoreutils-2.0.3/Makefile +diff --exclude-from=exclude --exclude=sepolgen-1.0.2 --exclude=gui --exclude=po -N -u -r nsapolicycoreutils/Makefile policycoreutils-2.0.6/Makefile --- nsapolicycoreutils/Makefile 2006-11-16 17:15:00.000000000 -0500 -+++ policycoreutils-2.0.3/Makefile 2007-02-22 12:32:39.000000000 -0500 ++++ policycoreutils-2.0.6/Makefile 2007-02-27 11:30:03.000000000 -0500 @@ -1,4 +1,4 @@ -SUBDIRS=setfiles semanage load_policy newrole run_init restorecon restorecond secon audit2allow audit2why scripts sestatus semodule_package semodule semodule_link semodule_expand semodule_deps setsebool po +SUBDIRS=setfiles semanage load_policy newrole run_init restorecon restorecond secon audit2allow audit2why scripts sestatus semodule_package semodule semodule_link semodule_expand semodule_deps setsebool po gui all install relabel clean indent: @for subdir in $(SUBDIRS); do \ -diff --exclude-from=exclude --exclude=sepolgen-1.0.0 --exclude=gui --exclude=po -N -u -r nsapolicycoreutils/restorecond/restorecond.c policycoreutils-2.0.3/restorecond/restorecond.c +diff --exclude-from=exclude --exclude=sepolgen-1.0.2 --exclude=gui --exclude=po -N -u -r nsapolicycoreutils/restorecond/restorecond.c policycoreutils-2.0.6/restorecond/restorecond.c --- nsapolicycoreutils/restorecond/restorecond.c 2007-02-22 08:53:22.000000000 -0500 -+++ policycoreutils-2.0.3/restorecond/restorecond.c 2007-02-22 12:32:39.000000000 -0500 ++++ policycoreutils-2.0.6/restorecond/restorecond.c 2007-02-27 11:30:03.000000000 -0500 @@ -210,9 +210,10 @@ } @@ -36,9 +36,9 @@ diff --exclude-from=exclude --exclude=sepolgen-1.0.0 --exclude=gui --exclude=po } free(scontext); close(fd); -diff --exclude-from=exclude --exclude=sepolgen-1.0.0 --exclude=gui --exclude=po -N -u -r nsapolicycoreutils/restorecond/restorecond.conf policycoreutils-2.0.3/restorecond/restorecond.conf +diff --exclude-from=exclude --exclude=sepolgen-1.0.2 --exclude=gui --exclude=po -N -u -r nsapolicycoreutils/restorecond/restorecond.conf policycoreutils-2.0.6/restorecond/restorecond.conf --- nsapolicycoreutils/restorecond/restorecond.conf 2006-11-20 12:19:55.000000000 -0500 -+++ policycoreutils-2.0.3/restorecond/restorecond.conf 2007-02-23 09:55:54.000000000 -0500 ++++ policycoreutils-2.0.6/restorecond/restorecond.conf 2007-02-27 11:30:03.000000000 -0500 @@ -1,7 +1,10 @@ /etc/resolv.conf +/etc/localtime @@ -50,9 +50,98 @@ diff --exclude-from=exclude --exclude=sepolgen-1.0.0 --exclude=gui --exclude=po +/etc/lvm/.cache ~/public_html ~/.mozilla/plugins/libflashplayer.so -diff --exclude-from=exclude --exclude=sepolgen-1.0.0 --exclude=gui --exclude=po -N -u -r nsapolicycoreutils/scripts/chcat policycoreutils-2.0.3/scripts/chcat +diff --exclude-from=exclude --exclude=sepolgen-1.0.2 --exclude=gui --exclude=po -N -u -r nsapolicycoreutils/restorecond/restorecond.init policycoreutils-2.0.6/restorecond/restorecond.init +--- nsapolicycoreutils/restorecond/restorecond.init 2006-11-16 17:14:28.000000000 -0500 ++++ policycoreutils-2.0.6/restorecond/restorecond.init 2007-02-27 11:34:54.000000000 -0500 +@@ -1,43 +1,68 @@ + #!/bin/sh + # +-# restorecond: Daemo used to maintain path file context ++# restorecond: Daemon used to maintain path file context + # +-# chkconfig: 2345 10 90 ++# chkconfig: 2345 12 87 + # description: restorecond uses inotify to look for creation of new files \ + # listed in the /etc/selinux/restorecond.conf file, and restores the \ + # correct security context. + # ++# processname: /usr/sbin/restorecond ++# config: /etc/selinux/restorecond.conf ++# pidfile: /var/run/restorecond.pid ++# ++# Return values according to LSB for all commands but status: ++# 0 - success ++# 1 - generic or unspecified error ++# 2 - invalid or excess argument(s) ++# 3 - unimplemented feature (e.g. "reload") ++# 4 - insufficient privilege ++# 5 - program is not installed ++# 6 - program is not configured ++# 7 - program is not running ++ ++PATH=/sbin:/bin:/usr/bin:/usr/sbin + + # Source function library. + . /etc/rc.d/init.d/functions + + [ -x /usr/sbin/selinuxenabled ] && /usr/sbin/selinuxenabled || exit 0 + ++# Check that we are root ... so non-root users stop here ++test $EUID = 0 || exit 4 ++ ++test -x /usr/sbin/restorecond || exit 5 ++test -f /etc/selinux/restorecond.conf || exit 6 ++ ++RETVAL=0 ++ + start() + { + echo -n $"Starting restorecond: " ++ unset HOME MAIL USER USERNAME + daemon /usr/sbin/restorecond +- ++ RETVAL=$? + touch /var/lock/subsys/restorecond + echo ++ return $RETVAL + } + + stop() + { + echo -n $"Shutting down restorecond: " + killproc restorecond +- ++ RETVAL=$? + rm -f /var/lock/subsys/restorecond + echo ++ return $RETVAL + } ++ + restart() + { + stop + start + } + +-[ -f /usr/sbin/restorecond ] || exit 0 +- + # See how we were called. + case "$1" in + start) +@@ -57,7 +82,8 @@ + ;; + *) + echo $"Usage: $0 {start|stop|restart|reload|condrestart}" +- exit 1 ++ RETVAL=3 + esac + +-exit 0 ++exit $RETVAL ++ +diff --exclude-from=exclude --exclude=sepolgen-1.0.2 --exclude=gui --exclude=po -N -u -r nsapolicycoreutils/scripts/chcat policycoreutils-2.0.6/scripts/chcat --- nsapolicycoreutils/scripts/chcat 2007-02-22 08:53:22.000000000 -0500 -+++ policycoreutils-2.0.3/scripts/chcat 2007-02-22 12:37:17.000000000 -0500 ++++ policycoreutils-2.0.6/scripts/chcat 2007-02-27 11:30:03.000000000 -0500 @@ -74,9 +74,11 @@ if i not in cats: cats.append(i) @@ -84,9 +173,9 @@ diff --exclude-from=exclude --exclude=sepolgen-1.0.0 --exclude=gui --exclude=po if add_ind: cmd = "semanage login -a -r %s -s %s %s" % (new_serange, user[0], u) else: -diff --exclude-from=exclude --exclude=sepolgen-1.0.0 --exclude=gui --exclude=po -N -u -r nsapolicycoreutils/semanage/seobject.py policycoreutils-2.0.3/semanage/seobject.py +diff --exclude-from=exclude --exclude=sepolgen-1.0.2 --exclude=gui --exclude=po -N -u -r nsapolicycoreutils/semanage/seobject.py policycoreutils-2.0.6/semanage/seobject.py --- nsapolicycoreutils/semanage/seobject.py 2007-02-22 08:53:22.000000000 -0500 -+++ policycoreutils-2.0.3/semanage/seobject.py 2007-02-22 12:32:39.000000000 -0500 ++++ policycoreutils-2.0.6/semanage/seobject.py 2007-02-27 11:30:03.000000000 -0500 @@ -209,6 +209,7 @@ os.write(fd, self.out()) os.close(fd) diff --git a/policycoreutils.spec b/policycoreutils.spec index bbcace9..076481d 100644 --- a/policycoreutils.spec +++ b/policycoreutils.spec @@ -2,11 +2,11 @@ %define libsepolver 2.0.1-1 %define libsemanagever 1.10.0-1 %define libselinuxver 2.0.0-1 -%define sepolgenver 1.0.2 +%define sepolgenver 1.0.3 Summary: SELinux policy core utilities. Name: policycoreutils Version: 2.0.6 -Release: 2%{?dist} +Release: 3%{?dist} License: GPL Group: System Environment/Base Source: http://www.nsa.gov/selinux/archives/policycoreutils-%{version}.tgz @@ -178,6 +178,7 @@ fi %post /sbin/chkconfig --add restorecond [ -f /usr/share/selinux/devel/include/build.conf ] && /usr/bin/sepolgen-ifgen > /dev/null +exit 0 %postun if [ "$1" -ge "1" ]; then @@ -185,6 +186,12 @@ if [ "$1" -ge "1" ]; then fi %changelog +* Tue Feb 27 2007 Dan Walsh 2.0.6-3 +- Update to upstream + -sepolgen + * Merged support for enabling parser debugging from Karl MacMillan. +- Add sgrupp cleanup of restorcon init script + * Mon Feb 26 2007 Dan Walsh 2.0.6-2 - Add Bill Nottinham patch to run restorcond condrestart in postun diff --git a/sources b/sources index f158654..ae50f58 100644 --- a/sources +++ b/sources @@ -1,2 +1,2 @@ -978739a21202be549954555a3c0ecb45 policycoreutils-2.0.6.tgz -e7637ad90fb6cd2c5d9bd20238353c01 sepolgen-1.0.2.tgz +55b324eacb47b4e660964fb7896d15fd policycoreutils-2.0.6.tgz +ceeaa37a796531da375bd32af071ae4c sepolgen-1.0.3.tgz