summaryrefslogtreecommitdiff
path: root/amavis/amavisd.conf.addon.in
blob: 32db04445905cc869d16880621a47ecf78f29f99 (plain)
  1. #!/bin/perl
  2. #
  3. # /etc/local-COMMON/amavisd.conf.addon
  4. # Copyright 2002 Jonas Smedegaard <dr@jones.dk>
  5. #
  6. # $Id: amavisd.conf.addon.in,v 1.8 2004-03-11 00:36:46 jonas Exp $
  7. #
  8. # AMaViS configuration file addon (Debian package "amavisd-new")
  9. #
  10. # Put the following lines at the end of /etc/amavis/amavisd.conf:
  11. #
  12. # my $config_file_addon="/etc/local-COMMON/amavis/amavisd.conf.addon";
  13. # -f $config_file_addon or die "Cannot find config file $config_file_addon";
  14. # do $config_file_addon or die "Error in config file $config_file_addon: $@";
  15. #
  16. # We use SpamAssassin >= 2.44
  17. @bypass_spam_checks_acl = undef;
  18. $sa_auto_whitelist = 1;
  19. ## Let's bounce everything bad as suggested (why not bad headers per default?)
  20. # ...or let's not (yet)...
  21. #$final_spam_destiny = D_BOUNCE;
  22. #$final_bad_header_destiny = D_BOUNCE;
  23. # We set Postfix timeout to 1200 for the filter, so should be safe raising it here as well
  24. $child_timeout=15*60;
  25. # Deliver quarantined emails through postfix
  26. $virus_quarantine_to = 'virus-quarantine@';
  27. $spam_quarantine_to = 'spam-quarantine@';
  28. # We explicitly set local domains
  29. @local_domains_acl = undef;
  30. my $local_domain_file="/etc/local-COMMON/amavis/local_domains_$mydomain";
  31. if ( -f $local_domain_file ) {
  32. read_hash(\%local_domains, $local_domain_file);
  33. } else {
  34. warn "Ignoring non-existing file $local_domain_file";
  35. }
  36. # Let amavisd-new handle all bouncing (postfix dual-MTA setup can't properly)
  37. $final_virus_destiny = D_BOUNCE;
  38. $final_banned_destiny = D_BOUNCE;
  39. $final_spam_destiny = D_BOUNCE;
  40. $final_bad_header_destiny = D_BOUNCE;
  41. $virus_admin = "virusalert\@$mydomain";
  42. $spam_admin = "spamalert\@$mydomain";
  43. $mailfrom_notify_admin = "virusalert\@$mydomain";
  44. $mailfrom_notify_recip = "virusalert\@$mydomain";
  45. $mailfrom_notify_spamadmin = "spam.police\@$mydomain";
  46. map { $virus_lovers{lc($_)}=1; } (qw(
  47. postmaster@
  48. virusalert@
  49. ));
  50. map { $spam_lovers{lc($_)}=1; } (qw(
  51. postmaster@
  52. spamalert@
  53. ));