From edbb239a67bd663c98c042c0d6da6af875c4ec6d Mon Sep 17 00:00:00 2001 From: Dinko Korunic Date: Mon, 13 Apr 2009 13:03:41 +0200 Subject: [PATCH] - upgrade za Lenny - ciscenje zareza iz network stringova (treba backportati na Etch isti fix) - ciscenje ::1 i ffff:127.0.0.0 IPv6 loopback adresa iz trusted_networks (moze upasti kroz Postfix conf) - ispravni depsi za Lenny --- README.CARNet | 22 ++++++++-------------- debian/changelog | 8 ++++++++ debian/control | 6 +++--- debian/postinst | 8 +++++--- 4 files changed, 24 insertions(+), 20 deletions(-) diff --git a/README.CARNet b/README.CARNet index 012fee1..46e9c0e 100644 --- a/README.CARNet +++ b/README.CARNet @@ -2,26 +2,20 @@ spamassassin-cn ~~~~~~~~~~~~~~~ Ovo je dodatak na standardni SpamAssassin paket. Glavne razlike su u -mogucnosti upravljanja postavkama (Bayes klasifikator, Razor2, Pyzor) -u local.cf te potpuniji local.cf predlozak sa postavkama spremnim za +mogucnosti upravljanja postavkama (Bayes klasifikator, Razor2, Pyzor) u +local.cf te potpuniji local.cf predlozak sa postavkama spremnim za produkciju. Takodjer, koriste se popularna SARE pravila kroz sa-update mehanizam (GPG potpisani updateovi), a i sam SpamAssassin se automatski nadogradjuje kroz receni mehanizam. -Logovi koji se generiraju kroz nadogradjivanje SpamAssassina se -standardno spremaju u /var/log/sa-update.log. Daljnje modifikacije pravila -koja se skidaju su moguca kroz datoteku -/etc/spamassassin/sa-update.channels. +Logovi koji se generiraju kroz nadogradjivanje SpamAssassina se standardno +spremaju u /var/log/sa-update.log. Daljnje modifikacije pravila koja se +skidaju su moguca kroz datoteku /etc/spamassassin/sa-update.channels. -Standardno Pyzor i Bayes nisu ukljuceni iz sljedecih razloga: - * Pyzor posluzitelji uglavnom timeoutaju i time ne predstavljaju ozbiljan - izbor za klasifikaciju, - * Naivni Bayes klasifikator je inicijalno nauciti kroz uzorak od 1000 - spamova i 1000 hamova koristeci sa-learn. Nakon toga je isti takodjer - potrebno redovno trenirati na pogreskama, sto dakle ocekuje prilicnu - paznju od sistemaca. +Standardno Pyzor nije ukljucen zato sto se Pyzor posluzitelji uglavnom +timeoutaju i time ne predstavljaju ozbiljan izbor za klasifikaciju, Takodjer se standardno ne omogucuje ni SpamAssassin daemon odnosno spamd, buduci da je na instalacijama sa Amavis posluziteljem suvisan. - -- Dinko Korunic Tue, 19 Aug 2008 16:55:47 +0200 + -- Dinko Korunic Mon, 13 Apr 2009 12:17:38 +0200 diff --git a/debian/changelog b/debian/changelog index 505ff92..913265c 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,11 @@ +spamassassin-cn (2:3.2.5-10) stable; urgency=low + + * Upgrade paketa za Lenny + * Ciscenje svih ::1, 127/8 raspona iz trusted_networks, kao i zareza (ovisno + o Postfix konfiguraciji) + + -- Dinko Korunic Mon, 13 Apr 2009 12:30:17 +0200 + spamassassin-cn (2:3.2.5-6) stable; urgency=low * spajanje IP klasa iz mynetworks Postfix konfiguracije u trusted_networks diff --git a/debian/control b/debian/control index 2e689b3..a95ae82 100644 --- a/debian/control +++ b/debian/control @@ -1,14 +1,14 @@ Source: spamassassin-cn Section: mail Priority: optional -Maintainer: Dinko Korunic +Maintainer: Dinko Korunic Build-Depends: debhelper (>= 4) Standards-Version: 3.7.2 Package: spamassassin-cn Architecture: all -Depends: spamassassin (>= 3.2.5-2~bpo40+1), razor (>= 2.810-2), libnet-dns-perl, carnet-tools-cn (>= 2.0), gnupg (>= 1.4.6-2), libmail-dkim-perl (>= 0.19-3), libcrypt-openssl-bignum-perl (>= 0.03-1), libmail-spf-query-perl (>= 1.999.1-2), ${misc:Depends} -Recommends: amavis +Depends: spamassassin (>= 3.2.5-2), razor (>= 1:2.85-1), libnet-dns-perl (>= 0.63-2), carnet-tools-cn (>= 2.8.1), gnupg (>= 1.4.9-3), libmail-dkim-perl (>= 0.32-1), libcrypt-openssl-bignum-perl (>= 0.04-1+b1), libmail-spf-query-perl (>= 1:1.999.1-3), ${misc:Depends} +Recommends: amavisd-new Description: Perl-based spam filter using text analysis SpamAssassin is a very powerful and fully configurable spam filter with numerous features including automatic white-listing, RBL diff --git a/debian/postinst b/debian/postinst index e931e54..ff854eb 100755 --- a/debian/postinst +++ b/debian/postinst @@ -204,7 +204,7 @@ if [ -f $examdir/local.cf ]; then netaddr="$RET" # ... get already configured trusted networks trusted_networks=$(awk '/^trusted_networks/ { print $2 }' \ - $confdir/local.cf.$$) + $confdir/local.cf.$$ | sed -e 's/,/ /g') # ... merge with local networks configured on eth interfaces for i in $netaddr; do if ! echo "$trusted_networks" | grep -q "$i"; then @@ -213,7 +213,7 @@ if [ -f $examdir/local.cf ]; then done # ... merge with Postfix ranges if [ -x /usr/sbin/postconf ]; then - for i in $(postconf -h mynetworks); do + for i in $(postconf -h mynetworks | sed -e 's/,/ /g'); do if ! echo "$trusted_networks" | grep -q "$i"; then trusted_networks="$trusted_networks $i" fi @@ -221,10 +221,12 @@ if [ -f $examdir/local.cf ]; then fi # ... strip 127/8 range for i in $trusted_networks; do - if ! echo "$i" | grep -q "127.0.0.0/8"; then + if ! echo "$i" | egrep -q \ + "127.0.0.0/8|\[::1\]/128|\[::ffff:127.0.0.0\]/104"; then trusted_networks_clean="$trusted_networks_clean $i" fi done + # ... strip left and right blanks from final string trusted_networks_clean=$(echo "$trusted_networks_clean" \ | sed 's/^[ \t]*//;s/[ \t]*$//') # ... and replace if non-zero -- 1.7.10.4