[arch-commits] Commit in shadow/trunk (6 files)

Dave Reisner dreisner at archlinux.org
Sat Jun 30 18:20:48 UTC 2012


    Date: Saturday, June 30, 2012 @ 14:20:48
  Author: dreisner
Revision: 162807

upgpkg: shadow 4.1.5.1-1

- remove upstreamed patches
- remove login utils moved to util-linux

Modified:
  shadow/trunk/PKGBUILD
Deleted:
  shadow/trunk/login
  shadow/trunk/nscd-error-reporting.patch
  shadow/trunk/shadow-add-missing-include.patch
  shadow/trunk/userdel-avoid-bad-mem-access.patch
  shadow/trunk/write-utmp-wtmp-entries.patch

------------------------------------+
 PKGBUILD                           |   65 +++++++++++++++++------------------
 login                              |   21 -----------
 nscd-error-reporting.patch         |   17 ---------
 shadow-add-missing-include.patch   |   11 -----
 userdel-avoid-bad-mem-access.patch |   57 ------------------------------
 write-utmp-wtmp-entries.patch      |   47 -------------------------
 6 files changed, 32 insertions(+), 186 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2012-06-30 18:13:15 UTC (rev 162806)
+++ PKGBUILD	2012-06-30 18:20:48 UTC (rev 162807)
@@ -3,8 +3,8 @@
 # Maintainer: Aaron Griffin <aaron at archlinux.org>
 
 pkgname=shadow
-pkgver=4.1.5
-pkgrel=4
+pkgver=4.1.5.1
+pkgrel=1
 pkgdesc="Password and account management tool suite with support for shadow files and PAM"
 arch=('i686' 'x86_64')
 url='http://pkg-shadow.alioth.debian.org/'
@@ -12,9 +12,9 @@
 groups=('base')
 depends=('bash' 'pam' 'acl')
 backup=(etc/login.defs
-        etc/pam.d/{chage,login,passwd,shadow,useradd,usermod,userdel}
+        etc/pam.d/{chage,passwd,shadow,useradd,usermod,userdel}
         etc/pam.d/{chpasswd,newusers,groupadd,groupdel,groupmod}
-        etc/pam.d/{chfn,chgpasswd,groupmems,chsh}
+        etc/pam.d/{chgpasswd,groupmems}
         etc/default/useradd)
 options=('!libtool')
 install='shadow.install'
@@ -24,37 +24,27 @@
         chgpasswd
         chpasswd
         defaults.pam
-        login
         login.defs
         newusers
         passwd
         shadow.cron.daily
         useradd.defaults
-        nscd-error-reporting.patch
         xstrdup.patch
