Gentoo Archives: gentoo-commits

From: Michael Orlitzky <mjo@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: mail-filter/opendkim/
Date: Wed, 01 May 2019 03:50:20
Message-Id: 1556681892.b25aafe5f47dd4ae9c78a397fe7752c3e8c2978c.mjo@gentoo
1 commit: b25aafe5f47dd4ae9c78a397fe7752c3e8c2978c
2 Author: Michael Orlitzky <mjo <AT> gentoo <DOT> org>
3 AuthorDate: Wed May 1 00:41:22 2019 +0000
4 Commit: Michael Orlitzky <mjo <AT> gentoo <DOT> org>
5 CommitDate: Wed May 1 03:38:12 2019 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b25aafe5
7
8 mail-filter/opendkim: remove old "unused" -r9 and -r10 ebuilds.
9
10 Signed-off-by: Michael Orlitzky <mjo <AT> gentoo.org>
11 Package-Manager: Portage-2.3.62, Repoman-2.3.11
12
13 mail-filter/opendkim/opendkim-2.10.3-r10.ebuild | 227 -----------------------
14 mail-filter/opendkim/opendkim-2.10.3-r9.ebuild | 229 ------------------------
15 2 files changed, 456 deletions(-)
16
17 diff --git a/mail-filter/opendkim/opendkim-2.10.3-r10.ebuild b/mail-filter/opendkim/opendkim-2.10.3-r10.ebuild
18 deleted file mode 100644
19 index 8cba8ef6170..00000000000
20 --- a/mail-filter/opendkim/opendkim-2.10.3-r10.ebuild
21 +++ /dev/null
22 @@ -1,227 +0,0 @@
23 -# Copyright 1999-2019 Gentoo Authors
24 -# Distributed under the terms of the GNU General Public License v2
25 -
26 -EAPI=6
27 -
28 -inherit autotools db-use eutils systemd user
29 -
30 -DESCRIPTION="A milter providing DKIM signing and verification"
31 -HOMEPAGE="http://opendkim.org/"
32 -SRC_URI="mirror://sourceforge/opendkim/${P}.tar.gz"
33 -
34 -# The GPL-2 is for the init script, bug 425960.
35 -LICENSE="BSD GPL-2 Sendmail-Open-Source"
36 -SLOT="0"
37 -KEYWORDS="~amd64 ~arm ~x86"
38 -IUSE="+berkdb ldap libressl lmdb lua memcached opendbx poll sasl selinux +ssl static-libs unbound"
39 -
40 -DEPEND="|| ( mail-filter/libmilter mail-mta/sendmail )
41 - dev-libs/libbsd
42 - ssl? (
43 - !libressl? ( dev-libs/openssl:0= )
44 - libressl? ( dev-libs/libressl:0= )
45 - )
46 - berkdb? ( >=sys-libs/db-3.2:* )
47 - opendbx? ( >=dev-db/opendbx-1.4.0 )
48 - lua? ( dev-lang/lua:* )
49 - ldap? ( net-nds/openldap )
50 - lmdb? ( dev-db/lmdb )
51 - memcached? ( dev-libs/libmemcached )
52 - sasl? ( dev-libs/cyrus-sasl )
53 - unbound? ( >=net-dns/unbound-1.4.1:= net-dns/dnssec-root )
54 - !unbound? ( net-libs/ldns )"
55 -
56 -RDEPEND="${DEPEND}
57 - sys-process/psmisc
58 - selinux? ( sec-policy/selinux-dkim )
59 -"
60 -
61 -REQUIRED_USE="sasl? ( ldap )"
62 -
63 -PATCHES=(
64 - "${FILESDIR}/${P}-openssl-1.1.1.patch"
65 -)
66 -
67 -pkg_setup() {
68 - # This user can read your private keys, and must therefore not be
69 - # shared with any other package.
70 - enewgroup opendkim
71 - enewuser opendkim -1 -1 -1 opendkim
72 -}
73 -
74 -src_prepare() {
75 - default
76 -
77 - # We delete the "Socket" setting because it's overridden by our
78 - # conf.d file.
79 - sed -e 's:/var/db/dkim:/var/lib/opendkim:g' \
80 - -e '/^[[:space:]]*Socket/d' \
81 - -i opendkim/opendkim.conf.sample opendkim/opendkim.conf.simple.in \
82 - stats/opendkim-reportstats{,.in} || die
83 -
84 - sed -i -e 's:dist_doc_DATA:dist_html_DATA:' libopendkim/docs/Makefile.am \
85 - || die
86 -
87 - # TODO: what purpose does this serve, do the tests even get run?
88 - sed -e "/sock.*mt.getcwd/s:mt.getcwd():${T}:" \
89 - -i opendkim/tests/*.lua || die
90 -
91 - eautoreconf
92 -}
93 -
94 -src_configure() {
95 - local myconf=()
96 - if use berkdb ; then
97 - myconf+=(
98 - $(db_includedir)
99 - --with-db-incdir=${myconf#-I}
100 - --enable-popauth
101 - --enable-query_cache
102 - --enable-stats
103 - )
104 - fi
105 - if use unbound; then
106 - myconf+=( --with-unbound )
107 - else
108 - myconf+=( --with-ldns )
109 - fi
110 - if use ldap; then
111 - myconf+=( $(use_with sasl) )
112 - fi
113 - econf \
114 - $(use_with berkdb db) \
115 - $(use_with opendbx odbx) \
116 - $(use_with lua) \
117 - $(use_enable lua rbl) \
118 - $(use_with ldap openldap) \
119 - $(use_with lmdb) \
120 - $(use_enable poll) \
121 - $(use_enable static-libs static) \
122 - $(use_with memcached libmemcached) \
123 - "${myconf[@]}" \
124 - --enable-filter \
125 - --enable-atps \
126 - --enable-identity_header \
127 - --enable-rate_limit \
128 - --enable-resign \
129 - --enable-replace_rules \
130 - --enable-default_sender \
131 - --enable-sender_macro \
132 - --enable-vbr \
133 - --disable-live-testing
134 -}
135 -
136 -src_install() {
137 - default
138 - prune_libtool_files
139 -
140 - dosbin stats/opendkim-reportstats
141 -
142 - newinitd "${FILESDIR}/opendkim.init.r6" opendkim
143 - newconfd "${FILESDIR}/opendkim.confd" opendkim
144 - systemd_newunit "${FILESDIR}/opendkim.service.r4" opendkim.service
145 - systemd_install_serviced "${FILESDIR}/${PN}.service.conf" "${PN}.service"
146 -
147 - dodir /etc/opendkim
148 - keepdir /var/lib/opendkim
149 -
150 - # The OpenDKIM data (particularly, your keys) should be read-only to
151 - # the UserID that the daemon runs as.
152 - fowners root:opendkim /var/lib/opendkim
153 - fperms 750 /var/lib/opendkim
154 -
155 - # Strip the comments out of the "simple" example configuration...
156 - grep ^[^#] "${S}"/opendkim/opendkim.conf.simple \
157 - > "${T}/opendkim.conf" || die
158 -
159 - # and tweak it a bit before installing it unconditionally.
160 - echo "# For use with unbound" >> "${T}/opendkim.conf" || die
161 - echo "#TrustAnchorFile /etc/dnssec/root-anchors.txt" \
162 - >> "${T}/opendkim.conf" || die
163 - echo "UserID opendkim" >> "${T}/opendkim.conf" || die
164 -
165 - # The UMask is really only used for the PID file (root:root) and the
166 - # local UNIX socket, if you're using one. It should be 0117 for the
167 - # socket, so we might as well set that unconditionally here.
168 - echo "UMask 0117" >> "${T}/opendkim.conf" || die
169 -
170 - insinto /etc/opendkim
171 - doins "${T}/opendkim.conf"
172 -}
173 -
174 -pkg_postinst() {
175 - if [[ -z ${REPLACING_VERSION} ]]; then
176 - elog "If you want to sign your mail messages and need some help"
177 - elog "please run:"
178 - elog " emerge --config ${CATEGORY}/${PN}"
179 - elog "It will help you create your key and give you hints on how"
180 - elog "to configure your DNS and MTA."
181 -
182 - # TODO: This is tricky, we really need a good wiki page showing
183 - # how to share a local socket with an MTA!
184 - elog "If you are using a local (UNIX) socket, then you will"
185 - elog "need to make sure that your MTA has read/write access"
186 - elog "to the socket file. This is best accomplished by creating"
187 - elog "a completely-new group with only your MTA user and the "
188 - elog "\"opendkim\" user in it. You would then set \"UMask 0112\""
189 - elog "in your opendkim.conf, and switch the primary group of your"
190 - elog "\"opendkim\" user to the group that you just created. The"
191 - elog "last step is necessary for the socket to be created as the"
192 - elog "new group (and not as group \"opendkim\")".
193 - else
194 - ewarn "The user account for the OpenDKIM daemon has changed"
195 - ewarn "from \"milter\" to \"opendkim\" to prevent unrelated services"
196 - ewarn "from being able to read your private keys. You should"
197 - ewarn "adjust your existing configuration to use the \"opendkim\""
198 - ewarn "user and group, and change the permissions on"
199 - ewarn "${ROOT}var/lib/opendkim to root:opendkim with mode 0750."
200 - ewarn "The owner and group of the files within that directory"
201 - ewarn "will likely need to be adjusted as well."
202 - fi
203 -}
204 -
205 -pkg_config() {
206 - local selector keysize pubkey
207 -
208 - read -p "Enter the selector name (default ${HOSTNAME}): " selector
209 - [[ -n "${selector}" ]] || selector="${HOSTNAME}"
210 - if [[ -z "${selector}" ]]; then
211 - eerror "Oddly enough, you don't have a HOSTNAME."
212 - return 1
213 - fi
214 - if [[ -f "${ROOT}var/lib/opendkim/${selector}.private" ]]; then
215 - ewarn "The private key for this selector already exists."
216 - else
217 - keysize=1024
218 - # Generate the private and public keys. Note that opendkim-genkeys
219 - # sets umask=077 on its own to keep these safe. However, we want
220 - # them to be readable (only!) to the opendkim user, and we manage
221 - # that by changing their groups and making everything group-readable.
222 - opendkim-genkey -b ${keysize} -D "${ROOT}"var/lib/opendkim/ \
223 - -s "${selector}" -d '(your domain)' && \
224 - chgrp --no-dereference opendkim \
225 - "${ROOT}var/lib/opendkim/${selector}".{private,txt} || \
226 - { eerror "Failed to create private and public keys." ;
227 - return 1; }
228 - chmod g+r "${ROOT}var/lib/opendkim/${selector}".{private,txt}
229 - fi
230 -
231 - # opendkim selector configuration
232 - echo
233 - einfo "Make sure you have the following settings in your /etc/opendkim/opendkim.conf:"
234 - einfo " Keyfile /var/lib/opendkim/${selector}.private"
235 - einfo " Selector ${selector}"
236 -
237 - # MTA configuration
238 - echo
239 - einfo "If you are using Postfix, add following lines to your main.cf:"
240 - einfo " smtpd_milters = unix:/run/opendkim/opendkim.sock"
241 - einfo " non_smtpd_milters = unix:/run/opendkim/opendkim.sock"
242 - einfo " and read http://www.postfix.org/MILTER_README.html"
243 -
244 - # DNS configuration
245 - einfo "After you configured your MTA, publish your key by adding this TXT record to your domain:"
246 - cat "${ROOT}var/lib/opendkim/${selector}.txt"
247 - einfo "t=y signifies you only test the DKIM on your domain. See following page for the complete list of tags:"
248 - einfo " http://www.dkim.org/specs/rfc4871-dkimbase.html#key-text"
249 -}
250
251 diff --git a/mail-filter/opendkim/opendkim-2.10.3-r9.ebuild b/mail-filter/opendkim/opendkim-2.10.3-r9.ebuild
252 deleted file mode 100644
253 index 9a9ff14612a..00000000000
254 --- a/mail-filter/opendkim/opendkim-2.10.3-r9.ebuild
255 +++ /dev/null
256 @@ -1,229 +0,0 @@
257 -# Copyright 1999-2019 Gentoo Authors
258 -# Distributed under the terms of the GNU General Public License v2
259 -
260 -EAPI=6
261 -
262 -inherit autotools db-use eutils systemd user
263 -
264 -DESCRIPTION="A milter providing DKIM signing and verification"
265 -HOMEPAGE="http://opendkim.org/"
266 -SRC_URI="mirror://sourceforge/opendkim/${P}.tar.gz"
267 -
268 -# The GPL-2 is for the init script, bug 425960.
269 -LICENSE="BSD GPL-2 Sendmail-Open-Source"
270 -SLOT="0"
271 -KEYWORDS="~amd64 ~arm ~x86"
272 -IUSE="+berkdb gnutls ldap libressl lmdb lua memcached opendbx poll sasl selinux +ssl static-libs unbound"
273 -
274 -DEPEND="|| ( mail-filter/libmilter mail-mta/sendmail )
275 - dev-libs/libbsd
276 - ssl? (
277 - !libressl? ( dev-libs/openssl:0= )
278 - libressl? ( dev-libs/libressl:0= )
279 - )
280 - berkdb? ( >=sys-libs/db-3.2:* )
281 - opendbx? ( >=dev-db/opendbx-1.4.0 )
282 - lua? ( dev-lang/lua:* )
283 - ldap? ( net-nds/openldap )
284 - lmdb? ( dev-db/lmdb )
285 - memcached? ( dev-libs/libmemcached )
286 - sasl? ( dev-libs/cyrus-sasl )
287 - unbound? ( >=net-dns/unbound-1.4.1:= net-dns/dnssec-root )
288 - !unbound? ( net-libs/ldns )
289 - gnutls? ( >=net-libs/gnutls-3.3 )"
290 -
291 -RDEPEND="${DEPEND}
292 - sys-process/psmisc
293 - selinux? ( sec-policy/selinux-dkim )
294 -"
295 -
296 -REQUIRED_USE="sasl? ( ldap )"
297 -
298 -PATCHES=(
299 - "${FILESDIR}/${P}-gnutls-3.4.patch"
300 - "${FILESDIR}/${P}-openssl-1.1.1.patch"
301 -)
302 -
303 -pkg_setup() {
304 - # This user can read your private keys, and must therefore not be
305 - # shared with any other package.
306 - enewuser opendkim
307 -}
308 -
309 -src_prepare() {
310 - default
311 -
312 - # We delete the "Socket" setting because it's overridden by our
313 - # conf.d file.
314 - sed -e 's:/var/db/dkim:/var/lib/opendkim:g' \
315 - -e '/^[[:space:]]*Socket/d' \
316 - -i opendkim/opendkim.conf.sample opendkim/opendkim.conf.simple.in \
317 - stats/opendkim-reportstats{,.in} || die
318 -
319 - sed -i -e 's:dist_doc_DATA:dist_html_DATA:' libopendkim/docs/Makefile.am \
320 - || die
321 -
322 - # TODO: what purpose does this serve, do the tests even get run?
323 - sed -e "/sock.*mt.getcwd/s:mt.getcwd():${T}:" \
324 - -i opendkim/tests/*.lua || die
325 -
326 - eautoreconf
327 -}
328 -
329 -src_configure() {
330 - local myconf=()
331 - if use berkdb ; then
332 - myconf+=(
333 - $(db_includedir)
334 - --with-db-incdir=${myconf#-I}
335 - --enable-popauth
336 - --enable-query_cache
337 - --enable-stats
338 - )
339 - fi
340 - if use unbound; then
341 - myconf+=( --with-unbound )
342 - else
343 - myconf+=( --with-ldns )
344 - fi
345 - if use ldap; then
346 - myconf+=( $(use_with sasl) )
347 - fi
348 - econf \
349 - $(use_with berkdb db) \
350 - $(use_with opendbx odbx) \
351 - $(use_with lua) \
352 - $(use_enable lua rbl) \
353 - $(use_with ldap openldap) \
354 - $(use_with lmdb) \
355 - $(use_enable poll) \
356 - $(use_enable static-libs static) \
357 - $(use_with gnutls) \
358 - $(use_with memcached libmemcached) \
359 - "${myconf[@]}" \
360 - --enable-filter \
361 - --enable-atps \
362 - --enable-identity_header \
363 - --enable-rate_limit \
364 - --enable-resign \
365 - --enable-replace_rules \
366 - --enable-default_sender \
367 - --enable-sender_macro \
368 - --enable-vbr \
369 - --disable-live-testing
370 -}
371 -
372 -src_install() {
373 - default
374 - prune_libtool_files
375 -
376 - dosbin stats/opendkim-reportstats
377 -
378 - newinitd "${FILESDIR}/opendkim.init.r6" opendkim
379 - newconfd "${FILESDIR}/opendkim.confd" opendkim
380 - systemd_newunit "${FILESDIR}/opendkim.service.r4" opendkim.service
381 - systemd_install_serviced "${FILESDIR}/${PN}.service.conf" "${PN}.service"
382 -
383 - dodir /etc/opendkim
384 - keepdir /var/lib/opendkim
385 -
386 - # The OpenDKIM data (particularly, your keys) should be read-only to
387 - # the UserID that the daemon runs as.
388 - fowners root:opendkim /var/lib/opendkim
389 - fperms 750 /var/lib/opendkim
390 -
391 - # Strip the comments out of the "simple" example configuration...
392 - grep ^[^#] "${S}"/opendkim/opendkim.conf.simple \
393 - > "${T}/opendkim.conf" || die
394 -
395 - # and tweak it a bit before installing it unconditionally.
396 - echo "# For use with unbound" >> "${T}/opendkim.conf" || die
397 - echo "#TrustAnchorFile /etc/dnssec/root-anchors.txt" \
398 - >> "${T}/opendkim.conf" || die
399 - echo "UserID opendkim" >> "${T}/opendkim.conf" || die
400 -
401 - # The UMask is really only used for the PID file (root:root) and the
402 - # local UNIX socket, if you're using one. It should be 0117 for the
403 - # socket, so we might as well set that unconditionally here.
404 - echo "UMask 0117" >> "${T}/opendkim.conf" || die
405 -
406 - insinto /etc/opendkim
407 - doins "${T}/opendkim.conf"
408 -}
409 -
410 -pkg_postinst() {
411 - if [[ -z ${REPLACING_VERSION} ]]; then
412 - elog "If you want to sign your mail messages and need some help"
413 - elog "please run:"
414 - elog " emerge --config ${CATEGORY}/${PN}"
415 - elog "It will help you create your key and give you hints on how"
416 - elog "to configure your DNS and MTA."
417 -
418 - # TODO: This is tricky, we really need a good wiki page showing
419 - # how to share a local socket with an MTA!
420 - elog "If you are using a local (UNIX) socket, then you will"
421 - elog "need to make sure that your MTA has read/write access"
422 - elog "to the socket file. This is best accomplished by creating"
423 - elog "a completely-new group with only your MTA user and the "
424 - elog "\"opendkim\" user in it. You would then set \"UMask 0112\""
425 - elog "in your opendkim.conf, and switch the primary group of your"
426 - elog "\"opendkim\" user to the group that you just created. The"
427 - elog "last step is necessary for the socket to be created as the"
428 - elog "new group (and not as group \"opendkim\")".
429 - else
430 - ewarn "The user account for the OpenDKIM daemon has changed"
431 - ewarn "from \"milter\" to \"opendkim\" to prevent unrelated services"
432 - ewarn "from being able to read your private keys. You should"
433 - ewarn "adjust your existing configuration to use the \"opendkim\""
434 - ewarn "user and group, and change the permissions on"
435 - ewarn "${ROOT}var/lib/opendkim to root:opendkim with mode 0750."
436 - ewarn "The owner and group of the files within that directory"
437 - ewarn "will likely need to be adjusted as well."
438 - fi
439 -}
440 -
441 -pkg_config() {
442 - local selector keysize pubkey
443 -
444 - read -p "Enter the selector name (default ${HOSTNAME}): " selector
445 - [[ -n "${selector}" ]] || selector="${HOSTNAME}"
446 - if [[ -z "${selector}" ]]; then
447 - eerror "Oddly enough, you don't have a HOSTNAME."
448 - return 1
449 - fi
450 - if [[ -f "${ROOT}var/lib/opendkim/${selector}.private" ]]; then
451 - ewarn "The private key for this selector already exists."
452 - else
453 - keysize=1024
454 - # Generate the private and public keys. Note that opendkim-genkeys
455 - # sets umask=077 on its own to keep these safe. However, we want
456 - # them to be readable (only!) to the opendkim user, and we manage
457 - # that by changing their groups and making everything group-readable.
458 - opendkim-genkey -b ${keysize} -D "${ROOT}"var/lib/opendkim/ \
459 - -s "${selector}" -d '(your domain)' && \
460 - chgrp --no-dereference opendkim \
461 - "${ROOT}var/lib/opendkim/${selector}".{private,txt} || \
462 - { eerror "Failed to create private and public keys." ;
463 - return 1; }
464 - chmod g+r "${ROOT}var/lib/opendkim/${selector}".{private,txt}
465 - fi
466 -
467 - # opendkim selector configuration
468 - echo
469 - einfo "Make sure you have the following settings in your /etc/opendkim/opendkim.conf:"
470 - einfo " Keyfile /var/lib/opendkim/${selector}.private"
471 - einfo " Selector ${selector}"
472 -
473 - # MTA configuration
474 - echo
475 - einfo "If you are using Postfix, add following lines to your main.cf:"
476 - einfo " smtpd_milters = unix:/run/opendkim/opendkim.sock"
477 - einfo " non_smtpd_milters = unix:/run/opendkim/opendkim.sock"
478 - einfo " and read http://www.postfix.org/MILTER_README.html"
479 -
480 - # DNS configuration
481 - einfo "After you configured your MTA, publish your key by adding this TXT record to your domain:"
482 - cat "${ROOT}var/lib/opendkim/${selector}.txt"
483 - einfo "t=y signifies you only test the DKIM on your domain. See following page for the complete list of tags:"
484 - einfo " http://www.dkim.org/specs/rfc4871-dkimbase.html#key-text"
485 -}