Advertisement
Guest User

Untitled

a guest
Mar 30th, 2020
162
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Perl 3.71 KB | None | 0 0
  1. use strict;
  2.  
  3. #
  4. # Place your configuration directives here.  They will override those in
  5. # earlier files.
  6. #
  7. # See /usr/share/doc/amavisd-new/ for documentation and examples of
  8. # the directives you can use in this file
  9. #
  10.  
  11. $notify_method      = 'smtp:[127.0.0.1]:10025';
  12. $forward_method     = 'smtp:[127.0.0.1]:10025';
  13.  
  14. $max_servers        = 10;
  15. @local_domains_maps = ( [".$mydomain"] );
  16.  
  17. $QUARANTINEDIR = undef;
  18.  
  19. $final_virus_destiny            = D_DISCARD;  # (data not lost, see virus quarantine)
  20. $final_banned_destiny           = D_DISCARD;  # D_REJECT when front-end MTA
  21. $final_spam_destiny             = D_DISCARD;
  22. $final_bad_header_destiny       = D_PASS;     # False-positive prone (for spam)
  23.  
  24. # $virus_quarantine_method = "smtp:10.9.8.19:25";
  25. # $bad_header_quarantine_method = "smtp:10.9.8.19:25";
  26. $banned_files_quarantine_method = "smtp:10.9.8.19:25";
  27. $spam_quarantine_method = "smtp:10.9.8.19:25";
  28.  
  29. # $virus_quarantine_to = "spam\@a1.ind.br";
  30. # $bad_header_quarantine_to = "spam\@a1.ind.br";
  31. $banned_files_quarantine_to = "spam\@a1.ind.br";
  32. $spam_quarantine_to = "spam\@a1.ind.br";
  33.  
  34. $defang_spam = 0;
  35.  
  36. $enable_dkim_verification = 1; #disabled to prevent warning
  37.  
  38. $sa_spam_subject_tag            = '';
  39. $sa_tag_level_deflt             = -999; # add spam info headers if at, or above that level
  40. $sa_tag2_level_deflt            = 5; # add 'spam detected' headers at that level
  41. $sa_kill_level_deflt            = 5; # triggers spam evasive actions
  42. $sa_dsn_cutoff_level            = 7.50; # spam level beyond which a DSN is not sent
  43.  
  44. # @bypass_virus_checks_maps => ();
  45. @bypass_virus_checks_maps = (
  46.    \%bypass_virus_checks, \@bypass_virus_checks_acl, \$bypass_virus_checks_re);
  47.  
  48. # @bypass_spam_checks_maps = ();
  49. @bypass_spam_checks_maps = (
  50.    \%bypass_spam_checks, \@bypass_spam_checks_acl, \$bypass_spam_checks_re);
  51.  
  52.  
  53. @av_scanners = (
  54.  
  55. ### http://www.clamav.net/
  56.  ['ClamAV-clamd',
  57.    \&ask_daemon, ["CONTSCAN {}\n", "/var/run/clamav/clamd.ctl"],
  58.    qr/\bOK$/m, qr/\bFOUND$/m,
  59.    qr/^.*?: (?!Infected Archive)(.*) FOUND$/m ],
  60. # NOTE: run clamd under the same user as amavisd, or run it under its own
  61. #   uid such as clamav, add user clamav to the amavis group, and then add
  62. #   AllowSupplementaryGroups to clamd.conf;
  63. # NOTE: match socket name (LocalSocket) in clamav.conf to the socket name in
  64. #   this entry; when running chrooted one may prefer socket "$MYHOME/clamd".
  65.  
  66. );
  67.  
  68. $banned_filename_re = new_RE(
  69.  
  70.   # block certain double extensions anywhere in the base name
  71.   qr'\.[^./]*\.(exe|vbs|vbe|pif|scr|bat|cmd|com|cpl|dll|jar)\.?$'i,
  72.   qr'\{[0-9a-f]{8}(-[0-9a-f]{4}){3}-[0-9a-f]{12}\}?$'i, # Windows Class ID CLSID, strict
  73.   # qr'^application/x-msdownload$'i,                  # block these MIME types
  74.   qr'^application/x-msdos-program$'i,
  75.   qr'^application/hta$'i,
  76.   qr'.\.(exe|vbs|vbe|vb|pif|scr|msi|bat|cmd|com|cpl|hta|z|jar|wsf|js|mp4|img)$'i, # banned extension - basic
  77. #  qr'.\.(exe|vbs|vbe|vb|pif|scr|bat|cmd|com|cpl|html?|hta|z|jar|wsf|js|mp4)$'i, # banned extension - basic
  78. # qr'.\.(ade|adp|app|bas|bat|chm|cmd|com|cpl|crt|emf|exe|fxp|grp|hlp|hta|
  79. #        inf|ins|isp|js|jse|lnk|mda|mdb|mde|mdw|mdt|mdz|msc|msi|msp|mst|
  80. #        ops|pcd|pif|prg|reg|scr|sct|shb|shs|vb|vbe|vbs|
  81. #        wmf|wsc|wsf|wsh)$'ix,  # banned ext - long
  82.   qr'^\.(exe-ms)$',                       # banned file(1) types
  83.   qr'^\.(exe|lha|cab|dll|vbs|vbe|hta|js)$',         # banned file(1) types
  84. );
  85. # See http://support.microsoft.com/default.aspx?scid=kb;EN-US;q262631
  86. # and http://www.cknow.com/vtutor/vtextensions.htm
  87.  
  88. map { $whitelist_sender{lc($_)}=1 } (qw(
  89.     cert-advisory-owner@cert.org
  90.     owner-alert@iss.net
  91.     slashdot@slashdot.org
  92.     bugtraq@securityfocus.com
  93.     mail@tstparana.ning.com
  94. ));
  95.  
  96. #------------ Do not modify anything below this line -------------
  97. 1;  # ensure a defined return
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement