Gentoo Archives: gentoo-commits

From: "Alfredo Tupone (tupone)" <tupone@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in mail-filter/qmail-scanner: ChangeLog qmail-scanner-2.01-r1.ebuild qmail-scanner-2.02-r1.ebuild qmail-scanner-2.05.ebuild
Date: Wed, 29 Oct 2008 20:17:47
Message-Id: E1KvHU8-0002ti-7C@stork.gentoo.org
1 tupone 08/10/29 20:17:44
2
3 Modified: ChangeLog qmail-scanner-2.01-r1.ebuild
4 qmail-scanner-2.02-r1.ebuild
5 Added: qmail-scanner-2.05.ebuild
6 Log:
7 Version bump to 2.05
8 (Portage version: 2.1.4.5)
9
10 Revision Changes Path
11 1.43 mail-filter/qmail-scanner/ChangeLog
12
13 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/mail-filter/qmail-scanner/ChangeLog?rev=1.43&view=markup
14 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/mail-filter/qmail-scanner/ChangeLog?rev=1.43&content-type=text/plain
15 diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/mail-filter/qmail-scanner/ChangeLog?r1=1.42&r2=1.43
16
17 Index: ChangeLog
18 ===================================================================
19 RCS file: /var/cvsroot/gentoo-x86/mail-filter/qmail-scanner/ChangeLog,v
20 retrieving revision 1.42
21 retrieving revision 1.43
22 diff -u -r1.42 -r1.43
23 --- ChangeLog 23 Aug 2008 05:57:29 -0000 1.42
24 +++ ChangeLog 29 Oct 2008 20:17:44 -0000 1.43
25 @@ -1,6 +1,13 @@
26 # ChangeLog for mail-filter/qmail-scanner
27 # Copyright 2002-2008 Gentoo Foundation; Distributed under the GPL v2
28 -# $Header: /var/cvsroot/gentoo-x86/mail-filter/qmail-scanner/ChangeLog,v 1.42 2008/08/23 05:57:29 cardoe Exp $
29 +# $Header: /var/cvsroot/gentoo-x86/mail-filter/qmail-scanner/ChangeLog,v 1.43 2008/10/29 20:17:44 tupone Exp $
30 +
31 +*qmail-scanner-2.05 (29 Oct 2008)
32 +
33 + 29 Oct 2008; Tupone Alfredo <tupone@g.o>
34 + +files/qmail-scanner-2.05.logrotate, qmail-scanner-2.01-r1.ebuild,
35 + qmail-scanner-2.02-r1.ebuild, +qmail-scanner-2.05.ebuild:
36 + Version bump to 2.05 & some minor fix
37
38 23 Aug 2008; Doug Goldstein <cardoe@g.o> metadata.xml:
39 add GLEP 56 USE flag desc from use.local.desc
40
41
42
43 1.2 mail-filter/qmail-scanner/qmail-scanner-2.01-r1.ebuild
44
45 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/mail-filter/qmail-scanner/qmail-scanner-2.01-r1.ebuild?rev=1.2&view=markup
46 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/mail-filter/qmail-scanner/qmail-scanner-2.01-r1.ebuild?rev=1.2&content-type=text/plain
47 diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/mail-filter/qmail-scanner/qmail-scanner-2.01-r1.ebuild?r1=1.1&r2=1.2
48
49 Index: qmail-scanner-2.01-r1.ebuild
50 ===================================================================
51 RCS file: /var/cvsroot/gentoo-x86/mail-filter/qmail-scanner/qmail-scanner-2.01-r1.ebuild,v
52 retrieving revision 1.1
53 retrieving revision 1.2
54 diff -u -r1.1 -r1.2
55 --- qmail-scanner-2.01-r1.ebuild 4 Jan 2008 22:45:16 -0000 1.1
56 +++ qmail-scanner-2.01-r1.ebuild 29 Oct 2008 20:17:44 -0000 1.2
57 @@ -1,6 +1,6 @@
58 # Copyright 1999-2008 Gentoo Foundation
59 # Distributed under the terms of the GNU General Public License v2
60 -# $Header: /var/cvsroot/gentoo-x86/mail-filter/qmail-scanner/qmail-scanner-2.01-r1.ebuild,v 1.1 2008/01/04 22:45:16 tupone Exp $
61 +# $Header: /var/cvsroot/gentoo-x86/mail-filter/qmail-scanner/qmail-scanner-2.01-r1.ebuild,v 1.2 2008/10/29 20:17:44 tupone Exp $
62
63 inherit fixheadtails toolchain-funcs eutils
64
65 @@ -46,7 +46,7 @@
66 unpack ${A}
67 cd "${S}"
68 rm index.php && cp README.html index.php
69 - epatch ${DISTDIR}/q-s-${PV}st-${Q_S_DATE}.patch.gz
70 + epatch "${DISTDIR}"/q-s-${PV}st-${Q_S_DATE}.patch.gz
71 ht_fix_file autoupdaters/* configure
72 sed -i \
73 -e "s:/var/spool/qscand:/var/spool/qscan:g" \
74
75
76
77 1.2 mail-filter/qmail-scanner/qmail-scanner-2.02-r1.ebuild
78
79 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/mail-filter/qmail-scanner/qmail-scanner-2.02-r1.ebuild?rev=1.2&view=markup
80 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/mail-filter/qmail-scanner/qmail-scanner-2.02-r1.ebuild?rev=1.2&content-type=text/plain
81 diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/mail-filter/qmail-scanner/qmail-scanner-2.02-r1.ebuild?r1=1.1&r2=1.2
82
83 Index: qmail-scanner-2.02-r1.ebuild
84 ===================================================================
85 RCS file: /var/cvsroot/gentoo-x86/mail-filter/qmail-scanner/qmail-scanner-2.02-r1.ebuild,v
86 retrieving revision 1.1
87 retrieving revision 1.2
88 diff -u -r1.1 -r1.2
89 --- qmail-scanner-2.02-r1.ebuild 13 Feb 2008 06:03:51 -0000 1.1
90 +++ qmail-scanner-2.02-r1.ebuild 29 Oct 2008 20:17:44 -0000 1.2
91 @@ -1,6 +1,6 @@
92 # Copyright 1999-2008 Gentoo Foundation
93 # Distributed under the terms of the GNU General Public License v2
94 -# $Header: /var/cvsroot/gentoo-x86/mail-filter/qmail-scanner/qmail-scanner-2.02-r1.ebuild,v 1.1 2008/02/13 06:03:51 tupone Exp $
95 +# $Header: /var/cvsroot/gentoo-x86/mail-filter/qmail-scanner/qmail-scanner-2.02-r1.ebuild,v 1.2 2008/10/29 20:17:44 tupone Exp $
96
97 inherit fixheadtails toolchain-funcs eutils
98
99 @@ -14,7 +14,7 @@
100
101 LICENSE="GPL-2"
102 SLOT="0"
103 -KEYWORDS="~amd64 ~x86"
104 +KEYWORDS="amd64 x86"
105 RESTRICT="userpriv"
106
107 DEPEND=">=dev-lang/perl-5.6.1-r1
108 @@ -48,7 +48,7 @@
109 src_unpack() {
110 unpack ${A}
111 cd "${S}"
112 - epatch ${DISTDIR}/q-s-${PV}st-${Q_S_DATE}.patch.gz
113 + epatch "${DISTDIR}"/q-s-${PV}st-${Q_S_DATE}.patch.gz
114 ht_fix_file autoupdaters/* configure
115 sed -i \
116 -e "s:/var/spool/qscand:/var/spool/qscan:g" \
117
118
119
120 1.1 mail-filter/qmail-scanner/qmail-scanner-2.05.ebuild
121
122 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/mail-filter/qmail-scanner/qmail-scanner-2.05.ebuild?rev=1.1&view=markup
123 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/mail-filter/qmail-scanner/qmail-scanner-2.05.ebuild?rev=1.1&content-type=text/plain
124
125 Index: qmail-scanner-2.05.ebuild
126 ===================================================================
127 # Copyright 1999-2008 Gentoo Foundation
128 # Distributed under the terms of the GNU General Public License v2
129 # $Header: /var/cvsroot/gentoo-x86/mail-filter/qmail-scanner/qmail-scanner-2.05.ebuild,v 1.1 2008/10/29 20:17:44 tupone Exp $
130
131 inherit fixheadtails toolchain-funcs eutils
132
133 Q_S_DATE=20080728
134 DESCRIPTION="E-Mail virus scanner for qmail."
135 HOMEPAGE="http://qmail-scanner.sourceforge.net/"
136 SRC_URI="mirror://sourceforge/qmail-scanner/${P}.tgz
137 http://toribio.apollinare.org/qmail-scanner/download/q-s-${PV}st-${Q_S_DATE}.patch.gz"
138
139 IUSE="clamav spamassassin"
140
141 LICENSE="GPL-2"
142 SLOT="0"
143 KEYWORDS="~amd64 ~x86"
144 RESTRICT="userpriv"
145
146 DEPEND="dev-lang/perl
147 virtual/perl-Time-HiRes
148 net-mail/tnef
149 virtual/perl-DB_File
150 mail-filter/maildrop
151 virtual/qmail
152 app-arch/unzip
153 sys-process/daemontools
154 virtual/antivirus
155 clamav? ( app-antivirus/clamav )
156 spamassassin? ( mail-filter/spamassassin )"
157
158 pkg_setup() {
159 enewgroup qscand 210
160 enewuser qscand 210 -1 /var/spool/qscan qscand
161 use clamav && usermod -a -G qscand,nofiles clamav
162 }
163
164 pkg_preinst() {
165 local oldname="/var/qmail/bin/qmail-scanner-queue.pl"
166 if [ -f ${oldname} ]; then
167 newname=${oldname}.`date +%Y%m%d%H%M%S`
168 elog "Backing up old qmail-scanner as $newname in case of modifications."
169 cp ${oldname} ${newname}
170 chmod 600 ${newname}
171 fi
172 }
173
174 src_unpack() {
175 unpack ${A}
176 cd "${S}"
177 epatch "${DISTDIR}"/q-s-${PV}st-${Q_S_DATE}.patch.gz
178 ht_fix_file autoupdaters/* configure
179 sed -i \
180 -e "s:/var/spool/qscand:/var/spool/qscan:g" \
181 README-st-patch.html \
182 README-st-patch.txt || die "Fixing doc with sed failed"
183
184 EXTRA_VIRII="bagle,beagle,mydoom,sco,maldal,mimail,novarg,shimg,bugler,cissi,cissy,dloade,netsky,qizy"
185 elog "Adding items to the SILENT_VIRUSES list (${EXTRA_VIRII})"
186 sed -e "/^SILENT_VIRUSES/s/\"$/,${EXTRA_VIRII}\"/g" -i configure
187 }
188
189 src_compile () {
190 local myconf
191
192 addpredict /var/log/kav/kavscan.log
193 addpredict /opt/bdc/plugins.htm
194
195 use spamassassin && myconf="--virus-to-delete yes --sa-quarantine 2.1 --sa-delete 4.2 --sa-reject no --sa-subject SPAM: --sa-delta 0.5 --sa-alt yes"
196
197 PATH=${PATH}:/opt/f-prot:/opt/vlnx ./configure \
198 --domain localhost \
199 --batch \
200 --log-details yes \
201 --skip-setuid-test \
202 ${myconf} \
203 || die "./configure failed!"
204
205 # build for qmail-scanner-queue wrapper, so we don't need suidperl
206 cd contrib
207 $(tc-getCC) ${CFLAGS} -o qmail-scanner-queue qmail-scanner-queue.c || die
208 }
209
210 src_install () {
211 # Create Directory Structure
212 diropts -m 755 -o qscand -g qscand
213 dodir /var/spool/qscan
214 keepdir /var/spool/qscan
215 diropts -m 750 -o qscand -g qscand
216 dodir /var/spool/qscan/quarantine
217 for i in quarantine/{viruses,policy,spam} working archives; do
218 for j in tmp new cur; do
219 dodir /var/spool/qscan/${i}/${j}
220 keepdir /var/spool/qscan/${i}/${j}
221 done
222 done
223 dodir /var/spool/qscan/tmp
224 keepdir /var/spool/qscan/tmp
225
226 # Install standard quarantine events file
227 insinto /var/spool/qscan
228 insopts -m 644 -o qscand -g qscand
229 doins quarantine-events.txt
230
231 # create quarantine.log and viruses.log
232 touch quarantine.log
233 insinto /var/spool/qscan
234 insopts -m 644 -o qscand -g qscand
235 doins quarantine.log
236 dosym quarantine.log ${DESTDIR}/var/spool/qscan/viruses.log
237
238 # Install qmail-scanner wrapper
239 insinto /var/qmail/bin
240 insopts -m 4755 -o qscand -g qscand
241 doins contrib/qmail-scanner-queue
242
243 # Install qmail-scanner script
244 insinto /var/qmail/bin
245 insopts -m 0755 -o qscand -g qscand
246 doins qmail-scanner-queue.pl
247
248 insinto /etc/logrotate.d/
249 insopts -m 644 -o root -g root
250 newins "${FILESDIR}"/${P}.logrotate qmail-scanner
251
252 exeinto /etc/cron.daily/
253 newexe "${FILESDIR}"/qmailscanner.cronjob qmail-scanner
254
255 # Install documentation
256 dodoc README CHANGES
257 dohtml README.html FAQ.php TODO.php configure-options.php manual-install.php perlscanner.php
258
259 docinto contrib
260 cd "${S}"/contrib
261 dodoc spamc-nice.eml \
262 test-trophie.pl \
263 logrotate.qmail-scanner \
264 sub-avpdaemon.pl \
265 logging_first_80_chars.eml \
266 spamc-nasty.eml \
267 avpdeamon.init \
268 test_installation.sh \
269 test-sophie.pl \
270 reformime-test.eml \
271 sub-sender-cache.pl \
272 rbl_scanner.txt \
273 test-clamd.pl \
274 qs2mrtg.pl \
275 mrtg-qmail-scanner.cfg \
276 check_AV_daemons \
277 patch_for_nod32_single_user.eml \
278 qmail-delay \
279 qs-scanner-report.sh \
280 qs_config.sh \
281 qscan-spam-to-users.pl \
282 test-avgd.pl \
283 test_password.zip \
284 vpopmail-issues.eml
285 }
286
287 pkg_postinst () {
288 einfo "Fixing ownerships"
289 chown -R qscand:qscand /var/spool/qscan
290 touch /var/qmail/bin/qmail-scanner-queue.pl
291
292 # Setup perlscanner + Version Info
293 chmod -s "${ROOT}"/var/qmail/bin/qmail-scanner-queue.pl
294 "${ROOT}"/var/qmail/bin/qmail-scanner-queue -z
295 "${ROOT}"/var/qmail/bin/qmail-scanner-queue -g
296
297 elog "To activate qmail-scanner, please edit your"
298 elog "/var/qmail/control/conf-common file and set:"
299 elog "export QMAILQUEUE=/var/qmail/bin/qmail-scanner-queue"
300 elog "Or place it in your tcprules file."
301 ewarn "Please note that it was a call to qmail-scanner-queue.pl before,"
302 ewarn "but this is now changed to use a wrapper to improve security!"
303 ewarn "Once you have changed to the wrapper, you can remove the setuid "
304 ewarn "bit on qmail-scanner-queue.pl"
305
306 ewarn "If this is an upgrade from <=2.0.1 the home directory of the qscand"
307 ewarn "user is changed. Please update it manually to /var/spool/qscan"
308 ewarn "or remove the user and emerge again this package"
309
310 if use clamav; then
311 ewarn "To allow clamav integration comment-out in /etc/clamd.conf:"
312 ewarn "AllowSupplementaryGroups putting yes."
313 ewarn "After that, restart clamd with"
314 ewarn "/etc/init.d/clamd restart"
315 fi
316 }