bad_header_lovers

Andrea gabellini - SC andrea.gabellini.sc at telecomitalia.sm
Sat Mar 24 10:02:46 CET 2012


Mark,

thank you very much for the detailed info!!!

Andrea

Il 23/03/2012 14:47, Mark Martinec ha scritto:
> Andrea,
>
>> I need to skip the bad_header results based on the from address.
>> Is it possible? If yes, haw can I configure it?
> Currently you can only do this through loading of a policy bank,
> e.g.:
>
> $policy_bank{'NOHCHK'} = {
>   bypass_header_checks_maps => [1]
> };
>
> A policy bank can be loaded based on an incoming TCP port number,
> or based on a SMTP client's IP address, or based on a valid DKIM
> signature. This is certainly a cleanest and simplest solution,
> e.g.:
>
> @author_to_policy_bank_maps = (
>   {
>     'example.com' => 'NOHCHK',
>   }
> );
>
>
> There is no off-the-shelf mechanism to load a policy bank based
> on a sender address, although you can do so through a custom hook,
> e.g.:
>
> amavisd.conf:
>   include_config_files('/etc/amavisd-custom.conf');
>
>
> amavid-custom.conf:
>
> package Amavis::Custom;
> use strict;
>
> sub new {
>   my($class,$conn,$msginfo) = @_;
>   my $self = bless {}, $class;
>   if ($msginfo->sender =~ /\@example\.com\z/i ) {
>     Amavis::load_policy_bank('NOHCHK',$msginfo);
>   }
>   $self;
> }
>
> 1;
>
>
>
>   Mark


More information about the amavis-users mailing list