-        shadow-strncpy-usage.patch
-        shadow-add-missing-include.patch
-        userdel-avoid-bad-mem-access.patch
-        write-utmp-wtmp-entries.patch)
-sha1sums=('3ab1ae0e30af36d04445314fcb5a079bdf05de41'
-          '0a31aafceb948a91fe7370a6378cafd6fd883145'
+        shadow-strncpy-usage.patch)
+sha1sums=('81f38720b953ef9c2c100c43d02dfe19cafd6c30'
+          '126570e2939bf3b57f28df5197ab9309747a6b5c'
           '33a6cf1e44a1410e5c9726c89e5de68b78f5f922'
           '78ec184a499f9708adcfcf0b7a3b22a60bf39f91'
           '4ad0e059406a305c8640ed30d93c2a1f62c2f4ad'
           '12427b1ca92a9b85ca8202239f0d9f50198b818f'
           '0e56fed7fc93572c6bf0d8f3b099166558bb46f1'
-          '895aad07c192b288b457e19dd7b8c55841b4ad22'
           'e5cab2118ecb1e61874cde842d7d04d1003f35cb'
           '12427b1ca92a9b85ca8202239f0d9f50198b818f'
           '611be25d91c3f8f307c7fe2485d5f781e5dee75f'
           '5d83ba7e11c765c951867cbe00b0ae7ff57148fa'
           '9ae93de5987dd0ae428f0cc1a5a5a5cd53583f19'
-          'ae6eebb842c433ac4022c493294a13ed68e06acc'
           '6010fffeed1fc6673ad9875492e1193b1a847b53'
-          '21e12966a6befb25ec123b403cd9b5c492fe5b16'
-          '0697a21f7519de30821da7772677035652df4ad2'
-          'e1dd93d82c6eba76b5f17a9fefad4bbc513cff5b'
-          'bcef8558c9123b396d2d4df26c815a951f97a91a')
+          '21e12966a6befb25ec123b403cd9b5c492fe5b16')
 
 build() {
   cd "$pkgname-$pkgver"
@@ -69,16 +59,6 @@
   patch -Np1 <"$srcdir/xstrdup.patch"
   patch -Np1 <"$srcdir/shadow-strncpy-usage.patch"
 
-  # backports queued for 4.1.5.1
-  patch -Np1 <"$srcdir/shadow-add-missing-include.patch"
-  patch -Np1 <"$srcdir/nscd-error-reporting.patch"
-
-  # sent to ML
-  patch -Np0 <"$srcdir/userdel-avoid-bad-mem-access.patch"
-
-  # revert to fix FS#28543
-  patch -RNp1 <"$srcdir/write-utmp-wtmp-entries.patch"
-
   # supress etc/pam.d/*, we provide our own
   sed -i '/^SUBDIRS/s/pam.d//' etc/Makefile.in
 
@@ -115,18 +95,37 @@
 
   # PAM config - custom
   install -dm755 "$pkgdir/etc/pam.d"
-  install -t "$pkgdir/etc/pam.d" -m644 "$srcdir"/{login,passwd,chgpasswd,chpasswd,newusers}
+  install -t "$pkgdir/etc/pam.d" -m644 "$srcdir"/{passwd,chgpasswd,chpasswd,newusers}
 
   # PAM config - from tarball
   install -Dm644 etc/pam.d/groupmems "$pkgdir/etc/pam.d/groupmems"
 
   # we use the 'useradd' PAM file for other similar utilities
-  for file in chage chfn chsh groupadd groupdel groupmod shadow \
+  for file in chage groupadd groupdel groupmod shadow \
       useradd usermod userdel; do
     install -Dm644 "$srcdir/defaults.pam" "$pkgdir/etc/pam.d/$file"
   done
 
-  # Remove su - using su from coreutils instead
-  rm "$pkgdir/bin/su"
-  find "$pkgdir/usr/share/man" -name 'su.1' -delete
+  # Remove utilities provided by util-linux
+  rm \
+      "$pkgdir"/usr/bin/{chsh,chfn,sg} \
+      "$pkgdir"/bin/{login,su} \
+      "$pkgdir"/usr/sbin/{vipw,vigr}
+
+  # but we keep newgrp, as sg is really an alias to it
+  mv "$pkgdir"/usr/bin/{newgrp,sg}
+
+  # ...and their many man pages
+  find "$pkgdir"/usr/share/man \
+      '(' -name 'chsh.1'  -o \
+          -name 'chfn.1'  -o \
+          -name 'su.1'    -o \
+          -name 'login.1' -o \
+          -name 'vipw.8'  -o \
+          -name 'vigr.8'  -o \
+          -name 'newgrp.1' ')' \
+      -delete
+  rmdir \
+      "$pkgdir"/usr/share/man/{fi,id,zh_TW}/man1 \
+      "$pkgdir"/usr/share/man/{fi,ko/man8}
 }

