>> Paradoxically, a simpler solution in your case is to use a more
>> complex MTA+amavisd setup, letting MTA separate mail into originating
>> (=locally submitted) and all the rest, and feeding each flow
>> on a separate amavisd port.
>>
>> When code sections in current versions of amavisd need to know whether
>> mail is originating from local users or not, they only consult a state
>> of
>> a flag $originating. This includes deciding whether mail is eligible
> to
>> DKIM signing or not.
>>
>> The $originating flag can be set by a policy bank:
>>   originating => 1
>> or can be set implicitly by matching a client IP address against the
>> @mynetworks list of local networks. See release notes for version
>> 2.5.0.
>>
>> Up to version 2.5.0 the implicit way was the only mechanism available,
>> so @mynetworks needed to be set correctly.
>>
>> Starting with 2.5.0 the @mynetworks is mostly just a convenient
>> legacy mechanism for implicitly setting the $originating flag.
>> Use it if you only have few local networks and no roaming
> authenticated
>> mail submitters, otherwise just set $originating flag explicitly by a
>> port-based policy bank and can forget about @mynetworks.
>
> How I have to tell to the MTA to distinguish between local submitted
> messages and not (I'm using Postfix)?
>

Great!!! Thanks Mark, I've read your mail carefully and so I ve solved. In
/etc/amavisd.conf I ve put

$inet_socket_port = [10024,10026];

$interface_policy{'10026'} = 'SENDERBYPASS';

$policy_bank{'SENDERBYPASS'} = {
        originating => 1,
};

and in /etc/postfix/main.cf I have set:

smtpd_client_restrictions =
    check_client_access
proxy:mysql:/etc/postfix/mysql-check-client-filter-access.cf

where /etc/postfix/mysql-check-client-filter-access.cf:

user = ***
password = ***
hosts = ***
dbname = ***
query = <returns 'FILTER smtp-amavis:[127.0.0.1]:10026 if ip is enabled
for relaying, the action set in DB otherwise>

Thanks,

rocsca


------------------------------------------------------------------------------
This SF.net email is sponsored by:
SourcForge Community
SourceForge wants to tell your story.
http://p.sf.net/sfu/sf-spreadtheword
_______________________________________________
AMaViS-user mailing list
[email protected] 
https://lists.sourceforge.net/lists/listinfo/amavis-user 
 AMaViS-FAQ:http://www.amavis.org/amavis-faq.php3 
 AMaViS-HowTos:http://www.amavis.org/howto/ 

Reply via email to