problem with transport

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

problem with transport

mami64
Hi
Sorry about my probably stupid and easy question.

I have one server for outgoing smtp and I added a spamassassin to
filtered outgoing e-mial

This is trivial like

cut master.cf:
---- start ---------

smtp      inet  n    -    n    -    -    smtpd -o
content_filter=spamassassin
....
submission inet n    -    -    -    -    smtpd
  -o content_filter=spamassassin
  -o smtpd_milters=
  -o syslog_name=postfix/submission
....
spamassassin unix -     n    n    -    -    pipe
        user=filter argv=/usr/bin/spamc -f -e /usr/sbin/sendmail -oi -f
${sender} ${recipient}


----- end ----

I use DKIM (added like documentations)

In log i found double added DKIM - because the mail goes back to the
queue and smtpd_milters tags it again ...

Probably I must create a returns transport with "-o smtpd_milters="
But I dont have idea - maby I thing wrong ...

works fine for 587,465 but not 25

log:
http://paste.debian.net/1133556/

I have many vdomain and I don't want to use amavis


Reply | Threaded
Open this post in threaded view
|

Re: problem with transport

Jaroslaw Rafa
Dnia  5.03.2020 o godz. 12:06:43 natan maciej milaszewski pisze:
>
> I use DKIM (added like documentations)
>
> In log i found double added DKIM - because the mail goes back to the
> queue and smtpd_milters tags it again ...
>
> Probably I must create a returns transport with "-o smtpd_milters="
> But I dont have idea - maby I thing wrong ...

Instead of using spamassassin as a content filter, as in your example,
you have to use spamass-milter, it's a Milter interface to spamassassin.
Then you will avoid double DKIM.
--
Regards,
   Jaroslaw Rafa
   [hidden email]
--
"In a million years, when kids go to school, they're gonna know: once there
was a Hushpuppy, and she lived with her daddy in the Bathtub."
Reply | Threaded
Open this post in threaded view
|

Re: problem with transport

mami64
Hi
Thenx for replay :) You have right

I forget add a "-o smtpd_milters" in smtp

smtp      inet  n    -    n    -    -    smtpd
 -o content_filter=spamassassin
 -o smtpd_milters=

But Your solution is better

On 05.03.2020 12:19, Jaroslaw Rafa wrote:

> Dnia  5.03.2020 o godz. 12:06:43 natan maciej milaszewski pisze:
>> I use DKIM (added like documentations)
>>
>> In log i found double added DKIM - because the mail goes back to the
>> queue and smtpd_milters tags it again ...
>>
>> Probably I must create a returns transport with "-o smtpd_milters="
>> But I dont have idea - maby I thing wrong ...
> Instead of using spamassassin as a content filter, as in your example,
> you have to use spamass-milter, it's a Milter interface to spamassassin.
> Then you will avoid double DKIM.

Reply | Threaded
Open this post in threaded view
|

Re: problem with transport

mami64
In reply to this post by Jaroslaw Rafa
Hi
Is it possible to second add header_checks after milter check ?

milter_protocol = 2
milter_default_action = accept

milter_connect_macros = j {daemon_name} v {if_name} _
smtpd_milters =
unix:/run/spamass-milter/spamass-milter.sock,inet:localhost:12301
non_smtpd_milters =
unix:/run/spamass-milter/spamass-milter.sock,inet:localhost:12301

I need solutions for if find spam then hold in queue like:
/^X-Spam-Flag:.YES/             HOLD text




On 05.03.2020 12:19, Jaroslaw Rafa wrote:

> Dnia  5.03.2020 o godz. 12:06:43 natan maciej milaszewski pisze:
>> I use DKIM (added like documentations)
>>
>> In log i found double added DKIM - because the mail goes back to the
>> queue and smtpd_milters tags it again ...
>>
>> Probably I must create a returns transport with "-o smtpd_milters="
>> But I dont have idea - maby I thing wrong ...
> Instead of using spamassassin as a content filter, as in your example,
> you have to use spamass-milter, it's a Milter interface to spamassassin.
> Then you will avoid double DKIM.

Reply | Threaded
Open this post in threaded view
|

Re: problem with transport

Wietse Venema
natan maciej milaszewski:
> Hi
> Is it possible to second add header_checks after milter check ?

milter_header_checks are applied to headers that are added by a
Milter. This can be used to ignore, log, or replace header text.

        Wietse
Reply | Threaded
Open this post in threaded view
|

Re: problem with transport

mami64
Hi
Thenx for replay :) Working perfectly :)

On 06.03.2020 13:07, Wietse Venema wrote:
> natan maciej milaszewski:
>> Hi
>> Is it possible to second add header_checks after milter check ?
> milter_header_checks are applied to headers that are added by a
> Milter. This can be used to ignore, log, or replace header text.
>
> Wietse