Gentoo Archives: gentoo-commits

From: David Seifert <soap@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: app-admin/sudo/
Date: Mon, 14 Jun 2021 09:20:03
Message-Id: 1623662336.a37a6a3e434759d626ee5da4d3dc4b6d5459eb1e.soap@gentoo
1 commit: a37a6a3e434759d626ee5da4d3dc4b6d5459eb1e
2 Author: David Seifert <soap <AT> gentoo <DOT> org>
3 AuthorDate: Mon Jun 14 09:18:56 2021 +0000
4 Commit: David Seifert <soap <AT> gentoo <DOT> org>
5 CommitDate: Mon Jun 14 09:18:56 2021 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a37a6a3e
7
8 app-admin/sudo: drop 1.9.7
9
10 Signed-off-by: David Seifert <soap <AT> gentoo.org>
11
12 app-admin/sudo/Manifest | 1 -
13 app-admin/sudo/sudo-1.9.7.ebuild | 254 ---------------------------------------
14 2 files changed, 255 deletions(-)
15
16 diff --git a/app-admin/sudo/Manifest b/app-admin/sudo/Manifest
17 index d4786ae3fd4..f3f27e8a2ed 100644
18 --- a/app-admin/sudo/Manifest
19 +++ b/app-admin/sudo/Manifest
20 @@ -1,3 +1,2 @@
21 DIST sudo-1.9.6p1.tar.gz 4119888 BLAKE2B 02bdb551c46cff11ac56e64937c64e6a29ccd8e0af34ea2f6b33c223bee8f7ad958d0fc3d7ef8ef12bf5bc82565769b923ff112a3f3d6bf6999fa4f6ea55e38e SHA512 632dfe72f04ce9a7a5a7236fcd5c09ce4535e695ced49d24dd848e3a7b1bea7380df44188b9e475af4271069539b5a5816948a98fbb0649ebebaba8b4c4b7745
22 -DIST sudo-1.9.7.tar.gz 4194242 BLAKE2B 5addf9fc0a8fea8ada89f240f827dcec973277f120ad98f7942f8e46e2869c676eaca044b9c46e43dab120efea3413c71e19c30ef5b0d9cc4d9ad8f0413dbffe SHA512 53e9f18f6c0acd4f80c0cd695cd23781310e9edd305d1b3ea19653efa3fd7faba149daef0ba4953615b140a8816bc980c9bd8d28545dd8db98075abf11b63e61
23 DIST sudo-1.9.7p1.tar.gz 4197591 BLAKE2B fff3eab8b4de6276135229c5fe12e7eced98af988b7686600e6a63b8615f6357ab2c5f95ef6f1872534476c4398a28c4f468ffc316e0cff7d4b32e6068aa97d4 SHA512 bc85d9de1566de24883375edd1c4cd24b1f24437bb16d181bfa3c9c94cead220c69ad00d6727560ca195765ced970e95d69b9ce01dbea448de39afac9a902fb4
24
25 diff --git a/app-admin/sudo/sudo-1.9.7.ebuild b/app-admin/sudo/sudo-1.9.7.ebuild
26 deleted file mode 100644
27 index 4d5f317bd54..00000000000
28 --- a/app-admin/sudo/sudo-1.9.7.ebuild
29 +++ /dev/null
30 @@ -1,254 +0,0 @@
31 -# Copyright 1999-2021 Gentoo Authors
32 -# Distributed under the terms of the GNU General Public License v2
33 -
34 -EAPI=7
35 -
36 -inherit pam multilib libtool systemd tmpfiles toolchain-funcs
37 -
38 -MY_P="${P/_/}"
39 -MY_P="${MY_P/beta/b}"
40 -
41 -DESCRIPTION="Allows users or groups to run commands as other users"
42 -HOMEPAGE="https://www.sudo.ws/"
43 -if [[ ${PV} == "9999" ]] ; then
44 - inherit mercurial
45 - EHG_REPO_URI="https://www.sudo.ws/repos/sudo"
46 -else
47 - uri_prefix=
48 - case ${P} in
49 - *_beta*|*_rc*) uri_prefix=beta/ ;;
50 - esac
51 -
52 - SRC_URI="https://www.sudo.ws/sudo/dist/${uri_prefix}${MY_P}.tar.gz
53 - ftp://ftp.sudo.ws/pub/sudo/${uri_prefix}${MY_P}.tar.gz"
54 - if [[ ${PV} != *_beta* ]] && [[ ${PV} != *_rc* ]] ; then
55 - KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86 ~sparc-solaris"
56 - fi
57 -fi
58 -
59 -# Basic license is ISC-style as-is, some files are released under
60 -# 3-clause BSD license
61 -LICENSE="ISC BSD"
62 -SLOT="0"
63 -IUSE="gcrypt ldap nls offensive pam sasl +secure-path selinux +sendmail skey ssl sssd"
64 -
65 -DEPEND="
66 - sys-libs/zlib:=
67 - gcrypt? ( dev-libs/libgcrypt:= )
68 - ldap? (
69 - >=net-nds/openldap-2.1.30-r1
70 - sasl? (
71 - dev-libs/cyrus-sasl
72 - net-nds/openldap[sasl]
73 - )
74 - )
75 - pam? ( sys-libs/pam )
76 - sasl? ( dev-libs/cyrus-sasl )
77 - skey? ( >=sys-auth/skey-1.1.5-r1 )
78 - ssl? ( dev-libs/openssl:0= )
79 - sssd? ( sys-auth/sssd[sudo] )
80 -"
81 -RDEPEND="
82 - ${DEPEND}
83 - >=app-misc/editor-wrapper-3
84 - virtual/editor
85 - ldap? ( dev-lang/perl )
86 - pam? ( sys-auth/pambase )
87 - selinux? ( sec-policy/selinux-sudo )
88 - sendmail? ( virtual/mta )
89 -"
90 -BDEPEND="
91 - sys-devel/bison
92 - virtual/pkgconfig
93 -"
94 -
95 -S="${WORKDIR}/${MY_P}"
96 -
97 -REQUIRED_USE="
98 - ?? ( pam skey )
99 - ?? ( gcrypt ssl )
100 -"
101 -
102 -MAKEOPTS+=" SAMPLES="
103 -
104 -src_prepare() {
105 - default
106 - elibtoolize
107 -}
108 -
109 -set_secure_path() {
110 - # first extract the default ROOTPATH from build env
111 - SECURE_PATH=$(unset ROOTPATH; . "${EPREFIX}"/etc/profile.env;
112 - echo "${ROOTPATH}")
113 - case "${SECURE_PATH}" in
114 - */usr/sbin*) ;;
115 - *) SECURE_PATH=$(unset PATH;
116 - . "${EPREFIX}"/etc/profile.env; echo "${PATH}")
117 - ;;
118 - esac
119 - if [[ -z ${SECURE_PATH} ]] ; then
120 - ewarn " Failed to detect SECURE_PATH, please report this"
121 - fi
122 -
123 - # then remove duplicate path entries
124 - cleanpath() {
125 - local newpath thisp IFS=:
126 - for thisp in $1 ; do
127 - if [[ :${newpath}: != *:${thisp}:* ]] ; then
128 - newpath+=:${thisp}
129 - else
130 - einfo " Duplicate entry ${thisp} removed..."
131 - fi
132 - done
133 - SECURE_PATH=${newpath#:}
134 - }
135 - cleanpath /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/opt/bin${SECURE_PATH:+:${SECURE_PATH}}
136 -
137 - # finally, strip gcc paths #136027
138 - rmpath() {
139 - local e newpath thisp IFS=:
140 - for thisp in ${SECURE_PATH} ; do
141 - for e ; do [[ ${thisp} == ${e} ]] && continue 2 ; done
142 - newpath+=:${thisp}
143 - done
144 - SECURE_PATH=${newpath#:}
145 - }
146 - rmpath '*/gcc-bin/*' '*/gnat-gcc-bin/*' '*/gnat-gcc/*'
147 -}
148 -
149 -src_configure() {
150 - local SECURE_PATH
151 - set_secure_path
152 - tc-export PKG_CONFIG #767712
153 -
154 - # audit: somebody got to explain me how I can test this before I
155 - # enable it.. - Diego
156 - # plugindir: autoconf code is crappy and does not delay evaluation
157 - # until `make` time, so we have to use a full path here rather than
158 - # basing off other values.
159 - myeconfargs=(
160 - # requires some python eclass
161 - --disable-python
162 - --enable-tmpfiles.d="${EPREFIX}"/usr/lib/tmpfiles.d
163 - --enable-zlib=system
164 - --with-editor="${EPREFIX}"/usr/libexec/editor
165 - --with-env-editor
166 - --with-plugindir="${EPREFIX}"/usr/$(get_libdir)/sudo
167 - --with-rundir="${EPREFIX}"/run/sudo
168 - --with-vardir="${EPREFIX}"/var/db/sudo
169 - --without-linux-audit
170 - --without-opie
171 - $(use_enable gcrypt)
172 - $(use_enable nls)
173 - $(use_enable sasl)
174 - $(use_enable ssl openssl)
175 - $(use_with ldap)
176 - $(use_with ldap ldap_conf_file /etc/ldap.conf.sudo)
177 - $(use_with offensive insults)
178 - $(use_with offensive all-insults)
179 - $(use_with pam)
180 - $(use_with pam pam-login)
181 - $(use_with secure-path secure-path "${SECURE_PATH}")
182 - $(use_with selinux)
183 - $(use_with sendmail)
184 - $(use_with skey)
185 - $(use_with sssd)
186 - )
187 -
188 - econf "${myeconfargs[@]}"
189 -}
190 -
191 -src_install() {
192 - default
193 -
194 - if use ldap ; then
195 - dodoc README.LDAP
196 -
197 - cat <<-EOF > "${T}"/ldap.conf.sudo
198 - # See ldap.conf(5) and README.LDAP for details
199 - # This file should only be readable by root
200 -
201 - # supported directives: host, port, ssl, ldap_version
202 - # uri, binddn, bindpw, sudoers_base, sudoers_debug
203 - # tls_{checkpeer,cacertfile,cacertdir,randfile,ciphers,cert,key}
204 - EOF
205 -
206 - if use sasl ; then
207 - cat <<-EOF >> "${T}"/ldap.conf.sudo
208 -
209 - # SASL directives: use_sasl, sasl_mech, sasl_auth_id
210 - # sasl_secprops, rootuse_sasl, rootsasl_auth_id, krb5_ccname
211 - EOF
212 - fi
213 -
214 - insinto /etc
215 - doins "${T}"/ldap.conf.sudo
216 - fperms 0440 /etc/ldap.conf.sudo
217 -
218 - insinto /etc/openldap/schema
219 - newins doc/schema.OpenLDAP sudo.schema
220 - fi
221 -
222 - if use pam; then
223 - pamd_mimic system-auth sudo auth account session
224 - pamd_mimic system-auth sudo-i auth account session
225 - fi
226 -
227 - keepdir /var/db/sudo/lectured
228 - fperms 0700 /var/db/sudo/lectured
229 - fperms 0711 /var/db/sudo #652958
230 -
231 - # Don't install into /run as that is a tmpfs most of the time
232 - # (bug #504854)
233 - rm -rf "${ED}"/run || die
234 -
235 - find "${ED}" -type f -name "*.la" -delete || die #697812
236 -}
237 -
238 -pkg_postinst() {
239 - tmpfiles_process sudo.conf
240 -
241 - #652958
242 - local sudo_db="${EROOT}/var/db/sudo"
243 - if [[ "$(stat -c %a "${sudo_db}")" -ne 711 ]] ; then
244 - chmod 711 "${sudo_db}" || die
245 - fi
246 -
247 - if use ldap ; then
248 - ewarn
249 - ewarn "sudo uses the /etc/ldap.conf.sudo file for ldap configuration."
250 - ewarn
251 - if grep -qs '^[[:space:]]*sudoers:' "${ROOT}"/etc/nsswitch.conf ; then
252 - ewarn "In 1.7 series, LDAP is no more consulted, unless explicitly"
253 - ewarn "configured in /etc/nsswitch.conf."
254 - ewarn
255 - ewarn "To make use of LDAP, add this line to your /etc/nsswitch.conf:"
256 - ewarn " sudoers: ldap files"
257 - ewarn
258 - fi
259 - fi
260 - if use prefix ; then
261 - ewarn
262 - ewarn "To use sudo, you need to change file ownership and permissions"
263 - ewarn "with root privileges, as follows:"
264 - ewarn
265 - ewarn " # chown root:root ${EPREFIX}/usr/bin/sudo"
266 - ewarn " # chown root:root ${EPREFIX}/usr/lib/sudo/sudoers.so"
267 - ewarn " # chown root:root ${EPREFIX}/etc/sudoers"
268 - ewarn " # chown root:root ${EPREFIX}/etc/sudoers.d"
269 - ewarn " # chown root:root ${EPREFIX}/var/db/sudo"
270 - ewarn " # chmod 4111 ${EPREFIX}/usr/bin/sudo"
271 - ewarn
272 - fi
273 -
274 - elog "To use the -A (askpass) option, you need to install a compatible"
275 - elog "password program from the following list. Starred packages will"
276 - elog "automatically register for the use with sudo (but will not force"
277 - elog "the -A option):"
278 - elog ""
279 - elog " [*] net-misc/ssh-askpass-fullscreen"
280 - elog " net-misc/x11-ssh-askpass"
281 - elog ""
282 - elog "You can override the choice by setting the SUDO_ASKPASS environmnent"
283 - elog "variable to the program you want to use."
284 -}