Deleted: login
===================================================================
--- login	2012-06-30 18:13:15 UTC (rev 162806)
+++ login	2012-06-30 18:20:48 UTC (rev 162807)
@@ -1,21 +0,0 @@
-#%PAM-1.0
-auth		required	pam_securetty.so
-auth		requisite	pam_nologin.so
-auth		required	pam_unix.so nullok
-auth		required	pam_tally.so onerr=succeed file=/var/log/faillog
-# use this to lockout accounts for 10 minutes after 3 failed attempts
-#auth		required	pam_tally.so deny=2 unlock_time=600 onerr=succeed file=/var/log/faillog
-account		required	pam_access.so
-account		required	pam_time.so
-account		required	pam_unix.so
-#password	required	pam_cracklib.so difok=2 minlen=8 dcredit=2 ocredit=2 retry=3
-#password	required	pam_unix.so sha512 shadow use_authtok
-session		required	pam_unix.so
-session		required	pam_env.so
-session		required	pam_motd.so
-session		required	pam_limits.so
-session		optional	pam_mail.so dir=/var/spool/mail standard
-session		optional	pam_lastlog.so
-session		optional	pam_loginuid.so
--session	optional	pam_ck_connector.so nox11
--session	optional	pam_systemd.so

Deleted: nscd-error-reporting.patch
===================================================================
--- nscd-error-reporting.patch	2012-06-30 18:13:15 UTC (rev 162806)
+++ nscd-error-reporting.patch	2012-06-30 18:20:48 UTC (rev 162807)
@@ -1,17 +0,0 @@
-diff --git a/upstream/trunk/lib/nscd.c b/upstream/trunk/lib/nscd.c
-index 227c205..7adb58f 100644
---- a/lib/nscd.c
-+++ b/lib/nscd.c
-@@ -39,8 +39,11 @@ int nscd_flush_cache (const char *service)
- 		/* nscd is not installed, or it is installed but uses an
- 		   interpreter that is missing.  Probably the former. */
- 		return 0;
-+	} else if (code == 1) {
-+		/* nscd is installed, but it isn't active. */
-+		return 0;
- 	} else if (code != 0) {
--		(void) fprintf (stderr, _("%s: nscd exited with status %d"),
-+		(void) fprintf (stderr, _("%s: nscd exited with status %d\n"),
- 		                Prog, code);
- 		(void) fprintf (stderr, _(MSG_NSCD_FLUSH_CACHE_FAILED), Prog);
- 		return -1;

Deleted: shadow-add-missing-include.patch
===================================================================
--- shadow-add-missing-include.patch	2012-06-30 18:13:15 UTC (rev 162806)
+++ shadow-add-missing-include.patch	2012-06-30 18:20:48 UTC (rev 162807)
@@ -1,11 +0,0 @@
-diff -Naur shadow-4.1.4.2+svn3283/libmisc/copydir.c shadow-4.1.4.2+svn3283.new/libmisc/copydir.c
---- shadow-4.1.4.2+svn3283/libmisc/copydir.c	2010-09-05 11:35:26.000000000 -0400
-+++ shadow-4.1.4.2+svn3283.new/libmisc/copydir.c	2011-06-26 01:26:52.000000000 -0400
-@@ -34,6 +34,7 @@
- 
- #ident "$Id: copydir.c 3283 2010-09-05 15:34:42Z nekral-guest $"
- 
-+#include <stdarg.h>
- #include <assert.h>
- #include <sys/stat.h>
- #include <sys/types.h>

Deleted: userdel-avoid-bad-mem-access.patch
===================================================================
--- userdel-avoid-bad-mem-access.patch	2012-06-30 18:13:15 UTC (rev 162806)
+++ userdel-avoid-bad-mem-access.patch	2012-06-30 18:20:48 UTC (rev 162807)
@@ -1,57 +0,0 @@
-Index: src/userdel.c
-===================================================================
---- src/userdel.c	(revision 3713)
-+++ src/userdel.c	(working copy)
-@@ -329,26 +329,33 @@
- 	}
- 
- 	if (NULL == pwd) {
-+		char gr_name[GROUP_NAME_MAX_LENGTH + 1];
-+
-+		/* make a copy of the group name before we delete it.
-+		 * we can't use ->gr_name after the group is deleted
-+		 * for logging purposes */
-+		snprintf(gr_name, GROUP_NAME_MAX_LENGTH, "%s", grp->gr_name);
-+
- 		/*
- 		 * We can remove this group, it is not the primary
- 		 * group of any remaining user.
- 		 */
--		if (gr_remove (grp->gr_name) == 0) {
-+		if (gr_remove (gr_name) == 0) {
- 			fprintf (stderr,
- 			         _("%s: cannot remove entry '%s' from %s\n"),
--			         Prog, grp->gr_name, gr_dbname ());
-+			         Prog, gr_name, gr_dbname ());
- 			fail_exit (E_GRP_UPDATE);
- 		}
- 
- #ifdef WITH_AUDIT
- 		audit_logger (AUDIT_DEL_GROUP, Prog,
- 		              "deleting group",
--		              grp->gr_name, AUDIT_NO_ID,
-+		              gr_name, AUDIT_NO_ID,
- 		              SHADOW_AUDIT_SUCCESS);
- #endif				/* WITH_AUDIT */
- 		SYSLOG ((LOG_INFO,
- 		         "removed group '%s' owned by '%s'\n",
--		         grp->gr_name, user_name));
-+		         gr_name, user_name));
- 
- #ifdef	SHADOWGRP
- 		if (sgr_locate (user_name) != NULL) {
-@@ -361,12 +368,12 @@
- #ifdef WITH_AUDIT
- 			audit_logger (AUDIT_DEL_GROUP, Prog,
- 			              "deleting shadow group",
--			              grp->gr_name, AUDIT_NO_ID,
-+			              gr_name, AUDIT_NO_ID,
- 			              SHADOW_AUDIT_SUCCESS);
- #endif				/* WITH_AUDIT */
- 			SYSLOG ((LOG_INFO,
- 			         "removed shadow group '%s' owned by '%s'\n",
--			         grp->gr_name, user_name));
-+			         gr_name, user_name));
- 
- 		}
- #endif				/* SHADOWGRP */

