From: Daniel J Walsh <dwalsh@redhat.com>
To: SELinux <SELinux@tycho.nsa.gov>, Stephen Smalley <sds@epoch.ncsc.mil>
Subject: Change fixfiles to use file_context.local if it exists.
Date: Mon, 24 Jan 2005 11:27:28 -0500 [thread overview]
Message-ID: <41F521F0.7090108@redhat.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 1 bytes --]
[-- Attachment #2: policycoreutils-rhat.patch --]
[-- Type: text/x-patch, Size: 857 bytes --]
diff --exclude-from=exclude -N -u -r nsapolicycoreutils/scripts/fixfiles policycoreutils-1.21.1/scripts/fixfiles
--- nsapolicycoreutils/scripts/fixfiles 2005-01-24 11:19:10.103136000 -0500
+++ policycoreutils-1.21.1/scripts/fixfiles 2005-01-24 11:19:28.998223000 -0500
@@ -37,11 +37,19 @@
SELINUXTYPE="targeted"
if [ -e /etc/selinux/config ]; then
. /etc/selinux/config
- FC=/etc/selinux/${SELINUXTYPE}/contexts/files/file_contexts
+ FC=`mktemp /var/tmp/file_contexts.XXXXXX`
+ cat /etc/selinux/${SELINUXTYPE}/contexts/files/file_contexts /etc/selinux/${SELINUXTYPE}/contexts/files/file_contexts.local > $FC 2> /dev/null
else
FC=/etc/security/selinux/file_contexts
fi
+cleanup() {
+ if [ -e /etc/selinux/config -a -f "$FC" ]; then
+ rm -f $FC
+ fi
+}
+trap "cleanup" 0 1 2 3 13 15
+
#
# Log to either syslog or a LOGFILE
#
next reply other threads:[~2005-01-24 16:27 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-01-24 16:27 Daniel J Walsh [this message]
2005-01-24 16:29 ` Change fixfiles to use file_context.local if it exists Stephen Smalley
2005-01-24 17:41 ` Daniel J Walsh
2005-01-25 18:52 ` Stephen Smalley
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=41F521F0.7090108@redhat.com \
--to=dwalsh@redhat.com \
--cc=SELinux@tycho.nsa.gov \
--cc=sds@epoch.ncsc.mil \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.