diff options
author | Mike Frysinger <vapier@gentoo.org> | 2007-02-18 13:41:30 +0000 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2007-02-18 13:41:30 +0000 |
commit | 370c19aaafb7b0c28c6daef6f73928827ec5b49b (patch) | |
tree | 9d95e339e570b7124ac4ede2f3ec208950e0f28b /sys-apps/shadow | |
parent | Stable on Alpha. (diff) | |
download | gentoo-2-370c19aaafb7b0c28c6daef6f73928827ec5b49b.tar.gz gentoo-2-370c19aaafb7b0c28c6daef6f73928827ec5b49b.tar.bz2 gentoo-2-370c19aaafb7b0c28c6daef6f73928827ec5b49b.zip |
old
(Portage version: 2.1.2-r9)
Diffstat (limited to 'sys-apps/shadow')
23 files changed, 0 insertions, 1425 deletions
diff --git a/sys-apps/shadow/files/digest-shadow-4.0.15-r2 b/sys-apps/shadow/files/digest-shadow-4.0.15-r2 deleted file mode 100644 index 13dd58252a59..000000000000 --- a/sys-apps/shadow/files/digest-shadow-4.0.15-r2 +++ /dev/null @@ -1,3 +0,0 @@ -MD5 a0452fa989f8ba45023cc5a08136568e shadow-4.0.15.tar.bz2 1294860 -RMD160 b7b9ee9469561205037a1eacaa8791f069ba124c shadow-4.0.15.tar.bz2 1294860 -SHA256 e486bdb083df453c2d15ac58887ef45a3006182c0cdb1c6092058ea588be538d shadow-4.0.15.tar.bz2 1294860 diff --git a/sys-apps/shadow/files/digest-shadow-4.0.16-r2 b/sys-apps/shadow/files/digest-shadow-4.0.16-r2 deleted file mode 100644 index e6b69a954530..000000000000 --- a/sys-apps/shadow/files/digest-shadow-4.0.16-r2 +++ /dev/null @@ -1,3 +0,0 @@ -MD5 1d91f7479143d1d705b94180c0d4874b shadow-4.0.16.tar.bz2 1438030 -RMD160 9ac436d89913441b448da90ece25b77e818f3bd4 shadow-4.0.16.tar.bz2 1438030 -SHA256 2cbd0af0b4682d91282d2d0ad3110e6dfcad4e365d25a3b6beaf7048dd477bdd shadow-4.0.16.tar.bz2 1438030 diff --git a/sys-apps/shadow/files/digest-shadow-4.0.17 b/sys-apps/shadow/files/digest-shadow-4.0.17 deleted file mode 100644 index 1e8116ed5aa9..000000000000 --- a/sys-apps/shadow/files/digest-shadow-4.0.17 +++ /dev/null @@ -1,3 +0,0 @@ -MD5 bc5972a195290533b4c0576276056ed9 shadow-4.0.17.tar.bz2 1496220 -RMD160 590fbe5d0363da44370b026282c8226ee64f4603 shadow-4.0.17.tar.bz2 1496220 -SHA256 6e85b7a01d311fdb181d909b00c6e42bf08816c13e7f54d6dcc1d7a342ef98cd shadow-4.0.17.tar.bz2 1496220 diff --git a/sys-apps/shadow/files/digest-shadow-4.0.17-r1 b/sys-apps/shadow/files/digest-shadow-4.0.17-r1 deleted file mode 100644 index 1e8116ed5aa9..000000000000 --- a/sys-apps/shadow/files/digest-shadow-4.0.17-r1 +++ /dev/null @@ -1,3 +0,0 @@ -MD5 bc5972a195290533b4c0576276056ed9 shadow-4.0.17.tar.bz2 1496220 -RMD160 590fbe5d0363da44370b026282c8226ee64f4603 shadow-4.0.17.tar.bz2 1496220 -SHA256 6e85b7a01d311fdb181d909b00c6e42bf08816c13e7f54d6dcc1d7a342ef98cd shadow-4.0.17.tar.bz2 1496220 diff --git a/sys-apps/shadow/files/pam.d/login b/sys-apps/shadow/files/pam.d/login deleted file mode 100644 index 31a664b302ae..000000000000 --- a/sys-apps/shadow/files/pam.d/login +++ /dev/null @@ -1,12 +0,0 @@ -#%PAM-1.0 - -auth required pam_securetty.so -auth required pam_stack.so service=system-auth -auth required pam_nologin.so - -account required pam_stack.so service=system-auth - -password required pam_stack.so service=system-auth - -session required pam_stack.so service=system-auth -session optional pam_console.so diff --git a/sys-apps/shadow/files/pam.d/other b/sys-apps/shadow/files/pam.d/other deleted file mode 100644 index bb0b9647c076..000000000000 --- a/sys-apps/shadow/files/pam.d/other +++ /dev/null @@ -1,9 +0,0 @@ -#%PAM-1.0 - -auth required pam_deny.so - -account required pam_deny.so - -password required pam_deny.so - -session required pam_deny.so diff --git a/sys-apps/shadow/files/pam.d/passwd b/sys-apps/shadow/files/pam.d/passwd deleted file mode 100644 index c09409bb3a16..000000000000 --- a/sys-apps/shadow/files/pam.d/passwd +++ /dev/null @@ -1,7 +0,0 @@ -#%PAM-1.0 - -auth required pam_stack.so service=system-auth - -account required pam_stack.so service=system-auth - -password required pam_stack.so service=system-auth diff --git a/sys-apps/shadow/files/pam.d/shadow b/sys-apps/shadow/files/pam.d/shadow deleted file mode 100644 index 28db08c25c6f..000000000000 --- a/sys-apps/shadow/files/pam.d/shadow +++ /dev/null @@ -1,8 +0,0 @@ -#%PAM-1.0 - -auth sufficient pam_rootok.so -auth required pam_permit.so - -account required pam_stack.so service=system-auth - -password required pam_permit.so diff --git a/sys-apps/shadow/files/pam.d/su b/sys-apps/shadow/files/pam.d/su deleted file mode 100644 index e5b1d834f3f1..000000000000 --- a/sys-apps/shadow/files/pam.d/su +++ /dev/null @@ -1,32 +0,0 @@ -#%PAM-1.0 - -auth sufficient pam_rootok.so - -# If you want to restrict users begin allowed to su even more, -# create /etc/security/suauth.allow (or to that matter) that is only -# writable by root, and add users that are allowed to su to that -# file, one per line. -#auth required pam_listfile.so item=ruser sense=allow onerr=fail file=/etc/security/suauth.allow - -# Uncomment this to allow users in the wheel group to su without -# entering a passwd. -#auth sufficient pam_wheel.so use_uid trust - -# Alternatively to above, you can implement a list of users that do -# not need to supply a passwd with a list. -#auth sufficient pam_listfile.so item=ruser sense=allow onerr=fail file=/etc/security/suauth.nopass - -# Comment this to allow any user, even those not in the 'wheel' -# group to su -auth required pam_wheel.so use_uid - -auth required pam_stack.so service=system-auth - -account required pam_stack.so service=system-auth - -password required pam_stack.so service=system-auth - -session required pam_stack.so service=system-auth -session required pam_env.so -session optional pam_xauth.so - diff --git a/sys-apps/shadow/files/pam.d/system-auth b/sys-apps/shadow/files/pam.d/system-auth deleted file mode 100644 index d6d008f69bde..000000000000 --- a/sys-apps/shadow/files/pam.d/system-auth +++ /dev/null @@ -1,14 +0,0 @@ -#%PAM-1.0 - -auth required pam_env.so -auth sufficient pam_unix.so likeauth nullok nodelay -auth required pam_deny.so - -account required pam_unix.so - -password required pam_cracklib.so retry=3 -password sufficient pam_unix.so nullok md5 shadow use_authtok -password required pam_deny.so - -session required pam_limits.so -session required pam_unix.so diff --git a/sys-apps/shadow/files/pam.d/system-auth-1.1 b/sys-apps/shadow/files/pam.d/system-auth-1.1 deleted file mode 100644 index fe80483120ae..000000000000 --- a/sys-apps/shadow/files/pam.d/system-auth-1.1 +++ /dev/null @@ -1,14 +0,0 @@ -#%PAM-1.0 - -auth required pam_env.so -auth sufficient pam_unix.so likeauth nullok -auth required pam_deny.so - -account required pam_unix.so - -password required pam_cracklib.so retry=3 -password sufficient pam_unix.so nullok md5 shadow use_authtok -password required pam_deny.so - -session required pam_limits.so -session required pam_unix.so diff --git a/sys-apps/shadow/files/shadow-4.0.13-login.defs.patch b/sys-apps/shadow/files/shadow-4.0.13-login.defs.patch deleted file mode 100644 index 4ac4b4ec5513..000000000000 --- a/sys-apps/shadow/files/shadow-4.0.13-login.defs.patch +++ /dev/null @@ -1,25 +0,0 @@ -Index: etc/login.defs -=================================================================== -RCS file: /cvsroot/shadow/etc/login.defs,v -retrieving revision 1.8 -diff -u -p -U0 -r1.8 login.defs ---- etc/login.defs 1 Sep 2005 19:57:45 -0000 1.8 -+++ etc/login.defs 10 Oct 2005 22:17:39 -0000 -@@ -38 +38 @@ --MAIL_CHECK_ENAB yes -+MAIL_CHECK_ENAB no -@@ -205 +205 @@ --SU_WHEEL_ONLY no -+SU_WHEEL_ONLY yes -@@ -210 +210 @@ --CRACKLIB_DICTPATH /var/cache/cracklib/cracklib_dict -+CRACKLIB_DICTPATH /usr/lib/cracklib_dict -@@ -227 +227 @@ --LOGIN_RETRIES 5 -+LOGIN_RETRIES 3 -@@ -279 +279 @@ --#MD5_CRYPT_ENAB no -+MD5_CRYPT_ENAB yes -@@ -330 +330 @@ --#GETPASS_ASTERISKS 1 -+GETPASS_ASTERISKS 0 diff --git a/sys-apps/shadow/files/shadow-4.0.13-su-fix-environment.patch b/sys-apps/shadow/files/shadow-4.0.13-su-fix-environment.patch deleted file mode 100644 index 5db08fd5fd73..000000000000 --- a/sys-apps/shadow/files/shadow-4.0.13-su-fix-environment.patch +++ /dev/null @@ -1,39 +0,0 @@ -The patch from upstream (shadow-4.0.11.1-SUPATH.patch) sets environ too -early when using PAM, so move it to !USE_PAM. Also set USER and SHELL. - ---- shadow-4.0.11.1/src/su.c 2005-08-04 12:34:35.000000000 +0200 -+++ shadow-4.0.11.1.az/src/su.c 2005-08-04 12:38:57.000000000 +0200 -@@ -594,11 +594,6 @@ - addenv ("PATH", cp); - } - --#ifndef USE_PAM -- /* setup the environment for PAM later on, else we run into auth problems */ -- environ = newenvp; /* make new environment active */ --#endif -- - if (getenv ("IFS")) /* don't export user IFS ... */ - addenv ("IFS= \t\n", NULL); /* ... instead, set a safe IFS */ - -@@ -666,6 +664,8 @@ - exit (1); - } - #else /* !USE_PAM */ -+ environ = newenvp; /* make new environment active */ -+ - if (!amroot) /* no limits if su from root */ - setup_limits (&pwent); - -@@ -676,8 +676,11 @@ - if (fakelogin) - setup_env (&pwent); - #if 1 /* Suggested by Joey Hess. XXX - is this right? */ -- else -+ else { - addenv ("HOME", pwent.pw_dir); -+ addenv ("USER", pwent.pw_name); -+ addenv ("SHELL", pwent.pw_shell); -+ } - #endif - - /* diff --git a/sys-apps/shadow/files/shadow-4.0.14-su-fix-environment.patch b/sys-apps/shadow/files/shadow-4.0.14-su-fix-environment.patch deleted file mode 100644 index b537c7be19f0..000000000000 --- a/sys-apps/shadow/files/shadow-4.0.14-su-fix-environment.patch +++ /dev/null @@ -1,26 +0,0 @@ -The patch from upstream (shadow-4.0.11.1-SUPATH.patch) sets environ too -early when using PAM, so move it to !USE_PAM. - ---- shadow-4.0.14/src/su.c -+++ shadow-4.0.14/src/su.c -@@ -594,11 +594,6 @@ - addenv ("PATH", cp); - } - --#ifndef USE_PAM -- /* setup the environment for PAM later on, else we run into auth problems */ -- environ = newenvp; /* make new environment active */ --#endif -- - if (getenv ("IFS")) /* don't export user IFS ... */ - addenv ("IFS= \t\n", NULL); /* ... instead, set a safe IFS */ - -@@ -666,6 +664,8 @@ - exit (1); - } - #else /* !USE_PAM */ -+ environ = newenvp; /* make new environment active */ -+ - if (!amroot) /* no limits if su from root */ - setup_limits (&pwent); - diff --git a/sys-apps/shadow/files/shadow-4.0.15-no-default-MAIL.patch b/sys-apps/shadow/files/shadow-4.0.15-no-default-MAIL.patch deleted file mode 100644 index f7972933aabe..000000000000 --- a/sys-apps/shadow/files/shadow-4.0.15-no-default-MAIL.patch +++ /dev/null @@ -1,30 +0,0 @@ -if MAIL_CHECK_ENAB is disabled, then don't export the MAIL envvar - ---- libmisc/setupenv.c -+++ libmisc/setupenv.c -@@ -265,16 +265,18 @@ - * knows the prefix. - */ - -- if ((cp = getdef_str ("MAIL_DIR"))) -- addenv_path ("MAIL", cp, info->pw_name); -- else if ((cp = getdef_str ("MAIL_FILE"))) -- addenv_path ("MAIL", info->pw_dir, cp); -- else { -+ if (getdef_bool ("MAIL_CHECK_ENAB")) { -+ if ((cp = getdef_str ("MAIL_DIR"))) -+ addenv_path ("MAIL", cp, info->pw_name); -+ else if ((cp = getdef_str ("MAIL_FILE"))) -+ addenv_path ("MAIL", info->pw_dir, cp); -+ else { - #if defined(MAIL_SPOOL_FILE) -- addenv_path ("MAIL", info->pw_dir, MAIL_SPOOL_FILE); -+ addenv_path ("MAIL", info->pw_dir, MAIL_SPOOL_FILE); - #elif defined(MAIL_SPOOL_DIR) -- addenv_path ("MAIL", MAIL_SPOOL_DIR, info->pw_name); -+ addenv_path ("MAIL", MAIL_SPOOL_DIR, info->pw_name); - #endif -+ } - } - - /* diff --git a/sys-apps/shadow/files/shadow-4.0.15-sanity-checks.patch b/sys-apps/shadow/files/shadow-4.0.15-sanity-checks.patch deleted file mode 100644 index 2bced657b4aa..000000000000 --- a/sys-apps/shadow/files/shadow-4.0.15-sanity-checks.patch +++ /dev/null @@ -1,75 +0,0 @@ -=================================================================== -RCS file: /cvsroot/shadow/src/useradd.c,v -retrieving revision 1.93 -retrieving revision 1.94 -diff -u -r1.93 -r1.94 ---- shadow/src/useradd.c 2006/05/07 17:44:39 1.93 -+++ shadow/src/useradd.c 2006/05/19 13:36:25 1.94 -@@ -1585,46 +1585,38 @@ - */ - static void create_mail (void) - { -- char *ms; -+ char *spool, *file; - int fd; -- struct group *mail; -- gid_t mail_gid; -+ struct group *gr; -+ gid_t gid; - mode_t mode; - -+ spool = getdef_str ("MAIL_DIR") ? : "/var/mail"; -+ file = alloca (strlen (spool) + strlen (user_name) + 2); -+ sprintf (file, "%s/%s", spool, user_name); -+ fd = open (file, O_CREAT | O_WRONLY | O_TRUNC | O_EXCL, 0); -+ if (fd < 0) { -+ perror (_("Creating mailbox")); -+ return; -+ } -+ - if (strcasecmp (create_mail_spool, "yes") == 0) { -- mail = getgrnam ("mail"); -- if (mail == NULL) { -+ gr = getgrnam ("mail"); -+ if (!gr) { - fprintf (stderr, - _ -- ("No group named \"mail\" exists, creating mail spool with mode 0600.\n")); -+ ("Group 'mail' not found. Creating the mailbox with 0600 mode.\n")); -+ gid = user_gid; - mode = 0600; -- mail_gid = user_gid; - } else { -+ gid = gr->gr_gid; - mode = 0660; -- mail_gid = mail->gr_gid; - } - -- ms = malloc (strlen (user_name) + 11); -- if (ms != NULL) { -- sprintf (ms, "/var/mail/%s", user_name); -- if (access (ms, R_OK) != 0) { -- fd = open (ms, -- O_CREAT | O_EXCL | -- O_WRONLY | O_TRUNC, 0); -- if (fd != -1) { -- fchown (fd, user_id, mail_gid); -- fchmod (fd, mode); -- close (fd); -- } -- } else { -- fprintf (stderr, -- _ -- ("Can't create mail spool for user %s.\n"), -- user_name); -- fail_exit (E_MAIL_SPOOL); -- } -- } -- free (ms); -+ if (fchown (fd, user_id, gid) || fchmod (fd, mode)) -+ perror (_("Setting mailbox permissions")); -+ -+ close (fd); - } - } - diff --git a/sys-apps/shadow/files/shadow-4.0.16-check-opendir.patch b/sys-apps/shadow/files/shadow-4.0.16-check-opendir.patch deleted file mode 100644 index e0403cbaa654..000000000000 --- a/sys-apps/shadow/files/shadow-4.0.16-check-opendir.patch +++ /dev/null @@ -1,21 +0,0 @@ -http://bugs.gentoo.org/139148 - -e-mailed upstream - -Index: libmisc/copydir.c -=================================================================== -RCS file: /cvsroot/shadow/libmisc/copydir.c,v -retrieving revision 1.14 -diff -u -p -r1.14 copydir.c ---- libmisc/copydir.c 7 May 2006 18:10:10 -0000 1.14 -+++ libmisc/copydir.c 4 Jul 2006 19:42:22 -0000 -@@ -396,7 +396,8 @@ int remove_tree (const char *root) - * is made set-ID. - */ - -- dir = opendir (root); -+ if (!(dir = opendir (root))) -+ return -1; - - while ((ent = readdir (dir))) { - diff --git a/sys-apps/shadow/files/shadow-4.0.16-mail-creation.patch b/sys-apps/shadow/files/shadow-4.0.16-mail-creation.patch deleted file mode 100644 index f4772a0ffec1..000000000000 --- a/sys-apps/shadow/files/shadow-4.0.16-mail-creation.patch +++ /dev/null @@ -1,64 +0,0 @@ -rip out fixes from upstream for mail creation bug - -http://bugs.gentoo.org/139346 - -Index: useradd.c -=================================================================== -RCS file: /cvsroot/shadow/src/useradd.c,v -retrieving revision 1.96 -retrieving revision 1.99 -diff -u -p -r1.96 -r1.99 ---- shadow/src/useradd.c 30 May 2006 18:28:45 -0000 1.96 -+++ shadow/src/useradd.c 22 Jun 2006 11:30:32 -0000 1.99 -@@ -1246,6 +1247,11 @@ static void process_flags (int argc, cha - - if (!sflg) - user_shell = def_shell; -+ -+ /* TODO: add handle change default spool mail creation by -+ -K CREATE_MAIL_SPOOL={yes,no}. It need rewrite internal API for handle -+ shadow tools configuration */ -+ create_mail_spool = def_create_mail_spool; - } - - /* -@@ -1599,24 +1605,24 @@ static void create_mail (void) - if (fd < 0) { - perror (_("Creating mailbox file")); - return; -+ } - -- gr = getgrnam ("mail"); -- if (!gr) { -- fprintf (stderr, -- _ -- ("Group 'mail' not found. Creating the user mailbox file with 0600 mode.\n")); -- gid = user_gid; -- mode = 0600; -- } else { -- gid = gr->gr_gid; -- mode = 0660; -- } -+ gr = getgrnam ("mail"); -+ if (!gr) { -+ fprintf (stderr, -+ _ -+ ("Group 'mail' not found. Creating the user mailbox file with 0600 mode.\n")); -+ gid = user_gid; -+ mode = 0600; -+ } else { -+ gid = gr->gr_gid; -+ mode = 0660; -+ } - -- if (fchown (fd, user_id, gid) || fchmod (fd, mode)) -- perror (_("Setting mailbox file permissions")); -+ if (fchown (fd, user_id, gid) || fchmod (fd, mode)) -+ perror (_("Setting mailbox file permissions")); - -- close (fd); -- } -+ close (fd); - } - } - diff --git a/sys-apps/shadow/files/shadow-4.0.17-no-local-getpass.patch b/sys-apps/shadow/files/shadow-4.0.17-no-local-getpass.patch deleted file mode 100644 index 3292e9a46096..000000000000 --- a/sys-apps/shadow/files/shadow-4.0.17-no-local-getpass.patch +++ /dev/null @@ -1,23 +0,0 @@ -libshadow_getpass() was punted in 4.0.17 - -http://bugs.gentoo.org/139966 - -Patch by Ulrich Mueller - -Index: configure.in -=================================================================== -RCS file: /cvsroot/shadow/configure.in,v -retrieving revision 1.145 -diff -u -p -r1.145 configure.in ---- configure.in 25 Jun 2006 12:30:47 -0000 1.145 -+++ configure.in 15 Jul 2006 04:51:29 -0000 -@@ -329,9 +329,6 @@ if test "$with_skey" = "yes"; then - ],[ - skeychallenge((void*)0, (void*)0, (void*)0, 0); - ],[AC_DEFINE(SKEY_BSD_STYLE, 1, [Define to support newer BSD S/Key API])]) -- dnl libshadow_getpass() handles password prompt with enabled echo -- AC_DEFINE(getpass, libshadow_getpass, -- [Define to libshadow_getpass to use our own version of getpass().]) - fi - - AM_GNU_GETTEXT_VERSION(0.12.1) diff --git a/sys-apps/shadow/shadow-4.0.15-r2.ebuild b/sys-apps/shadow/shadow-4.0.15-r2.ebuild deleted file mode 100644 index c4ca34298b09..000000000000 --- a/sys-apps/shadow/shadow-4.0.15-r2.ebuild +++ /dev/null @@ -1,264 +0,0 @@ -# Copyright 1999-2006 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/sys-apps/shadow/shadow-4.0.15-r2.ebuild,v 1.12 2006/10/17 14:21:36 dsd Exp $ - -inherit eutils libtool toolchain-funcs flag-o-matic autotools pam - -# We should remove this login after pam-0.78 goes stable. -FORCE_SYSTEMAUTH_UPDATE="no" - -DESCRIPTION="Utilities to deal with user accounts" -HOMEPAGE="http://shadow.pld.org.pl/" -SRC_URI="ftp://ftp.pld.org.pl/software/${PN}/${P}.tar.bz2" - -LICENSE="BSD" -SLOT="0" -KEYWORDS="alpha amd64 arm hppa ia64 m68k mips ppc ppc64 s390 sh sparc x86" -IUSE="nls pam selinux skey nousuid cracklib" - -RDEPEND="cracklib? ( >=sys-libs/cracklib-2.7-r3 ) - pam? ( virtual/pam ) - !sys-apps/pam-login - skey? ( app-admin/skey ) - selinux? ( >=sys-libs/libselinux-1.28 ) - nls? ( virtual/libintl )" -DEPEND="${RDEPEND} - >=sys-apps/portage-2.0.51-r2 - nls? ( sys-devel/gettext )" - -src_unpack() { - unpack ${A} - cd "${S}" - - # uclibc support, corrects NIS usage - epatch "${FILESDIR}"/${PN}-4.0.13-nonis.patch - - # If su should not simulate a login shell, use '/bin/sh' as shell to enable - # running of commands as user with /bin/false as shell, closing bug #15015. - # *** This one could be a security hole; disable for now *** - #epatch "${FILESDIR}"/${P}-nologin-run-sh.patch - - # tweak the default login.defs - epatch "${FILESDIR}"/${PN}-4.0.13-login.defs.patch - - # Make user/group names more flexible #3485 / #22920 - epatch "${FILESDIR}"/${PN}-4.0.13-dots-in-usernames.patch - epatch "${FILESDIR}"/${PN}-4.0.13-long-groupnames.patch - - # Fix compiling with gcc-2.95.x - epatch "${FILESDIR}"/${PN}-4.0.12-gcc2.patch - - # Patch from upstream enables the new environment too early for PAM - epatch "${FILESDIR}"/${PN}-4.0.14-su-fix-environment.patch - - # lock down setuid perms #47208 - epatch "${FILESDIR}"/${PN}-4.0.11.1-perms.patch - - epatch "${FILESDIR}"/${PN}-4.0.15-uclibc-missing-l64a.patch - epatch "${FILESDIR}"/${PN}-4.0.15-no-default-MAIL.patch - epatch "${FILESDIR}"/${PN}-4.0.15-sanity-checks.patch #133615 - - # Needed by the UCLIBC patches - eautoconf || die - - elibtoolize - epunt_cxx -} - -src_compile() { - append-ldflags $(bindnow-flags) - tc-is-cross-compiler && export ac_cv_func_setpgrp_void=yes - econf \ - --disable-desrpc \ - --with-libcrypt \ - --enable-shared=no \ - --enable-static=yes \ - $(use_with cracklib libcrack) \ - $(use_with pam libpam) \ - $(use_with skey) \ - $(use_with selinux) \ - $(use_enable nls) \ - || die "bad configure" - emake || die "compile problem" -} - -src_install() { - local perms=4711 - use nousuid && perms=711 - make DESTDIR=${D} suiduperms=${perms} install || die "install problem" - dosym useradd /usr/sbin/adduser - - # Remove libshadow and libmisc; see bug 37725 and the following - # comment from shadow's README.linux: - # Currently, libshadow.a is for internal use only, so if you see - # -lshadow in a Makefile of some other package, it is safe to - # remove it. - rm -f "${D}"/{,usr/}$(get_libdir)/lib{misc,shadow}.{a,la} - - insinto /etc - # Using a securetty with devfs device names added - # (compat names kept for non-devfs compatibility) - insopts -m0600 ; doins "${FILESDIR}"/securetty - if ! use pam; then - insopts -m0600 - doins etc/login.access etc/limits - else - newpamd "${FILESDIR}/login.pamd" login - use selinux || sed -i -e '/@selinux@/d' ${D}/etc/pam.d/login - use selinux && sed -i -e 's:@selinux@::g' ${D}/etc/pam.d/login - - insinto /etc - insopts -m0644 - newins "${FILESDIR}/login.defs" login.defs - - # Also install another one that we can use to check if - # we need to update it if FORCE_LOGIN_DEFS = "yes" - [ "${FORCE_LOGIN_DEFS}" = "yes" ] \ - && newins "${FILESDIR}/login.defs" login.defs.new - fi - # Output arch-specific cruft - case $(tc-arch) in - ppc*) echo "hvc0" >> "${D}"/etc/securetty - echo "hvsi0" >> "${D}"/etc/securetty;; - hppa) echo "ttyB0" >> "${D}"/etc/securetty;; - arm) echo "ttyFB0" >> "${D}"/etc/securetty;; - esac - - # needed for 'adduser -D' - insinto /etc/default - insopts -m0600 - doins "${FILESDIR}"/default/useradd - - # move passwd to / to help recover broke systems #64441 - mv "${D}"/usr/bin/passwd "${D}"/bin/ - dosym /bin/passwd /usr/bin/passwd - - if use pam ; then - local INSTALL_SYSTEM_PAMD="yes" - - # Do not install below pam.d files if we have pam-0.78 or later - has_version '>=sys-libs/pam-0.78' && \ - INSTALL_SYSTEM_PAMD="no" - - for x in "${FILESDIR}"/pam.d-include/*; do - case "${x##*/}" in - "login") - # We do no longer install this one, as its from - # pam-login now. - ;; - "system-auth"|"system-auth-1.1"|"other") - # These we only install if we do not have pam-0.78 - # or later. - [ "${INSTALL_SYSTEM_PAMD}" = "yes" ] && [ -f ${x} ] && \ - dopamd ${x} - ;; - "su") - # Disable support for pam_env and pam_wheel on openpam - has_version sys-libs/pam && dopamd ${x} - ;; - "su-openpam") - has_version sys-libs/openpam && newpamd ${x} su - ;; - *) - [ -f ${x} ] && dopamd ${x} - ;; - esac - done - for x in chage chsh chfn chpasswd newusers \ - user{add,del,mod} group{add,del,mod} ; do - newpamd "${FILESDIR}"/pam.d-include/shadow ${x} - done - - # Only add this one if needed. - if [ "${FORCE_SYSTEMAUTH_UPDATE}" = "yes" ]; then - newpamd "${FILESDIR}"/pam.d-include/system-auth-1.1 system-auth.new || \ - die "Failed to install system-auth.new!" - fi - - # remove manpages that pam will install for us - # and/or don't apply when using pam - - find "${D}"/usr/share/man \ - '(' -name 'limits.5*' -o -name 'suauth.5*' ')' \ - -exec rm {} \; - else - insinto /etc - insopts -m0644 - newins etc/login.defs login.defs - fi - - # Remove manpages that are handled by other packages - find "${D}"/usr/share/man \ - '(' -name id.1 -o -name passwd.5 -o -name getspnam.3 ')' \ - -exec rm {} \; - - cd "${S}" - dodoc ChangeLog NEWS TODO - newdoc README README.download - cd doc - dodoc HOWTO LSM README* WISHLIST *.txt -} - -pkg_preinst() { - rm -f "${ROOT}"/etc/pam.d/system-auth.new \ - "${ROOT}/etc/login.defs.new" -} - -pkg_postinst() { - # Enable shadow groups (we need ROOT=/ here, as grpconv only - # operate on / ...). - if [[ ${ROOT} == / && ! -f /etc/gshadow ]] ; then - if grpck -r &>/dev/null; then - grpconv - else - ewarn "Running 'grpck' returned errors. Please run it by hand, and then" - ewarn "run 'grpconv' afterwards!" - fi - fi - - use pam || return 0 - - if [ "${FORCE_SYSTEMAUTH_UPDATE}" = "yes" ]; then - local CHECK1=$(md5sum "${ROOT}"/etc/pam.d/system-auth | cut -d ' ' -f 1) - local CHECK2=$(md5sum "${ROOT}"/etc/pam.d/system-auth.new | cut -d ' ' -f 1) - - if [ "${CHECK1}" != "${CHECK2}" ]; then - ewarn "Due to a security issue, ${ROOT}etc/pam.d/system-auth " - ewarn "is being updated automatically. Your old " - ewarn "system-auth will be backed up as:" - ewarn - ewarn " ${ROOT}etc/pam.d/system-auth.bak" - echo - - cp -pPR "${ROOT}"/etc/pam.d/system-auth \ - "${ROOT}"/etc/pam.d/system-auth.bak; - mv -f "${ROOT}"/etc/pam.d/system-auth.new \ - "${ROOT}"/etc/pam.d/system-auth - rm -f "${ROOT}"/etc/pam.d/._cfg????_system-auth - else - rm -f "${ROOT}"/etc/pam.d/system-auth.new - fi - fi - - [ "${FORCE_LOGIN_DEFS}" != "yes" ] && return 0 - - ewarn "Due to a compatibility issue, ${ROOT}etc/login.defs " - ewarn "is being updated automatically. Your old login.defs" - ewarn "will be backed up as: ${ROOT}etc/login.defs.bak" - echo - - local CHECK1="`md5sum ${ROOT}/etc/login.defs | cut -d ' ' -f 1`" - local CHECK2="`md5sum ${ROOT}/etc/login.defs.new | cut -d ' ' -f 1`" - - if [ "${CHECK1}" != "${CHECK2}" ] - then - cp -pPR ${ROOT}/etc/login.defs ${ROOT}/etc/login.defs.bak - mv -f ${ROOT}/etc/login.defs.new ${ROOT}/etc/login.defs - elif [ ! -f ${ROOT}/etc/login.defs ] - then - mv -f ${ROOT}/etc/login.defs.new ${ROOT}/etc/login.defs - else - rm -f ${ROOT}/etc/login.defs.new - fi -} - diff --git a/sys-apps/shadow/shadow-4.0.16-r2.ebuild b/sys-apps/shadow/shadow-4.0.16-r2.ebuild deleted file mode 100644 index d8ac3852b5c3..000000000000 --- a/sys-apps/shadow/shadow-4.0.16-r2.ebuild +++ /dev/null @@ -1,270 +0,0 @@ -# Copyright 1999-2006 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/sys-apps/shadow/shadow-4.0.16-r2.ebuild,v 1.2 2006/10/17 14:21:36 dsd Exp $ - -inherit eutils libtool toolchain-funcs flag-o-matic autotools pam - -# We should remove this login after pam-0.78 goes stable. -FORCE_SYSTEMAUTH_UPDATE="no" - -DESCRIPTION="Utilities to deal with user accounts" -HOMEPAGE="http://shadow.pld.org.pl/" -SRC_URI="ftp://ftp.pld.org.pl/software/${PN}/${P}.tar.bz2" - -LICENSE="BSD" -SLOT="0" -KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86" -IUSE="nls pam selinux skey nousuid cracklib" - -RDEPEND="cracklib? ( >=sys-libs/cracklib-2.7-r3 ) - pam? ( virtual/pam ) - !sys-apps/pam-login - skey? ( app-admin/skey ) - selinux? ( >=sys-libs/libselinux-1.28 ) - nls? ( virtual/libintl )" -DEPEND="${RDEPEND} - >=sys-apps/portage-2.0.51-r2 - nls? ( sys-devel/gettext )" - -src_unpack() { - unpack ${A} - cd "${S}" - - # uclibc support, corrects NIS usage - epatch "${FILESDIR}"/${PN}-4.0.13-nonis.patch - - # If su should not simulate a login shell, use '/bin/sh' as shell to enable - # running of commands as user with /bin/false as shell, closing bug #15015. - # *** This one could be a security hole; disable for now *** - #epatch "${FILESDIR}"/${P}-nologin-run-sh.patch - - # tweak the default login.defs - epatch "${FILESDIR}"/${PN}-4.0.13-login.defs.patch - - # Make user/group names more flexible #3485 / #22920 - epatch "${FILESDIR}"/${PN}-4.0.13-dots-in-usernames.patch - epatch "${FILESDIR}"/${PN}-4.0.13-long-groupnames.patch - - # Fix compiling with gcc-2.95.x - epatch "${FILESDIR}"/${PN}-4.0.12-gcc2.patch - - # Patch from upstream enables the new environment too early for PAM - epatch "${FILESDIR}"/${PN}-4.0.14-su-fix-environment.patch - - # lock down setuid perms #47208 - epatch "${FILESDIR}"/${PN}-4.0.11.1-perms.patch - - epatch "${FILESDIR}"/${PN}-4.0.15-uclibc-missing-l64a.patch - - epatch "${FILESDIR}"/${PN}-4.0.16-check-opendir.patch #139148 - epatch "${FILESDIR}"/${PN}-4.0.16-fix-useradd-usergroups.patch #128715 - epatch "${FILESDIR}"/${PN}-4.0.16-mail-creation.patch #139346 - - # Needed by the UCLIBC patches - eautoconf || die - - elibtoolize - epunt_cxx -} - -src_compile() { - append-ldflags $(bindnow-flags) - tc-is-cross-compiler && export ac_cv_func_setpgrp_void=yes - econf \ - --disable-desrpc \ - --with-libcrypt \ - --enable-shared=no \ - --enable-static=yes \ - $(use_with cracklib libcrack) \ - $(use_with pam libpam) \ - $(use_with skey) \ - $(use_with selinux) \ - $(use_enable nls) \ - || die "bad configure" - emake || die "compile problem" -} - -src_install() { - local perms=4711 - use nousuid && perms=711 - make DESTDIR="${D}" suiduperms=${perms} install || die "install problem" - dosym useradd /usr/sbin/adduser - - # Remove libshadow and libmisc; see bug 37725 and the following - # comment from shadow's README.linux: - # Currently, libshadow.a is for internal use only, so if you see - # -lshadow in a Makefile of some other package, it is safe to - # remove it. - rm -f "${D}"/{,usr/}$(get_libdir)/lib{misc,shadow}.{a,la} - - insinto /etc - # Using a securetty with devfs device names added - # (compat names kept for non-devfs compatibility) - insopts -m0600 ; doins "${FILESDIR}"/securetty - if ! use pam ; then - insopts -m0600 - doins etc/login.access etc/limits - else - newpamd "${FILESDIR}/login.pamd" login - use selinux || sed -i -e '/@selinux@/d' "${D}"/etc/pam.d/login - use selinux && sed -i -e 's:@selinux@::g' "${D}"/etc/pam.d/login - - insinto /etc - insopts -m0644 - newins "${FILESDIR}/login.defs" login.defs - - # Also install another one that we can use to check if - # we need to update it if FORCE_LOGIN_DEFS = "yes" - [ "${FORCE_LOGIN_DEFS}" = "yes" ] \ - && newins "${FILESDIR}/login.defs" login.defs.new - fi - # Output arch-specific cruft - case $(tc-arch) in - ppc*) echo "hvc0" >> "${D}"/etc/securetty - echo "hvsi0" >> "${D}"/etc/securetty;; - hppa) echo "ttyB0" >> "${D}"/etc/securetty;; - arm) echo "ttyFB0" >> "${D}"/etc/securetty;; - esac - - # needed for 'adduser -D' - insinto /etc/default - insopts -m0600 - doins "${FILESDIR}"/default/useradd - - # move passwd to / to help recover broke systems #64441 - mv "${D}"/usr/bin/passwd "${D}"/bin/ - dosym /bin/passwd /usr/bin/passwd - - if use pam ; then - local INSTALL_SYSTEM_PAMD="yes" - - # Do not install below pam.d files if we have pam-0.78 or later - has_version '>=sys-libs/pam-0.78' && \ - INSTALL_SYSTEM_PAMD="no" - - for x in "${FILESDIR}"/pam.d-include/*; do - case "${x##*/}" in - "login") - # We do no longer install this one, as its from - # pam-login now. - ;; - "system-auth"|"system-auth-1.1"|"other") - # These we only install if we do not have pam-0.78 - # or later. - [ "${INSTALL_SYSTEM_PAMD}" = "yes" ] && [ -f ${x} ] && \ - dopamd ${x} - ;; - "su") - # Disable support for pam_env and pam_wheel on openpam - has_version sys-libs/pam && dopamd ${x} - ;; - "su-openpam") - has_version sys-libs/openpam && newpamd ${x} su - ;; - *) - [ -f ${x} ] && dopamd ${x} - ;; - esac - done - for x in chage chsh chfn chpasswd newusers \ - user{add,del,mod} group{add,del,mod} ; do - newpamd "${FILESDIR}"/pam.d-include/shadow ${x} - done - - # Only add this one if needed. - if [ "${FORCE_SYSTEMAUTH_UPDATE}" = "yes" ]; then - newpamd "${FILESDIR}"/pam.d-include/system-auth-1.1 system-auth.new || \ - die "Failed to install system-auth.new!" - fi - - # remove manpages that pam will install for us - # and/or don't apply when using pam - - find "${D}"/usr/share/man \ - '(' -name 'limits.5*' -o -name 'suauth.5*' ')' \ - -exec rm {} \; - else - insinto /etc - insopts -m0644 - newins etc/login.defs login.defs - fi - - # libshadow_getpass() is only used sometimes now which means - # GETPASS_ASTERISKS may not always be applicable - use skey || sed -i -e '/^GETPASS_ASTERISKS/s:^:#:' "${D}"/etc/login.defs - - # Remove manpages that are handled by other packages - find "${D}"/usr/share/man \ - '(' -name id.1 -o -name passwd.5 -o -name getspnam.3 ')' \ - -exec rm {} \; - - cd "${S}" - dodoc ChangeLog NEWS TODO - newdoc README README.download - cd doc - dodoc HOWTO LSM README* WISHLIST *.txt -} - -pkg_preinst() { - rm -f "${ROOT}"/etc/pam.d/system-auth.new \ - "${ROOT}/etc/login.defs.new" -} - -pkg_postinst() { - # Enable shadow groups (we need ROOT=/ here, as grpconv only - # operate on / ...). - if [[ ${ROOT} == / && ! -f /etc/gshadow ]] ; then - if grpck -r &>/dev/null; then - grpconv - else - ewarn "Running 'grpck' returned errors. Please run it by hand, and then" - ewarn "run 'grpconv' afterwards!" - fi - fi - - use pam || return 0 - - if [ "${FORCE_SYSTEMAUTH_UPDATE}" = "yes" ]; then - local CHECK1=$(md5sum "${ROOT}"/etc/pam.d/system-auth | cut -d ' ' -f 1) - local CHECK2=$(md5sum "${ROOT}"/etc/pam.d/system-auth.new | cut -d ' ' -f 1) - - if [ "${CHECK1}" != "${CHECK2}" ]; then - ewarn "Due to a security issue, ${ROOT}etc/pam.d/system-auth " - ewarn "is being updated automatically. Your old " - ewarn "system-auth will be backed up as:" - ewarn - ewarn " ${ROOT}etc/pam.d/system-auth.bak" - echo - - cp -pPR "${ROOT}"/etc/pam.d/system-auth \ - "${ROOT}"/etc/pam.d/system-auth.bak; - mv -f "${ROOT}"/etc/pam.d/system-auth.new \ - "${ROOT}"/etc/pam.d/system-auth - rm -f "${ROOT}"/etc/pam.d/._cfg????_system-auth - else - rm -f "${ROOT}"/etc/pam.d/system-auth.new - fi - fi - - [ "${FORCE_LOGIN_DEFS}" != "yes" ] && return 0 - - ewarn "Due to a compatibility issue, ${ROOT}etc/login.defs " - ewarn "is being updated automatically. Your old login.defs" - ewarn "will be backed up as: ${ROOT}etc/login.defs.bak" - echo - - local CHECK1="`md5sum ${ROOT}/etc/login.defs | cut -d ' ' -f 1`" - local CHECK2="`md5sum ${ROOT}/etc/login.defs.new | cut -d ' ' -f 1`" - - if [ "${CHECK1}" != "${CHECK2}" ] - then - cp -pPR ${ROOT}/etc/login.defs ${ROOT}/etc/login.defs.bak - mv -f ${ROOT}/etc/login.defs.new ${ROOT}/etc/login.defs - elif [ ! -f ${ROOT}/etc/login.defs ] - then - mv -f ${ROOT}/etc/login.defs.new ${ROOT}/etc/login.defs - else - rm -f ${ROOT}/etc/login.defs.new - fi -} - diff --git a/sys-apps/shadow/shadow-4.0.17-r1.ebuild b/sys-apps/shadow/shadow-4.0.17-r1.ebuild deleted file mode 100644 index 21e60b5bfc64..000000000000 --- a/sys-apps/shadow/shadow-4.0.17-r1.ebuild +++ /dev/null @@ -1,210 +0,0 @@ -# Copyright 1999-2006 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/sys-apps/shadow/shadow-4.0.17-r1.ebuild,v 1.4 2006/10/17 14:21:36 dsd Exp $ - -inherit eutils libtool toolchain-funcs flag-o-matic autotools pam - -DESCRIPTION="Utilities to deal with user accounts" -HOMEPAGE="http://shadow.pld.org.pl/" -SRC_URI="ftp://ftp.pld.org.pl/software/${PN}/${P}.tar.bz2" - -LICENSE="BSD" -SLOT="0" -KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86" -IUSE="nls pam selinux skey nousuid cracklib" - -RDEPEND="cracklib? ( >=sys-libs/cracklib-2.7-r3 ) - pam? ( virtual/pam ) - !sys-apps/pam-login - skey? ( app-admin/skey ) - selinux? ( >=sys-libs/libselinux-1.28 ) - nls? ( virtual/libintl )" -DEPEND="${RDEPEND} - >=sys-apps/portage-2.0.51-r2 - nls? ( sys-devel/gettext )" - -src_unpack() { - unpack ${A} - cd "${S}" - - # uclibc support, corrects NIS usage - epatch "${FILESDIR}"/${PN}-4.0.13-nonis.patch - - # If su should not simulate a login shell, use '/bin/sh' as shell to enable - # running of commands as user with /bin/false as shell, closing bug #15015. - # *** This one could be a security hole; disable for now *** - #epatch "${FILESDIR}"/${P}-nologin-run-sh.patch - - # tweak the default login.defs - epatch "${FILESDIR}"/${PN}-4.0.17-login.defs.patch - - # Make user/group names more flexible #3485 / #22920 - epatch "${FILESDIR}"/${PN}-4.0.13-dots-in-usernames.patch - epatch "${FILESDIR}"/${PN}-4.0.13-long-groupnames.patch - - # Fix compiling with gcc-2.95.x - epatch "${FILESDIR}"/${PN}-4.0.12-gcc2.patch - - # Patch from upstream enables the new environment too early for PAM - epatch "${FILESDIR}"/${PN}-4.0.14-su-fix-environment.patch - - # lock down setuid perms #47208 - epatch "${FILESDIR}"/${PN}-4.0.11.1-perms.patch - - epatch "${FILESDIR}"/${PN}-4.0.15-uclibc-missing-l64a.patch - - epatch "${FILESDIR}"/${PN}-4.0.16-fix-useradd-usergroups.patch #128715 - - epatch "${FILESDIR}"/${PN}-4.0.17-no-local-getpass.patch - - # Needed by the UCLIBC patches - eautoconf || die - - elibtoolize - epunt_cxx -} - -src_compile() { - append-ldflags $(bindnow-flags) - tc-is-cross-compiler && export ac_cv_func_setpgrp_void=yes - econf \ - --disable-desrpc \ - --with-libcrypt \ - --enable-shared=no \ - --enable-static=yes \ - $(use_with cracklib libcrack) \ - $(use_with pam libpam) \ - $(use_with skey) \ - $(use_with selinux) \ - $(use_enable nls) \ - || die "bad configure" - emake || die "compile problem" -} - -src_install() { - local perms=4711 - use nousuid && perms=711 - make DESTDIR="${D}" suiduperms=${perms} install || die "install problem" - dosym useradd /usr/sbin/adduser - - # Remove libshadow and libmisc; see bug 37725 and the following - # comment from shadow's README.linux: - # Currently, libshadow.a is for internal use only, so if you see - # -lshadow in a Makefile of some other package, it is safe to - # remove it. - rm -f "${D}"/{,usr/}$(get_libdir)/lib{misc,shadow}.{a,la} - - insinto /etc - # Using a securetty with devfs device names added - # (compat names kept for non-devfs compatibility) - insopts -m0600 ; doins "${FILESDIR}"/securetty - if ! use pam ; then - insopts -m0600 - doins etc/login.access etc/limits - else - newpamd "${FILESDIR}/login.pamd" login - use selinux || sed -i -e '/@selinux@/d' "${D}"/etc/pam.d/login - use selinux && sed -i -e 's:@selinux@::g' "${D}"/etc/pam.d/login - fi - # Output arch-specific cruft - case $(tc-arch) in - ppc*) echo "hvc0" >> "${D}"/etc/securetty - echo "hvsi0" >> "${D}"/etc/securetty;; - hppa) echo "ttyB0" >> "${D}"/etc/securetty;; - arm) echo "ttyFB0" >> "${D}"/etc/securetty;; - esac - - # needed for 'adduser -D' - insinto /etc/default - insopts -m0600 - doins "${FILESDIR}"/default/useradd - - # move passwd to / to help recover broke systems #64441 - mv "${D}"/usr/bin/passwd "${D}"/bin/ - dosym /bin/passwd /usr/bin/passwd - - if use pam ; then - local INSTALL_SYSTEM_PAMD="yes" - - # Do not install below pam.d files if we have pam-0.78 or later - has_version '>=sys-libs/pam-0.78' && \ - INSTALL_SYSTEM_PAMD="no" - - for x in "${FILESDIR}"/pam.d-include/*; do - case "${x##*/}" in - "login") - # We do no longer install this one, as its from - # pam-login now. - ;; - "system-auth"|"system-auth-1.1"|"other") - # These we only install if we do not have pam-0.78 - # or later. - [ "${INSTALL_SYSTEM_PAMD}" = "yes" ] && [ -f ${x} ] && \ - dopamd ${x} - ;; - "su") - # Disable support for pam_env and pam_wheel on openpam - has_version sys-libs/pam && dopamd ${x} - ;; - "su-openpam") - has_version sys-libs/openpam && newpamd ${x} su - ;; - *) - [ -f ${x} ] && dopamd ${x} - ;; - esac - done - for x in chage chsh chfn chpasswd newusers \ - user{add,del,mod} group{add,del,mod} ; do - newpamd "${FILESDIR}"/pam.d-include/shadow ${x} - done - - # remove manpages that pam will install for us - # and/or don't apply when using pam - - find "${D}"/usr/share/man \ - '(' -name 'limits.5*' -o -name 'suauth.5*' ')' \ - -exec rm {} \; - fi - - cd "${S}" - insinto /etc - insopts -m0644 - newins etc/login.defs login.defs - - # comment out options that pam hates - if use pam ; then - awk -f "${FILESDIR}"/login_defs.awk \ - lib/getdef.c etc/login.defs \ - > "${D}"/etc/login.defs - fi - - # Remove manpages that are handled by other packages - find "${D}"/usr/share/man \ - '(' -name id.1 -o -name passwd.5 -o -name getspnam.3 ')' \ - -exec rm {} \; - - cd "${S}" - dodoc ChangeLog NEWS TODO - newdoc README README.download - cd doc - dodoc HOWTO README* WISHLIST *.txt -} - -pkg_preinst() { - rm -f "${ROOT}"/etc/pam.d/system-auth.new \ - "${ROOT}/etc/login.defs.new" -} - -pkg_postinst() { - # Enable shadow groups (we need ROOT=/ here, as grpconv only - # operate on / ...). - if [[ ${ROOT} == / && ! -f /etc/gshadow ]] ; then - if grpck -r &>/dev/null; then - grpconv - else - ewarn "Running 'grpck' returned errors. Please run it by hand, and then" - ewarn "run 'grpconv' afterwards!" - fi - fi -} diff --git a/sys-apps/shadow/shadow-4.0.17.ebuild b/sys-apps/shadow/shadow-4.0.17.ebuild deleted file mode 100644 index 5ed189106f24..000000000000 --- a/sys-apps/shadow/shadow-4.0.17.ebuild +++ /dev/null @@ -1,270 +0,0 @@ -# Copyright 1999-2006 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/sys-apps/shadow/shadow-4.0.17.ebuild,v 1.3 2006/10/17 14:21:36 dsd Exp $ - -inherit eutils libtool toolchain-funcs flag-o-matic autotools pam - -# We should remove this login after pam-0.78 goes stable. -FORCE_SYSTEMAUTH_UPDATE="no" - -DESCRIPTION="Utilities to deal with user accounts" -HOMEPAGE="http://shadow.pld.org.pl/" -SRC_URI="ftp://ftp.pld.org.pl/software/${PN}/${P}.tar.bz2" - -LICENSE="BSD" -SLOT="0" -KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86" -IUSE="nls pam selinux skey nousuid cracklib" - -RDEPEND="cracklib? ( >=sys-libs/cracklib-2.7-r3 ) - pam? ( virtual/pam ) - !sys-apps/pam-login - skey? ( app-admin/skey ) - selinux? ( >=sys-libs/libselinux-1.28 ) - nls? ( virtual/libintl )" -DEPEND="${RDEPEND} - >=sys-apps/portage-2.0.51-r2 - nls? ( sys-devel/gettext )" - -src_unpack() { - unpack ${A} - cd "${S}" - - # uclibc support, corrects NIS usage - epatch "${FILESDIR}"/${PN}-4.0.13-nonis.patch - - # If su should not simulate a login shell, use '/bin/sh' as shell to enable - # running of commands as user with /bin/false as shell, closing bug #15015. - # *** This one could be a security hole; disable for now *** - #epatch "${FILESDIR}"/${P}-nologin-run-sh.patch - - # tweak the default login.defs - epatch "${FILESDIR}"/${PN}-4.0.13-login.defs.patch - - # Make user/group names more flexible #3485 / #22920 - epatch "${FILESDIR}"/${PN}-4.0.13-dots-in-usernames.patch - epatch "${FILESDIR}"/${PN}-4.0.13-long-groupnames.patch - - # Fix compiling with gcc-2.95.x - epatch "${FILESDIR}"/${PN}-4.0.12-gcc2.patch - - # Patch from upstream enables the new environment too early for PAM - epatch "${FILESDIR}"/${PN}-4.0.14-su-fix-environment.patch - - # lock down setuid perms #47208 - epatch "${FILESDIR}"/${PN}-4.0.11.1-perms.patch - - epatch "${FILESDIR}"/${PN}-4.0.15-uclibc-missing-l64a.patch - - epatch "${FILESDIR}"/${PN}-4.0.16-fix-useradd-usergroups.patch #128715 - - epatch "${FILESDIR}"/${PN}-4.0.17-no-local-getpass.patch - - # Needed by the UCLIBC patches - eautoconf || die - - elibtoolize - epunt_cxx -} - -src_compile() { - append-ldflags $(bindnow-flags) - tc-is-cross-compiler && export ac_cv_func_setpgrp_void=yes - econf \ - --disable-desrpc \ - --with-libcrypt \ - --enable-shared=no \ - --enable-static=yes \ - $(use_with cracklib libcrack) \ - $(use_with pam libpam) \ - $(use_with skey) \ - $(use_with selinux) \ - $(use_enable nls) \ - || die "bad configure" - emake || die "compile problem" -} - -src_install() { - local perms=4711 - use nousuid && perms=711 - make DESTDIR="${D}" suiduperms=${perms} install || die "install problem" - dosym useradd /usr/sbin/adduser - - # Remove libshadow and libmisc; see bug 37725 and the following - # comment from shadow's README.linux: - # Currently, libshadow.a is for internal use only, so if you see - # -lshadow in a Makefile of some other package, it is safe to - # remove it. - rm -f "${D}"/{,usr/}$(get_libdir)/lib{misc,shadow}.{a,la} - - insinto /etc - # Using a securetty with devfs device names added - # (compat names kept for non-devfs compatibility) - insopts -m0600 ; doins "${FILESDIR}"/securetty - if ! use pam ; then - insopts -m0600 - doins etc/login.access etc/limits - else - newpamd "${FILESDIR}/login.pamd" login - use selinux || sed -i -e '/@selinux@/d' "${D}"/etc/pam.d/login - use selinux && sed -i -e 's:@selinux@::g' "${D}"/etc/pam.d/login - - insinto /etc - insopts -m0644 - newins "${FILESDIR}/login.defs" login.defs - - # Also install another one that we can use to check if - # we need to update it if FORCE_LOGIN_DEFS = "yes" - [ "${FORCE_LOGIN_DEFS}" = "yes" ] \ - && newins "${FILESDIR}/login.defs" login.defs.new - fi - # Output arch-specific cruft - case $(tc-arch) in - ppc*) echo "hvc0" >> "${D}"/etc/securetty - echo "hvsi0" >> "${D}"/etc/securetty;; - hppa) echo "ttyB0" >> "${D}"/etc/securetty;; - arm) echo "ttyFB0" >> "${D}"/etc/securetty;; - esac - - # needed for 'adduser -D' - insinto /etc/default - insopts -m0600 - doins "${FILESDIR}"/default/useradd - - # move passwd to / to help recover broke systems #64441 - mv "${D}"/usr/bin/passwd "${D}"/bin/ - dosym /bin/passwd /usr/bin/passwd - - if use pam ; then - local INSTALL_SYSTEM_PAMD="yes" - - # Do not install below pam.d files if we have pam-0.78 or later - has_version '>=sys-libs/pam-0.78' && \ - INSTALL_SYSTEM_PAMD="no" - - for x in "${FILESDIR}"/pam.d-include/*; do - case "${x##*/}" in - "login") - # We do no longer install this one, as its from - # pam-login now. - ;; - "system-auth"|"system-auth-1.1"|"other") - # These we only install if we do not have pam-0.78 - # or later. - [ "${INSTALL_SYSTEM_PAMD}" = "yes" ] && [ -f ${x} ] && \ - dopamd ${x} - ;; - "su") - # Disable support for pam_env and pam_wheel on openpam - has_version sys-libs/pam && dopamd ${x} - ;; - "su-openpam") - has_version sys-libs/openpam && newpamd ${x} su - ;; - *) - [ -f ${x} ] && dopamd ${x} - ;; - esac - done - for x in chage chsh chfn chpasswd newusers \ - user{add,del,mod} group{add,del,mod} ; do - newpamd "${FILESDIR}"/pam.d-include/shadow ${x} - done - - # Only add this one if needed. - if [ "${FORCE_SYSTEMAUTH_UPDATE}" = "yes" ]; then - newpamd "${FILESDIR}"/pam.d-include/system-auth-1.1 system-auth.new || \ - die "Failed to install system-auth.new!" - fi - - # remove manpages that pam will install for us - # and/or don't apply when using pam - - find "${D}"/usr/share/man \ - '(' -name 'limits.5*' -o -name 'suauth.5*' ')' \ - -exec rm {} \; - else - insinto /etc - insopts -m0644 - newins etc/login.defs login.defs - fi - - # libshadow_getpass() is only used sometimes now which means - # GETPASS_ASTERISKS may not always be applicable - use skey || sed -i -e '/^GETPASS_ASTERISKS/s:^:#:' "${D}"/etc/login.defs - - # Remove manpages that are handled by other packages - find "${D}"/usr/share/man \ - '(' -name id.1 -o -name passwd.5 -o -name getspnam.3 ')' \ - -exec rm {} \; - - cd "${S}" - dodoc ChangeLog NEWS TODO - newdoc README README.download - cd doc - dodoc HOWTO LSM README* WISHLIST *.txt -} - -pkg_preinst() { - rm -f "${ROOT}"/etc/pam.d/system-auth.new \ - "${ROOT}/etc/login.defs.new" -} - -pkg_postinst() { - # Enable shadow groups (we need ROOT=/ here, as grpconv only - # operate on / ...). - if [[ ${ROOT} == / && ! -f /etc/gshadow ]] ; then - if grpck -r &>/dev/null; then - grpconv - else - ewarn "Running 'grpck' returned errors. Please run it by hand, and then" - ewarn "run 'grpconv' afterwards!" - fi - fi - - use pam || return 0 - - if [ "${FORCE_SYSTEMAUTH_UPDATE}" = "yes" ]; then - local CHECK1=$(md5sum "${ROOT}"/etc/pam.d/system-auth | cut -d ' ' -f 1) - local CHECK2=$(md5sum "${ROOT}"/etc/pam.d/system-auth.new | cut -d ' ' -f 1) - - if [ "${CHECK1}" != "${CHECK2}" ]; then - ewarn "Due to a security issue, ${ROOT}etc/pam.d/system-auth " - ewarn "is being updated automatically. Your old " - ewarn "system-auth will be backed up as:" - ewarn - ewarn " ${ROOT}etc/pam.d/system-auth.bak" - echo - - cp -pPR "${ROOT}"/etc/pam.d/system-auth \ - "${ROOT}"/etc/pam.d/system-auth.bak; - mv -f "${ROOT}"/etc/pam.d/system-auth.new \ - "${ROOT}"/etc/pam.d/system-auth - rm -f "${ROOT}"/etc/pam.d/._cfg????_system-auth - else - rm -f "${ROOT}"/etc/pam.d/system-auth.new - fi - fi - - [ "${FORCE_LOGIN_DEFS}" != "yes" ] && return 0 - - ewarn "Due to a compatibility issue, ${ROOT}etc/login.defs " - ewarn "is being updated automatically. Your old login.defs" - ewarn "will be backed up as: ${ROOT}etc/login.defs.bak" - echo - - local CHECK1="`md5sum ${ROOT}/etc/login.defs | cut -d ' ' -f 1`" - local CHECK2="`md5sum ${ROOT}/etc/login.defs.new | cut -d ' ' -f 1`" - - if [ "${CHECK1}" != "${CHECK2}" ] - then - cp -pPR ${ROOT}/etc/login.defs ${ROOT}/etc/login.defs.bak - mv -f ${ROOT}/etc/login.defs.new ${ROOT}/etc/login.defs - elif [ ! -f ${ROOT}/etc/login.defs ] - then - mv -f ${ROOT}/etc/login.defs.new ${ROOT}/etc/login.defs - else - rm -f ${ROOT}/etc/login.defs.new - fi -} - |