From 211f960162021852a99382226b15a6fd19279066 Mon Sep 17 00:00:00 2001 From: Daniel J Walsh Date: Wed, 15 Nov 2006 21:34:02 +0000 Subject: [PATCH] * Wed Nov 15 2006 Dan Walsh 1.33.1-5 - Fix audit2allow to generate referene policy --- policycoreutils-rhat.patch | 43 ++++++++++++++++++++++++++++++++++++++ policycoreutils.spec | 5 ++++- 2 files changed, 47 insertions(+), 1 deletion(-) diff --git a/policycoreutils-rhat.patch b/policycoreutils-rhat.patch index 553bf65..0d71a28 100644 --- a/policycoreutils-rhat.patch +++ b/policycoreutils-rhat.patch @@ -1,3 +1,46 @@ +diff --exclude-from=exclude --exclude='*.po' --exclude='*.pot' -N -u -r nsapolicycoreutils/audit2allow/audit2allow policycoreutils-1.33.1/audit2allow/audit2allow +--- nsapolicycoreutils/audit2allow/audit2allow 2006-09-14 08:07:24.000000000 -0400 ++++ policycoreutils-1.33.1/audit2allow/audit2allow 2006-11-15 16:29:10.000000000 -0500 +@@ -184,22 +184,26 @@ + output.write(serules.out(requires, module)) + output.flush() + if buildPP: +- cmd = "checkmodule %s -m -o %s.mod %s.te" % (get_mls_flag(), module, module) +- print _("Compiling policy") +- print cmd +- rc = commands.getstatusoutput(cmd) +- if rc[0] == 0: +- cmd = "semodule_package -o %s.pp -m %s.mod" % (module, module) +- if fc_file != "": +- cmd = "%s -f %s" % (cmd, fc_file) +- ++ if ref_ind: ++ cmd = "make -f /usr/share/selinux/devel/Makefile %s.pp" % module ++ print _("Compiling policy") ++ print cmd ++ rc = commands.getstatusoutput(cmd) ++ else: ++ cmd = "checkmodule %s -m -o %s.mod %s.te" % (get_mls_flag(), module, module) ++ print _("Compiling policy") + print cmd + rc = commands.getstatusoutput(cmd) + if rc[0] == 0: +- print _("\n******************** IMPORTANT ***********************\n") +- print (_("In order to load this newly created policy package into the kernel,\nyou are required to execute \n\nsemodule -i %s.pp\n\n") % module) +- else: +- errorExit(rc[1]) ++ cmd = "semodule_package -o %s.pp -m %s.mod" % (module, module) ++ if fc_file != "": ++ cmd = "%s -f %s" % (cmd, fc_file) ++ ++ print cmd ++ rc = commands.getstatusoutput(cmd) ++ if rc[0] == 0: ++ print _("\n******************** IMPORTANT ***********************\n") ++ print (_("In order to load this newly created policy package into the kernel,\nyou are required to execute \n\nsemodule -i %s.pp\n\n") % module) + else: + errorExit(rc[1]) + diff --exclude-from=exclude --exclude='*.po' --exclude='*.pot' -N -u -r nsapolicycoreutils/gui/booleansPage.py policycoreutils-1.33.1/gui/booleansPage.py --- nsapolicycoreutils/gui/booleansPage.py 1969-12-31 19:00:00.000000000 -0500 +++ policycoreutils-1.33.1/gui/booleansPage.py 2006-11-14 09:54:05.000000000 -0500 diff --git a/policycoreutils.spec b/policycoreutils.spec index ee32e49..f797fdc 100644 --- a/policycoreutils.spec +++ b/policycoreutils.spec @@ -5,7 +5,7 @@ Summary: SELinux policy core utilities. Name: policycoreutils Version: 1.33.1 -Release: 4 +Release: 5 License: GPL Group: System Environment/Base Source: http://www.nsa.gov/selinux/archives/policycoreutils-%{version}.tgz @@ -168,6 +168,9 @@ fi [ -x /sbin/service ] && /sbin/service restorecond condrestart %changelog +* Wed Nov 15 2006 Dan Walsh 1.33.1-5 +- Fix audit2allow to generate referene policy + * Wed Nov 15 2006 Dan Walsh 1.33.1-4 - Add group sort for portsPage.py - Add enable/disableaudit to modules page