[policycoreutils] Fix semanage fcontext -E to extract the equivalance customizations.

Daniel J Walsh dwalsh at fedoraproject.org
Mon Apr 30 19:05:30 UTC 2012


commit 01c8a3601eb759e2cba16ca7a9a333da22362c98
Author: Dan Walsh <dwalsh at redhat.com>
Date:   Mon Apr 30 15:05:24 2012 -0400

    Fix semanage fcontext -E to extract the equivalance customizations.

 policycoreutils-rhat.patch |   13 ++++++++++++-
 policycoreutils.spec       |    5 ++++-
 2 files changed, 16 insertions(+), 2 deletions(-)
---
diff --git a/policycoreutils-rhat.patch b/policycoreutils-rhat.patch
index fecdb03..74d190d 100644
--- a/policycoreutils-rhat.patch
+++ b/policycoreutils-rhat.patch
@@ -245946,7 +245946,7 @@ index c5e18d9..9e086d1 100644
  .I                \-R, \-\-role
  SELinux Roles.  You must enclose multiple roles within quotes, separate by spaces. Or specify \-R multiple times.
 diff --git a/policycoreutils/semanage/seobject.py b/policycoreutils/semanage/seobject.py
-index 9745102..12cd0fe 100644
+index 9745102..28cf30e 100644
 --- a/policycoreutils/semanage/seobject.py
 +++ b/policycoreutils/semanage/seobject.py
 @@ -30,11 +30,10 @@ from IPy import IP
@@ -246016,6 +246016,17 @@ index 9745102..12cd0fe 100644
  
  		(rc, fcontext) = semanage_fcontext_create(self.sh)
  		if rc < 0:
+@@ -1920,6 +1925,10 @@ class fcontextRecords(semanageRecords):
+                for k in keys:
+                       if fcon_dict[k]:
+                              l.append("-a -f '%s' -t %s '%s'" % (k[1], fcon_dict[k][2], k[0]))
++
++	       if len(self.equiv):
++                      for target in self.equiv.keys():
++			     l.append("-a -e %s %s" % (target, self.equiv[target]))
+                return l
+ 
+ 	def list(self, heading = 1, locallist = 0 ):
 diff --git a/policycoreutils/setfiles/restore.c b/policycoreutils/setfiles/restore.c
 index 9a7d315..1b59e2f 100644
 --- a/policycoreutils/setfiles/restore.c
diff --git a/policycoreutils.spec b/policycoreutils.spec
index d25babe..66f70da 100644
--- a/policycoreutils.spec
+++ b/policycoreutils.spec
@@ -7,7 +7,7 @@
 Summary: SELinux policy core utilities
 Name:	 policycoreutils
 Version: 2.1.11
-Release: 8%{?dist}
+Release: 9%{?dist}
 License: GPLv2
 Group:	 System Environment/Base
 # Based on git repository with tag 20101221
@@ -340,6 +340,9 @@ fi
 %{_bindir}/systemctl try-restart restorecond.service >/dev/null 2>&1 || :
 
 %changelog
+* Mon Apr 30 2012 Dan Walsh <dwalsh at redhat.com> - 2.1.11-9
+- Fix semanage fcontext -E to extract the equivalance customizations.
+
 * Tue Apr 26 2012 Dan Walsh <dwalsh at redhat.com> - 2.1.11-8
 - Add mgrepl patch to have sepolgen search for -systemd rpm packages
 


More information about the scm-commits mailing list