diff options
Diffstat (limited to 'amavis')
-rw-r--r-- | amavis/.cvsignore | 1 | ||||
-rw-r--r-- | amavis/amavisd.conf.addon | 127 | ||||
-rw-r--r-- | amavis/amavisd.conf.addon.in | 34 | ||||
-rwxr-xr-x | amavis/mkaddon.sh | 40 |
4 files changed, 201 insertions, 1 deletions
diff --git a/amavis/.cvsignore b/amavis/.cvsignore new file mode 100644 index 0000000..d2d5bc6 --- /dev/null +++ b/amavis/.cvsignore @@ -0,0 +1 @@ +amavisd.conf.addon.old diff --git a/amavis/amavisd.conf.addon b/amavis/amavisd.conf.addon index 0b175bf..7d56d03 100644 --- a/amavis/amavisd.conf.addon +++ b/amavis/amavisd.conf.addon @@ -1,8 +1,10 @@ +### WARNING: This file is generated automatically. +### Please edit amavisd.conf.addon.in and run mkaddon.sh # # /etc/local-COMMON/amavisd.conf.addon # Copyright 2002 Jonas Smedegaard <dr@jones.dk> # -# $Id: amavisd.conf.addon,v 1.8 2003-06-28 09:39:41 jonas Exp $ +# $Id: amavisd.conf.addon,v 1.9 2003-07-12 12:55:48 jonas Exp $ # # AMaViS configuration file addon (Debian package "amavisd-new") # @@ -17,6 +19,10 @@ @bypass_spam_checks_acl = undef; $sa_auto_whitelist = 1; +# Let's bounce everything bad as suggested (why not bad headers per default?) +$final_spam_destiny = D_BOUNCE; +$final_bad_header_destiny = D_BOUNCE; + # We explicitly set local domains @local_domains_acl = undef; read_hash(\%local_domains, "/etc/local-COMMON/amavis/local_domains_$mydomain"); @@ -29,3 +35,122 @@ map { $virus_lovers{lc($_)}=1; $spam_lovers{lc($_)}=1; } (qw( postmaster@ )); +$virus_admin = { + '.altnet.dk' => 'virusalert@bitbase.dk', + '.ascii33.com' => 'virusalert@bitbase.dk', + '.bitbase.dk' => 'virusalert@bitbase.dk', + '.dekadentfilm.dk' => 'virusalert@bitbase.dk', + '.gangstafilm.dk' => 'virusalert@bitbase.dk', + '.hcfotografi.dk' => 'virusalert@bitbase.dk', + '.icas.dk' => 'virusalert@bitbase.dk', + '.minard.dk' => 'virusalert@bitbase.dk', + '.patientsikkerhed.dk' => 'virusalert@bitbase.dk', + '.resolution.dk' => 'virusalert@bitbase.dk', + '.respons.dk' => 'virusalert@bitbase.dk', + '.sebastianw.dk' => 'virusalert@bitbase.dk', + '.taekkemand.net' => 'virusalert@bitbase.dk', + '.diamond2002.dk' => 'virusalert@homebase.dk', + '.flightnavigator.dk' => 'virusalert@homebase.dk', + '.frontloberne.dk' => 'virusalert@homebase.dk', + '.frontloeberne.dk' => 'virusalert@homebase.dk', + '.frontrunners.net' => 'virusalert@homebase.dk', + '.homebase.dk' => 'virusalert@homebase.dk', + '.kaos-communication.com' => 'virusalert@homebase.dk', + '.kaos-communication.dk' => 'virusalert@homebase.dk', + '.kaoscommunication.com' => 'virusalert@homebase.dk', + '.kaoscommunication.dk' => 'virusalert@homebase.dk', + '.kaoshardcore.com' => 'virusalert@homebase.dk', + '.kaoshardcore.dk' => 'virusalert@homebase.dk', + '.kaosheartcore.com' => 'virusalert@homebase.dk', + '.kaosheartcore.dk' => 'virusalert@homebase.dk', + '.kaoslab.dk' => 'virusalert@homebase.dk', + '.kaosman.com' => 'virusalert@homebase.dk', + '.kaosman.dk' => 'virusalert@homebase.dk', + '.kaosmanagement.com' => 'virusalert@homebase.dk', + '.kaosmanagement.dk' => 'virusalert@homebase.dk', + '.kaospilot.dk' => 'virusalert@homebase.dk', + '.localplayers.dk' => 'virusalert@homebase.dk', + '.nyxforum.dk' => 'virusalert@homebase.dk', + '.stellabella.com' => 'virusalert@homebase.dk', + '.haakansson.com' => 'virusalert@haakansson.com', + '.bawnager.dk' => 'virusalert@jones.dk', + '.cph-bmx.dk' => 'virusalert@jones.dk', + '.craignative.com' => 'virusalert@jones.dk', + '.dgi-huset.dk' => 'virusalert@jones.dk', + '.faelleskab.dk' => 'virusalert@jones.dk', + '.faelleskabet.dk' => 'virusalert@jones.dk', + '.faellesskab.dk' => 'virusalert@jones.dk', + '.helbak.com' => 'virusalert@jones.dk', + '.helbak.dk' => 'virusalert@jones.dk', + '.jones.dk' => 'virusalert@jones.dk', + '.kassandra-production.dk' => 'virusalert@jones.dk', + '.knudemand.dk' => 'virusalert@jones.dk', + '.knudemanden.dk' => 'virusalert@jones.dk', + '.macronald.dk' => 'virusalert@jones.dk', + '.nilsstaerk.dk' => 'virusalert@jones.dk', + '.nord-utte.org' => 'virusalert@jones.dk', + '.public-e.dk' => 'virusalert@jones.dk', + '.riccos.dk' => 'virusalert@jones.dk', + '.vesterkaer.dk' => 'virusalert@jones.dk', + '.' => "virusalert\@$mydomain", +}; + +$spam_admin = { + '.altnet.dk' => 'spamalert@bitbase.dk', + '.ascii33.com' => 'spamalert@bitbase.dk', + '.bitbase.dk' => 'spamalert@bitbase.dk', + '.dekadentfilm.dk' => 'spamalert@bitbase.dk', + '.gangstafilm.dk' => 'spamalert@bitbase.dk', + '.hcfotografi.dk' => 'spamalert@bitbase.dk', + '.icas.dk' => 'spamalert@bitbase.dk', + '.minard.dk' => 'spamalert@bitbase.dk', + '.patientsikkerhed.dk' => 'spamalert@bitbase.dk', + '.resolution.dk' => 'spamalert@bitbase.dk', + '.respons.dk' => 'spamalert@bitbase.dk', + '.sebastianw.dk' => 'spamalert@bitbase.dk', + '.taekkemand.net' => 'spamalert@bitbase.dk', + '.diamond2002.dk' => 'spamalert@homebase.dk', + '.flightnavigator.dk' => 'spamalert@homebase.dk', + '.frontloberne.dk' => 'spamalert@homebase.dk', + '.frontloeberne.dk' => 'spamalert@homebase.dk', + '.frontrunners.net' => 'spamalert@homebase.dk', + '.homebase.dk' => 'spamalert@homebase.dk', + '.kaos-communication.com' => 'spamalert@homebase.dk', + '.kaos-communication.dk' => 'spamalert@homebase.dk', + '.kaoscommunication.com' => 'spamalert@homebase.dk', + '.kaoscommunication.dk' => 'spamalert@homebase.dk', + '.kaoshardcore.com' => 'spamalert@homebase.dk', + '.kaoshardcore.dk' => 'spamalert@homebase.dk', + '.kaosheartcore.com' => 'spamalert@homebase.dk', + '.kaosheartcore.dk' => 'spamalert@homebase.dk', + '.kaoslab.dk' => 'spamalert@homebase.dk', + '.kaosman.com' => 'spamalert@homebase.dk', + '.kaosman.dk' => 'spamalert@homebase.dk', + '.kaosmanagement.com' => 'spamalert@homebase.dk', + '.kaosmanagement.dk' => 'spamalert@homebase.dk', + '.kaospilot.dk' => 'spamalert@homebase.dk', + '.localplayers.dk' => 'spamalert@homebase.dk', + '.nyxforum.dk' => 'spamalert@homebase.dk', + '.stellabella.com' => 'spamalert@homebase.dk', + '.haakansson.com' => 'spamalert@haakansson.com', + '.bawnager.dk' => 'spamalert@jones.dk', + '.cph-bmx.dk' => 'spamalert@jones.dk', + '.craignative.com' => 'spamalert@jones.dk', + '.dgi-huset.dk' => 'spamalert@jones.dk', + '.faelleskab.dk' => 'spamalert@jones.dk', + '.faelleskabet.dk' => 'spamalert@jones.dk', + '.faellesskab.dk' => 'spamalert@jones.dk', + '.helbak.com' => 'spamalert@jones.dk', + '.helbak.dk' => 'spamalert@jones.dk', + '.jones.dk' => 'spamalert@jones.dk', + '.kassandra-production.dk' => 'spamalert@jones.dk', + '.knudemand.dk' => 'spamalert@jones.dk', + '.knudemanden.dk' => 'spamalert@jones.dk', + '.macronald.dk' => 'spamalert@jones.dk', + '.nilsstaerk.dk' => 'spamalert@jones.dk', + '.nord-utte.org' => 'spamalert@jones.dk', + '.public-e.dk' => 'spamalert@jones.dk', + '.riccos.dk' => 'spamalert@jones.dk', + '.vesterkaer.dk' => 'spamalert@jones.dk', + '.' => "spamalert\@$mydomain", +}; diff --git a/amavis/amavisd.conf.addon.in b/amavis/amavisd.conf.addon.in new file mode 100644 index 0000000..ce60af4 --- /dev/null +++ b/amavis/amavisd.conf.addon.in @@ -0,0 +1,34 @@ +# +# /etc/local-COMMON/amavisd.conf.addon +# Copyright 2002 Jonas Smedegaard <dr@jones.dk> +# +# $Id: amavisd.conf.addon.in,v 1.1 2003-07-12 12:55:48 jonas Exp $ +# +# AMaViS configuration file addon (Debian package "amavisd-new") +# +# Put the following lines at the end of /etc/amavis/amavisd.conf: +# +# my $config_file_addon="/etc/local-COMMON/amavis/amavisd.conf.addon"; +# -f $config_file_addon or die "Cannot find config file $config_file_addon"; +# do $config_file_addon or die "Error in config file $config_file_addon: $@"; +# + +# We use SpamAssassin >= 2.44 +@bypass_spam_checks_acl = undef; +$sa_auto_whitelist = 1; + +# Let's bounce everything bad as suggested (why not bad headers per default?) +$final_spam_destiny = D_BOUNCE; +$final_bad_header_destiny = D_BOUNCE; + +# We explicitly set local domains +@local_domains_acl = undef; +read_hash(\%local_domains, "/etc/local-COMMON/amavis/local_domains_$mydomain"); + +$spam_admin = "spamalert\@$mydomain"; + +#$virus_lovers{lc('postmaster@')} = 1; +#$spam_lovers{lc('postmaster@')} = 1; +map { $virus_lovers{lc($_)}=1; $spam_lovers{lc($_)}=1; } (qw( + postmaster@ +)); diff --git a/amavis/mkaddon.sh b/amavis/mkaddon.sh new file mode 100755 index 0000000..9840053 --- /dev/null +++ b/amavis/mkaddon.sh @@ -0,0 +1,40 @@ +#!/bin/sh + +set -e + +basedir="/etc/local-COMMON/amavis" +destfile="amavisd.conf.addon" + +>"$basedir"/"$destfile".new cat <<EOF +### WARNING: This file is generated automatically. +### Please edit $destfile.in and run mkaddon.sh +EOF + +cat "$basedir"/"$destfile".in >> "$basedir"/"$destfile".new + +domainfiles="`find "$basedir" -name 'local_domains_*' -type f`" +maildomains="" +for domainfile in $domainfiles; do + maildomain="`basename $domainfile | sed 's/local_domains_//'`" + maildomain_="`echo $maildomain | sed 's/\./_/g'`" + maildomains="$maildomains $maildomain" + domains="`cat "$domainfile" | grep -v '^#' | sed 's/#.*//'`" + eval "domains_$maildomain_=\"$domains\"" +done + +for thing in virus spam; do + echo >> "$basedir"/"$destfile".new + echo "\$${thing}_admin = {" >> "$basedir"/"$destfile".new + for maildomain in $maildomains; do + maildomain_="`echo $maildomain | sed 's/\./_/g'`" + eval "domains=\"\$domains_$maildomain_\"" + for domain in $domains; do + echo " '.$domain' => '${thing}alert@$maildomain'," >> "$basedir"/"$destfile".new + done + done + echo " '.' => \"${thing}alert\\@\$mydomain\"," >> "$basedir"/"$destfile".new + echo "};" >> "$basedir"/"$destfile".new +done + +cp -af "$basedir"/"$destfile" "$basedir"/"$destfile".old +mv "$basedir"/"$destfile".new "$basedir"/"$destfile" |