fix usermod SELinux user mappings change (#458766)
This commit is contained in:
parent
be8c9d1e92
commit
60ae26e9e9
2 changed files with 41 additions and 3 deletions
33
shadow-4.1.1-selinuxUserMappings.patch
Normal file
33
shadow-4.1.1-selinuxUserMappings.patch
Normal file
|
@ -0,0 +1,33 @@
|
|||
diff -up shadow-4.1.1/src/usermod.c.selinux-user shadow-4.1.1/src/usermod.c
|
||||
--- shadow-4.1.1/src/usermod.c.selinux-user 2008-09-09 17:28:45.673915250 +0200
|
||||
+++ shadow-4.1.1/src/usermod.c 2008-09-09 17:35:39.000000000 +0200
|
||||
@@ -116,6 +116,7 @@ static int
|
||||
oflg = 0, /* permit non-unique user ID to be specified with -u */
|
||||
pflg = 0, /* new encrypted password */
|
||||
sflg = 0, /* new shell program */
|
||||
+ Sflg = 0, /* new selinux user */
|
||||
uflg = 0, /* specify new user ID */
|
||||
Uflg = 0; /* unlock the password */
|
||||
|
||||
@@ -967,8 +968,10 @@ static void process_flags (int argc, cha
|
||||
break;
|
||||
#ifdef WITH_SELINUX
|
||||
case 'Z':
|
||||
- if (is_selinux_enabled() > 0)
|
||||
- user_selinux = optarg;
|
||||
+ if (is_selinux_enabled() > 0) {
|
||||
+ user_selinux = optarg;
|
||||
+ Sflg++;
|
||||
+ }
|
||||
else {
|
||||
fprintf (stderr, _("%s: -Z requires SELinux enabled kernel\n"), Prog);
|
||||
exit (E_BAD_ARG);
|
||||
@@ -1015,7 +1018,7 @@ static void process_flags (int argc, cha
|
||||
}
|
||||
|
||||
if (Uflg + uflg + sflg + pflg + oflg + mflg + Lflg + lflg + Gflg +
|
||||
- gflg + fflg + eflg + dflg + cflg == 0) {
|
||||
+ gflg + fflg + eflg + dflg + cflg + Sflg == 0) {
|
||||
fprintf (stderr, _("%s: no changes\n"), Prog);
|
||||
exit (E_SUCCESS);
|
||||
}
|
|
@ -5,7 +5,7 @@
|
|||
Summary: Utilities for managing accounts and shadow password files
|
||||
Name: shadow-utils
|
||||
Version: 4.1.2
|
||||
Release: 6%{?dist}
|
||||
Release: 7%{?dist}
|
||||
Epoch: 2
|
||||
URL: http://pkg-shadow.alioth.debian.org/
|
||||
Source0: ftp://pkg-shadow.alioth.debian.org/pub/pkg-shadow/shadow-%{version}.tar.bz2
|
||||
|
@ -18,6 +18,7 @@ Patch2: shadow-4.1.2-selinux.patch
|
|||
Patch3: shadow-4.1.2-sysAccountDownhill.patch
|
||||
Patch4: shadow-4.1.2-gmSEGV.patch
|
||||
Patch5: shadow-4.1.2-audit.patch
|
||||
Patch6: shadow-4.1.1-selinuxUserMappings.patch
|
||||
|
||||
License: BSD
|
||||
Group: System Environment/Base
|
||||
|
@ -48,6 +49,7 @@ are used for managing group accounts.
|
|||
%patch3 -p1 -b .sysAccountDownhill
|
||||
%patch4 -p1 -b .gmSEGV
|
||||
%patch5 -p1 -b .audit
|
||||
%patch6 -p1 -b .selinuxUserMappings
|
||||
|
||||
|
||||
rm po/*.gmo
|
||||
|
@ -188,10 +190,13 @@ rm -rf $RPM_BUILD_ROOT
|
|||
%{_mandir}/man8/vigr.8*
|
||||
|
||||
%changelog
|
||||
* Thu Sep 02 2008 Peter Vrabec <pvrabec@redhat.com> 2:4.1.2-6
|
||||
* Thu Sep 11 2008 Peter Vrabec <pvrabec@redhat.com> 2:4.1.2-7
|
||||
- fix usermod SELinux user mappings change (#458766)
|
||||
|
||||
* Tue Sep 02 2008 Peter Vrabec <pvrabec@redhat.com> 2:4.1.2-6
|
||||
- audit improvements, thnx. to sgrubb@redhat.com
|
||||
|
||||
* Thu Sep 02 2008 Peter Vrabec <pvrabec@redhat.com> 2:4.1.2-5
|
||||
* Tue Sep 02 2008 Peter Vrabec <pvrabec@redhat.com> 2:4.1.2-5
|
||||
- fix groupmems issues (#459825)
|
||||
|
||||
* Mon Jul 28 2008 Peter Vrabec <pvrabec@redhat.com> 2:4.1.2-4
|
||||
|
|
Loading…
Reference in a new issue