Deleted: write-utmp-wtmp-entries.patch
===================================================================
--- write-utmp-wtmp-entries.patch	2012-06-30 18:13:15 UTC (rev 162806)
+++ write-utmp-wtmp-entries.patch	2012-06-30 18:20:48 UTC (rev 162807)
@@ -1,47 +0,0 @@
-Index: upstream/trunk/src/login.c
-===================================================================
---- a/src/login.c	(revision 3437)
-+++ b/src/login.c	(revision 3438)
-@@ -126,10 +126,12 @@
- static void setup_tty (void);
- static void process_flags (int argc, char *const *argv);
- static /*@observer@*/const char *get_failent_user (/*@returned@*/const char *user);
-+#ifndef USE_PAM
- static void update_utmp (const char *user,
-                          const char *tty,
-                          const char *host,
-                          /*@null@*/const struct utmp *utent);
-+#endif				/* ! USE_PAM */
- 
- #ifndef USE_PAM
- static struct faillog faillog;
-@@ -471,6 +473,7 @@
- 	return failent_user;
- }
- 
-+#ifndef USE_PAM
- /*
-  * update_utmp - Update or create an utmp entry in utmp, wtmp, utmpw, and
-  *               wtmpx
-@@ -496,6 +499,7 @@
- 	free (utx);
- #endif				/* USE_UTMPX */
- }
-+#endif				/* ! USE_PAM */
- 
- /*
-  * login - create a new login session for a user
-@@ -1208,11 +1212,13 @@
- 		}
- 	}
- 
-+#ifndef USE_PAM
- 	/*
- 	 * The utmp entry needs to be updated to indicate the new status
- 	 * of the session, the new PID and SID.
- 	 */
- 	update_utmp (username, tty, hostname, utent);
-+#endif				/* ! USE_PAM */
- 
- 	/* The pwd and spwd entries for the user have been copied.
- 	 *




More information about the arch-commits mailing list