* Sat Jan 14 2006 Dan Walsh <dwalsh@redhat.com> 1.29.7-3
- Add check for root for semanage, genhomedircon
This commit is contained in:
parent
94d1c66432
commit
37eaabdd95
@ -1,7 +1,35 @@
|
|||||||
|
diff --exclude-from=exclude -N -u -r nsapolicycoreutils/scripts/genhomedircon policycoreutils-1.29.7/scripts/genhomedircon
|
||||||
|
--- nsapolicycoreutils/scripts/genhomedircon 2006-01-13 09:47:40.000000000 -0500
|
||||||
|
+++ policycoreutils-1.29.7/scripts/genhomedircon 2006-01-14 08:39:02.000000000 -0500
|
||||||
|
@@ -327,6 +327,9 @@
|
||||||
|
sys.stderr.write("%s: %s\n" % ( sys.argv[0], error ))
|
||||||
|
|
||||||
|
|
||||||
|
+if os.getuid() > 0 or os.geteuid() > 0:
|
||||||
|
+ print "You must be root to run %s." % sys.argv[0]
|
||||||
|
+ sys.exit(0)
|
||||||
|
|
||||||
|
#
|
||||||
|
# This script will generate home dir file context
|
||||||
diff --exclude-from=exclude -N -u -r nsapolicycoreutils/semanage/semanage policycoreutils-1.29.7/semanage/semanage
|
diff --exclude-from=exclude -N -u -r nsapolicycoreutils/semanage/semanage policycoreutils-1.29.7/semanage/semanage
|
||||||
--- nsapolicycoreutils/semanage/semanage 2006-01-13 09:47:40.000000000 -0500
|
--- nsapolicycoreutils/semanage/semanage 2006-01-13 09:47:40.000000000 -0500
|
||||||
+++ policycoreutils-1.29.7/semanage/semanage 2006-01-14 01:50:09.000000000 -0500
|
+++ policycoreutils-1.29.7/semanage/semanage 2006-01-14 08:38:35.000000000 -0500
|
||||||
@@ -186,6 +186,7 @@
|
@@ -20,10 +20,13 @@
|
||||||
|
# 02111-1307 USA
|
||||||
|
#
|
||||||
|
#
|
||||||
|
-import sys, getopt
|
||||||
|
+import os, sys, getopt
|
||||||
|
import seobject
|
||||||
|
|
||||||
|
if __name__ == '__main__':
|
||||||
|
+ if os.getuid() > 0 or os.geteuid() > 0:
|
||||||
|
+ print "You must be root to run %s." % sys.argv[0]
|
||||||
|
+ sys.exit(0)
|
||||||
|
|
||||||
|
def usage(message = ""):
|
||||||
|
print '\
|
||||||
|
@@ -186,6 +189,7 @@
|
||||||
|
|
||||||
if object == "fcontext":
|
if object == "fcontext":
|
||||||
OBJECT.add(target, setype, ftype, serange, seuser)
|
OBJECT.add(target, setype, ftype, serange, seuser)
|
||||||
@ -9,7 +37,7 @@ diff --exclude-from=exclude -N -u -r nsapolicycoreutils/semanage/semanage policy
|
|||||||
sys.exit(0);
|
sys.exit(0);
|
||||||
|
|
||||||
if modify:
|
if modify:
|
||||||
@@ -210,8 +211,13 @@
|
@@ -210,8 +214,13 @@
|
||||||
if delete:
|
if delete:
|
||||||
if object == "port":
|
if object == "port":
|
||||||
OBJECT.delete(target, proto)
|
OBJECT.delete(target, proto)
|
||||||
@ -930,3 +958,4 @@ diff --exclude-from=exclude -N -u -r nsapolicycoreutils/semanage/seobject.py pol
|
|||||||
-
|
-
|
||||||
-
|
-
|
||||||
+ print "%-50s %-18s " % (k[0], dict[k][0])
|
+ print "%-50s %-18s " % (k[0], dict[k][0])
|
||||||
|
Binary files nsapolicycoreutils/semanage/seobject.pyc and policycoreutils-1.29.7/semanage/seobject.pyc differ
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
Summary: SELinux policy core utilities.
|
Summary: SELinux policy core utilities.
|
||||||
Name: policycoreutils
|
Name: policycoreutils
|
||||||
Version: 1.29.7
|
Version: 1.29.7
|
||||||
Release: 2
|
Release: 3
|
||||||
License: GPL
|
License: GPL
|
||||||
Group: System Environment/Base
|
Group: System Environment/Base
|
||||||
Source: http://www.nsa.gov/selinux/archives/policycoreutils-%{version}.tgz
|
Source: http://www.nsa.gov/selinux/archives/policycoreutils-%{version}.tgz
|
||||||
@ -97,6 +97,9 @@ rm -rf ${RPM_BUILD_ROOT}
|
|||||||
%{_libdir}/python2.4/site-packages/seobject.py*
|
%{_libdir}/python2.4/site-packages/seobject.py*
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Sat Jan 14 2006 Dan Walsh <dwalsh@redhat.com> 1.29.7-3
|
||||||
|
- Add check for root for semanage, genhomedircon
|
||||||
|
|
||||||
* Sat Jan 14 2006 Dan Walsh <dwalsh@redhat.com> 1.29.7-2
|
* Sat Jan 14 2006 Dan Walsh <dwalsh@redhat.com> 1.29.7-2
|
||||||
- Add ivans patch
|
- Add ivans patch
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user