Gentoo Archives: gentoo-commits

From: Mikle Kolyada <zlogene@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: sys-apps/shadow/
Date: Tue, 22 May 2018 22:20:22
Message-Id: 1527027603.0607474fe104ff1158284c7985ebaf0ca5f6dd83.zlogene@gentoo
1 commit: 0607474fe104ff1158284c7985ebaf0ca5f6dd83
2 Author: Mikle Kolyada <zlogene <AT> gentoo <DOT> org>
3 AuthorDate: Tue May 22 22:19:43 2018 +0000
4 Commit: Mikle Kolyada <zlogene <AT> gentoo <DOT> org>
5 CommitDate: Tue May 22 22:20:03 2018 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=0607474f
7
8 sys-apps/shadow: Drop old
9
10 Package-Manager: Portage-2.3.24, Repoman-2.3.6
11
12 sys-apps/shadow/Manifest | 1 -
13 sys-apps/shadow/shadow-4.5-r1.ebuild | 212 -----------------------------------
14 sys-apps/shadow/shadow-4.5.ebuild | 209 ----------------------------------
15 3 files changed, 422 deletions(-)
16
17 diff --git a/sys-apps/shadow/Manifest b/sys-apps/shadow/Manifest
18 index 3aaa9d8978f..000b8e78833 100644
19 --- a/sys-apps/shadow/Manifest
20 +++ b/sys-apps/shadow/Manifest
21 @@ -1,2 +1 @@
22 -DIST shadow-4.5.tar.gz 3804933 BLAKE2B c4714b7fe9a1af5a5751d4274e70e7fb31994cc40058b44c401bbbdf83c238fcf48e6e6e663d8a61f614b6291ea524862d9d2425d7d839340a10f8fb7c8eaa85 SHA512 02d6482a1159689e404dd49a68b4e2db85e9ffdcdfbacc8efcbd9043f14a1ec3fc4d749700df915d375df67d589219b6b0f57a6cfd9fb5b197012888a608913b
23 DIST shadow-4.6.tar.gz 3804282 BLAKE2B 268c90e7daba138827aec6039f428f52cdcf7929743fa1f49f801cc669de7456ec5a69531194cdb29f051ce7d0b2f1e966fdf2513a9fc8f7fbdeb29d786a509f SHA512 36358333e7f03ef558772f3361bc5851a7d7fd3d85c993a6b732e37304b8068b2893d55607b9bfe8b8eed616a687264f947ff66cefc74ea1a48ba9396d464714
24
25 diff --git a/sys-apps/shadow/shadow-4.5-r1.ebuild b/sys-apps/shadow/shadow-4.5-r1.ebuild
26 deleted file mode 100644
27 index 1e3d98f2593..00000000000
28 --- a/sys-apps/shadow/shadow-4.5-r1.ebuild
29 +++ /dev/null
30 @@ -1,212 +0,0 @@
31 -# Copyright 1999-2018 Gentoo Foundation
32 -# Distributed under the terms of the GNU General Public License v2
33 -
34 -EAPI=6
35 -
36 -inherit libtool pam multilib
37 -
38 -DESCRIPTION="Utilities to deal with user accounts"
39 -HOMEPAGE="https://github.com/shadow-maint/shadow http://pkg-shadow.alioth.debian.org/"
40 -SRC_URI="https://github.com/shadow-maint/shadow/releases/download/${PV}/${P}.tar.gz"
41 -
42 -LICENSE="BSD GPL-2"
43 -SLOT="0"
44 -KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86"
45 -IUSE="acl audit +cracklib nls pam selinux skey xattr"
46 -# Taken from the man/Makefile.am file.
47 -LANGS=( cs da de es fi fr hu id it ja ko pl pt_BR ru sv tr zh_CN zh_TW )
48 -
49 -RDEPEND="acl? ( sys-apps/acl:0= )
50 - audit? ( >=sys-process/audit-2.6:0= )
51 - cracklib? ( >=sys-libs/cracklib-2.7-r3:0= )
52 - pam? ( virtual/pam:0= )
53 - skey? ( sys-auth/skey:0= )
54 - selinux? (
55 - >=sys-libs/libselinux-1.28:0=
56 - sys-libs/libsemanage:0=
57 - )
58 - nls? ( virtual/libintl )
59 - xattr? ( sys-apps/attr:0= )"
60 -DEPEND="${RDEPEND}
61 - app-arch/xz-utils
62 - nls? ( sys-devel/gettext )"
63 -RDEPEND="${RDEPEND}
64 - pam? ( >=sys-auth/pambase-20150213 )"
65 -
66 -PATCHES=(
67 - "${FILESDIR}/${PN}-4.1.3-dots-in-usernames.patch"
68 - "${FILESDIR}/${P}-CVE-2018-7169.patch" #647790
69 -)
70 -
71 -src_prepare() {
72 - default
73 - #eautoreconf
74 - elibtoolize
75 -}
76 -
77 -src_configure() {
78 - local myeconfargs=(
79 - --without-group-name-max-length
80 - --without-tcb
81 - --enable-shared=no
82 - --enable-static=yes
83 - $(use_with acl)
84 - $(use_with audit)
85 - $(use_with cracklib libcrack)
86 - $(use_with pam libpam)
87 - $(use_with skey)
88 - $(use_with selinux)
89 - $(use_enable nls)
90 - $(use_with elibc_glibc nscd)
91 - $(use_with xattr attr)
92 - )
93 - econf "${myeconfargs[@]}"
94 -
95 - has_version 'sys-libs/uclibc[-rpc]' && sed -i '/RLOGIN/d' config.h #425052
96 -
97 - if use nls ; then
98 - local l langs="po" # These are the pot files.
99 - for l in ${LANGS[*]} ; do
100 - has ${l} ${LINGUAS-${l}} && langs+=" ${l}"
101 - done
102 - sed -i "/^SUBDIRS = /s:=.*:= ${langs}:" man/Makefile || die
103 - fi
104 -}
105 -
106 -set_login_opt() {
107 - local comment="" opt=$1 val=$2
108 - if [[ -z ${val} ]]; then
109 - comment="#"
110 - sed -i \
111 - -e "/^${opt}\>/s:^:#:" \
112 - "${ED%/}"/etc/login.defs || die
113 - else
114 - sed -i -r \
115 - -e "/^#?${opt}\>/s:.*:${opt} ${val}:" \
116 - "${ED%/}"/etc/login.defs
117 - fi
118 - local res=$(grep "^${comment}${opt}\>" "${ED%/}"/etc/login.defs)
119 - einfo "${res:-Unable to find ${opt} in /etc/login.defs}"
120 -}
121 -
122 -src_install() {
123 - emake DESTDIR="${D}" suidperms=4711 install
124 -
125 - # Remove libshadow and libmisc; see bug 37725 and the following
126 - # comment from shadow's README.linux:
127 - # Currently, libshadow.a is for internal use only, so if you see
128 - # -lshadow in a Makefile of some other package, it is safe to
129 - # remove it.
130 - rm -f "${ED%/}"/{,usr/}$(get_libdir)/lib{misc,shadow}.{a,la}
131 -
132 - insinto /etc
133 - if ! use pam ; then
134 - insopts -m0600
135 - doins etc/login.access etc/limits
136 - fi
137 -
138 - # needed for 'useradd -D'
139 - insinto /etc/default
140 - insopts -m0600
141 - doins "${FILESDIR}"/default/useradd
142 -
143 - # move passwd to / to help recover broke systems #64441
144 - mv "${ED%/}"/usr/bin/passwd "${ED%/}"/bin/ || die
145 - dosym /bin/passwd /usr/bin/passwd
146 -
147 - cd "${S}" || die
148 - insinto /etc
149 - insopts -m0644
150 - newins etc/login.defs login.defs
151 -
152 - set_login_opt CREATE_HOME yes
153 - if ! use pam ; then
154 - set_login_opt MAIL_CHECK_ENAB no
155 - set_login_opt SU_WHEEL_ONLY yes
156 - set_login_opt CRACKLIB_DICTPATH /usr/$(get_libdir)/cracklib_dict
157 - set_login_opt LOGIN_RETRIES 3
158 - set_login_opt ENCRYPT_METHOD SHA512
159 - set_login_opt CONSOLE
160 - else
161 - dopamd "${FILESDIR}"/pam.d-include/shadow
162 -
163 - for x in chpasswd chgpasswd newusers; do
164 - newpamd "${FILESDIR}"/pam.d-include/passwd ${x}
165 - done
166 -
167 - for x in chage chsh chfn \
168 - user{add,del,mod} group{add,del,mod} ; do
169 - newpamd "${FILESDIR}"/pam.d-include/shadow ${x}
170 - done
171 -
172 - # comment out login.defs options that pam hates
173 - local opt sed_args=()
174 - for opt in \
175 - CHFN_AUTH \
176 - CONSOLE \
177 - CRACKLIB_DICTPATH \
178 - ENV_HZ \
179 - ENVIRON_FILE \
180 - FAILLOG_ENAB \
181 - FTMP_FILE \
182 - LASTLOG_ENAB \
183 - MAIL_CHECK_ENAB \
184 - MOTD_FILE \
185 - NOLOGINS_FILE \
186 - OBSCURE_CHECKS_ENAB \
187 - PASS_ALWAYS_WARN \
188 - PASS_CHANGE_TRIES \
189 - PASS_MIN_LEN \
190 - PORTTIME_CHECKS_ENAB \
191 - QUOTAS_ENAB \
192 - SU_WHEEL_ONLY
193 - do
194 - set_login_opt ${opt}
195 - sed_args+=( -e "/^#${opt}\>/b pamnote" )
196 - done
197 - sed -i "${sed_args[@]}" \
198 - -e 'b exit' \
199 - -e ': pamnote; i# NOTE: This setting should be configured via /etc/pam.d/ and not in this file.' \
200 - -e ': exit' \
201 - "${ED%/}"/etc/login.defs || die
202 -
203 - # remove manpages that pam will install for us
204 - # and/or don't apply when using pam
205 - find "${ED%/}"/usr/share/man \
206 - '(' -name 'limits.5*' -o -name 'suauth.5*' ')' \
207 - -delete
208 -
209 - # Remove pam.d files provided by pambase.
210 - rm "${ED%/}"/etc/pam.d/{login,passwd,su} || die
211 - fi
212 -
213 - # Remove manpages that are handled by other packages
214 - find "${ED%/}"/usr/share/man \
215 - '(' -name id.1 -o -name passwd.5 -o -name getspnam.3 ')' \
216 - -delete
217 -
218 - cd "${S}" || die
219 - dodoc ChangeLog NEWS TODO
220 - newdoc README README.download
221 - cd doc || die
222 - dodoc HOWTO README* WISHLIST *.txt
223 -}
224 -
225 -pkg_preinst() {
226 - rm -f "${EROOT}"/etc/pam.d/system-auth.new \
227 - "${EROOT}/etc/login.defs.new"
228 -}
229 -
230 -pkg_postinst() {
231 - # Enable shadow groups.
232 - if [ ! -f "${EROOT}"/etc/gshadow ] ; then
233 - if grpck -r -R "${EROOT}" 2>/dev/null ; then
234 - grpconv -R "${EROOT}"
235 - else
236 - ewarn "Running 'grpck' returned errors. Please run it by hand, and then"
237 - ewarn "run 'grpconv' afterwards!"
238 - fi
239 - fi
240 -
241 - einfo "The 'adduser' symlink to 'useradd' has been dropped."
242 -}
243
244 diff --git a/sys-apps/shadow/shadow-4.5.ebuild b/sys-apps/shadow/shadow-4.5.ebuild
245 deleted file mode 100644
246 index 0b67db2fe8a..00000000000
247 --- a/sys-apps/shadow/shadow-4.5.ebuild
248 +++ /dev/null
249 @@ -1,209 +0,0 @@
250 -# Copyright 1999-2018 Gentoo Foundation
251 -# Distributed under the terms of the GNU General Public License v2
252 -
253 -EAPI="5"
254 -
255 -inherit eutils libtool pam multilib
256 -
257 -DESCRIPTION="Utilities to deal with user accounts"
258 -HOMEPAGE="https://github.com/shadow-maint/shadow http://pkg-shadow.alioth.debian.org/"
259 -SRC_URI="https://github.com/shadow-maint/shadow/releases/download/${PV}/${P}.tar.gz"
260 -
261 -LICENSE="BSD GPL-2"
262 -SLOT="0"
263 -KEYWORDS="alpha amd64 arm arm64 hppa ia64 m68k ~mips ppc ppc64 s390 sh sparc x86"
264 -IUSE="acl audit +cracklib nls pam selinux skey xattr"
265 -# Taken from the man/Makefile.am file.
266 -LANGS=( cs da de es fi fr hu id it ja ko pl pt_BR ru sv tr zh_CN zh_TW )
267 -
268 -RDEPEND="acl? ( sys-apps/acl:0= )
269 - audit? ( >=sys-process/audit-2.6:0= )
270 - cracklib? ( >=sys-libs/cracklib-2.7-r3:0= )
271 - pam? ( virtual/pam:0= )
272 - skey? ( sys-auth/skey:0= )
273 - selinux? (
274 - >=sys-libs/libselinux-1.28:0=
275 - sys-libs/libsemanage:0=
276 - )
277 - nls? ( virtual/libintl )
278 - xattr? ( sys-apps/attr:0= )"
279 -DEPEND="${RDEPEND}
280 - app-arch/xz-utils
281 - nls? ( sys-devel/gettext )"
282 -RDEPEND="${RDEPEND}
283 - pam? ( >=sys-auth/pambase-20150213 )"
284 -
285 -PATCHES=(
286 - "${FILESDIR}"/${PN}-4.1.3-dots-in-usernames.patch
287 -)
288 -
289 -src_prepare() {
290 - epatch "${PATCHES[@]}"
291 - epatch_user
292 - #eautoreconf
293 - elibtoolize
294 -}
295 -
296 -src_configure() {
297 - econf \
298 - --without-group-name-max-length \
299 - --without-tcb \
300 - --enable-shared=no \
301 - --enable-static=yes \
302 - $(use_with acl) \
303 - $(use_with audit) \
304 - $(use_with cracklib libcrack) \
305 - $(use_with pam libpam) \
306 - $(use_with skey) \
307 - $(use_with selinux) \
308 - $(use_enable nls) \
309 - $(use_with elibc_glibc nscd) \
310 - $(use_with xattr attr)
311 - has_version 'sys-libs/uclibc[-rpc]' && sed -i '/RLOGIN/d' config.h #425052
312 -
313 - if use nls ; then
314 - local l langs="po" # These are the pot files.
315 - for l in ${LANGS[*]} ; do
316 - has ${l} ${LINGUAS-${l}} && langs+=" ${l}"
317 - done
318 - sed -i "/^SUBDIRS = /s:=.*:= ${langs}:" man/Makefile || die
319 - fi
320 -}
321 -
322 -set_login_opt() {
323 - local comment="" opt=$1 val=$2
324 - if [[ -z ${val} ]]; then
325 - comment="#"
326 - sed -i \
327 - -e "/^${opt}\>/s:^:#:" \
328 - "${ED}"/etc/login.defs || die
329 - else
330 - sed -i -r \
331 - -e "/^#?${opt}\>/s:.*:${opt} ${val}:" \
332 - "${ED}"/etc/login.defs
333 - fi
334 - local res=$(grep "^${comment}${opt}\>" "${ED}"/etc/login.defs)
335 - einfo "${res:-Unable to find ${opt} in /etc/login.defs}"
336 -}
337 -
338 -src_install() {
339 - emake DESTDIR="${D}" suidperms=4711 install
340 -
341 - # Remove libshadow and libmisc; see bug 37725 and the following
342 - # comment from shadow's README.linux:
343 - # Currently, libshadow.a is for internal use only, so if you see
344 - # -lshadow in a Makefile of some other package, it is safe to
345 - # remove it.
346 - rm -f "${ED}"/{,usr/}$(get_libdir)/lib{misc,shadow}.{a,la}
347 -
348 - insinto /etc
349 - if ! use pam ; then
350 - insopts -m0600
351 - doins etc/login.access etc/limits
352 - fi
353 -
354 - # needed for 'useradd -D'
355 - insinto /etc/default
356 - insopts -m0600
357 - doins "${FILESDIR}"/default/useradd
358 -
359 - # move passwd to / to help recover broke systems #64441
360 - mv "${ED}"/usr/bin/passwd "${ED}"/bin/ || die
361 - dosym /bin/passwd /usr/bin/passwd
362 -
363 - cd "${S}"
364 - insinto /etc
365 - insopts -m0644
366 - newins etc/login.defs login.defs
367 -
368 - set_login_opt CREATE_HOME yes
369 - if ! use pam ; then
370 - set_login_opt MAIL_CHECK_ENAB no
371 - set_login_opt SU_WHEEL_ONLY yes
372 - set_login_opt CRACKLIB_DICTPATH /usr/$(get_libdir)/cracklib_dict
373 - set_login_opt LOGIN_RETRIES 3
374 - set_login_opt ENCRYPT_METHOD SHA512
375 - set_login_opt CONSOLE
376 - else
377 - dopamd "${FILESDIR}"/pam.d-include/shadow
378 -
379 - for x in chpasswd chgpasswd newusers; do
380 - newpamd "${FILESDIR}"/pam.d-include/passwd ${x}
381 - done
382 -
383 - for x in chage chsh chfn \
384 - user{add,del,mod} group{add,del,mod} ; do
385 - newpamd "${FILESDIR}"/pam.d-include/shadow ${x}
386 - done
387 -
388 - # comment out login.defs options that pam hates
389 - local opt sed_args=()
390 - for opt in \
391 - CHFN_AUTH \
392 - CONSOLE \
393 - CRACKLIB_DICTPATH \
394 - ENV_HZ \
395 - ENVIRON_FILE \
396 - FAILLOG_ENAB \
397 - FTMP_FILE \
398 - LASTLOG_ENAB \
399 - MAIL_CHECK_ENAB \
400 - MOTD_FILE \
401 - NOLOGINS_FILE \
402 - OBSCURE_CHECKS_ENAB \
403 - PASS_ALWAYS_WARN \
404 - PASS_CHANGE_TRIES \
405 - PASS_MIN_LEN \
406 - PORTTIME_CHECKS_ENAB \
407 - QUOTAS_ENAB \
408 - SU_WHEEL_ONLY
409 - do
410 - set_login_opt ${opt}
411 - sed_args+=( -e "/^#${opt}\>/b pamnote" )
412 - done
413 - sed -i "${sed_args[@]}" \
414 - -e 'b exit' \
415 - -e ': pamnote; i# NOTE: This setting should be configured via /etc/pam.d/ and not in this file.' \
416 - -e ': exit' \
417 - "${ED}"/etc/login.defs || die
418 -
419 - # remove manpages that pam will install for us
420 - # and/or don't apply when using pam
421 - find "${ED}"/usr/share/man \
422 - '(' -name 'limits.5*' -o -name 'suauth.5*' ')' \
423 - -delete
424 -
425 - # Remove pam.d files provided by pambase.
426 - rm "${ED}"/etc/pam.d/{login,passwd,su} || die
427 - fi
428 -
429 - # Remove manpages that are handled by other packages
430 - find "${ED}"/usr/share/man \
431 - '(' -name id.1 -o -name passwd.5 -o -name getspnam.3 ')' \
432 - -delete
433 -
434 - cd "${S}"
435 - dodoc ChangeLog NEWS TODO
436 - newdoc README README.download
437 - cd doc
438 - dodoc HOWTO README* WISHLIST *.txt
439 -}
440 -
441 -pkg_preinst() {
442 - rm -f "${EROOT}"/etc/pam.d/system-auth.new \
443 - "${EROOT}/etc/login.defs.new"
444 -}
445 -
446 -pkg_postinst() {
447 - # Enable shadow groups.
448 - if [ ! -f "${EROOT}"/etc/gshadow ] ; then
449 - if grpck -r -R "${EROOT}" 2>/dev/null ; then
450 - grpconv -R "${EROOT}"
451 - else
452 - ewarn "Running 'grpck' returned errors. Please run it by hand, and then"
453 - ewarn "run 'grpconv' afterwards!"
454 - fi
455 - fi
456 -
457 - einfo "The 'adduser' symlink to 'useradd' has been dropped."
458 -}