From 10913b779d8a18f3ab2f9c52bba027d60ab6198c Mon Sep 17 00:00:00 2001 From: Dan Walsh Date: Thu, 28 Feb 2013 15:28:38 -0500 Subject: [PATCH] Fix fixfiles to use exclude_dirs on fixfiles restore --- policycoreutils-rhat.patch | 24 ++++++++++++++++++++++++ policycoreutils.spec | 5 ++++- 2 files changed, 28 insertions(+), 1 deletion(-) diff --git a/policycoreutils-rhat.patch b/policycoreutils-rhat.patch index 99a228c..019d3a7 100644 --- a/policycoreutils-rhat.patch +++ b/policycoreutils-rhat.patch @@ -1463,6 +1463,30 @@ index 201a988..f5d6e9d 100644 install -m 644 chcat.8 $(MANDIR)/man8/ clean: +diff --git a/policycoreutils/scripts/fixfiles b/policycoreutils/scripts/fixfiles +index 6901e4d..337d652 100755 +--- a/policycoreutils/scripts/fixfiles ++++ b/policycoreutils/scripts/fixfiles +@@ -241,8 +241,8 @@ then + TEMPFCFILE=`mktemp ${FC}.XXXXXXXXXX` + test -z "$TEMPFCFILE" && exit + /bin/cp -p ${FC} ${TEMPFCFILE} &>/dev/null || exit +- exclude_dirs=${exclude_dirs//-e/} +- for p in ${exclude_dirs} ++ tmpdirs=${tempdirs//-e/} ++ for p in ${tmpdirs} + do + p="${p%/}" + p1="${p}(/.*)? -- <>" +@@ -253,7 +253,7 @@ FC=$TEMPFCFILE + fi + if [ -n "${FILESYSTEMSRW}" ]; then + echo "Relabeling `echo ${FILESYSTEMSRW}`" +- ${SETFILES} ${VERBOSE} -q ${FORCEFLAG} $* ${FC} ${FILESYSTEMSRW} 2>&1 | cat >> $LOGFILE ++ ${SETFILES} ${VERBOSE} $exclude_dirs -q ${FORCEFLAG} $* ${FC} ${FILESYSTEMSRW} 2>&1 | cat >> $LOGFILE + else + echo >&2 "fixfiles: No suitable file systems found" + fi diff --git a/policycoreutils/scripts/fixfiles.8 b/policycoreutils/scripts/fixfiles.8 index 9ab7334..f263805 100644 --- a/policycoreutils/scripts/fixfiles.8 diff --git a/policycoreutils.spec b/policycoreutils.spec index 361e422..e5bc11e 100644 --- a/policycoreutils.spec +++ b/policycoreutils.spec @@ -7,7 +7,7 @@ Summary: SELinux policy core utilities Name: policycoreutils Version: 2.1.14 -Release: 14%{?dist} +Release: 15%{?dist} License: GPLv2 Group: System Environment/Base # Based on git repository with tag 20101221 @@ -324,6 +324,9 @@ The policycoreutils-restorecond package contains the restorecond service. %{_bindir}/systemctl try-restart restorecond.service >/dev/null 2>&1 || : %changelog +* Thu Feb 28 2013 Dan Walsh - 2.1.14-15 +- Fix fixfiles to use exclude_dirs on fixfiles restore + * Thu Feb 28 2013 Dan Walsh - 2.1.14-14 - Allow users with symlinked homedirs to work. call realpath on homedir - Fix sepolicy reorganization of helper functions.