1

Topic: Disclaimer not working when sending SMTP port 25

==== Required information ====
- iRedMail version (check /etc/iredmail-release):
- Linux/BSD distribution name and version:
- Store mail accounts in which backend (LDAP/MySQL/PGSQL):
- Web server (Apache or Nginx):
- Manage mail accounts with iRedAdmin-Pro?
- [IMPORTANT] Related original log or error message is required if you're experiencing an issue.
======== Required information ====
- iRedMail version (check /etc/iredmail-release): 0.9.7
- Linux/BSD distribution name and version: Debian 9
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): MySQL
- Web server (Apache or Nginx): Nginx
- Manage mail accounts with iRedAdmin-Pro? NO
- [IMPORTANT] Related original log or error message is required if you're experiencing an issue.
====

Hi, guys
I'm trying to configure a disclaimer in ALL my outgoing mails but it's not working if I use port 25 to send via SMTP. I have a lot of old email clients using SMTP autentication via port 25 so I need to know if there is any solution to make it works fine.
I have tried send unsing GMail with these results :
- Send via GMail using port 25 : NOT WORKS
- Send via GMail using port 587 : ITS WORK

There is any solution for this ?

Thanks a lot

----

Spider Email Archiver: On-Premises, lightweight email archiving software developed by iRedMail team. Supports Amazon S3 compatible storage and custom branding.

2

Re: Disclaimer not working when sending SMTP port 25

There's a problem with port 25:

*) Port 25 is used for inbound, it's not configured to have disclaimer support by default (why do we append disclaimer text to a email from others, right?)
*) Port 587 is secure and used for end users to submit email, it has disclaimer support (and DKIM signing) by default. You should (maybe slowly) convince end users to switch to this port.
*) Maybe old mail clients doesn't support port 587 with TLS secure connection, you can try to open additional port 465 with SSL support, most old mail clients support it.

3

Re: Disclaimer not working when sending SMTP port 25

ZhangHuangbin wrote:

There's a problem with port 25:

*) Port 25 is used for inbound, it's not configured to have disclaimer support by default (why do we append disclaimer text to a email from others, right?)
*) Port 587 is secure and used for end users to submit email, it has disclaimer support (and DKIM signing) by default. You should (maybe slowly) convince end users to switch to this port.
*) Maybe old mail clients doesn't support port 587 with TLS secure connection, you can try to open additional port 465 with SSL support, most old mail clients support it.

Thanks a lot for your answer, ZhangHuangbin.

My problem is with Outlook who is sending using port 25. I have read a lot of "old" discussions about this issue, but I thinks it's was right in the last version. There is any way to add disclaimer support to port 25 ??

Thanks again ...

4

Re: Disclaimer not working when sending SMTP port 25

You can try this, but i just want to repeat myself, mix inbound and outbound on same port is a very bad idea, and this is not recommended at all.

*) Update Amavisd config file /etc/amavis/conf.d/50-user, add lines like below:

$originating = 1;
$enable_dkim_signing = 1;

*) Restart Amavisd service.

5

Re: Disclaimer not working when sending SMTP port 25

ZhangHuangbin wrote:

You can try this, but i just want to repeat myself, mix inbound and outbound on same port is a very bad idea, and this is not recommended at all.

*) Update Amavisd config file /etc/amavis/conf.d/50-user, add lines like below:

$originating = 1;
$enable_dkim_signing = 1;

*) Restart Amavisd service.

Hi, ZhangHuangbin

I know is a bad idea ... Thanks a lot. I'm going to try installing a SSL certtificate to avoid Outlook certificate alert when I use TLS port. This would the best solution, of course.

Thanks a lot for your help and support. Great !

Best regards from Spain.

6

Re: Disclaimer not working when sending SMTP port 25

lorenzo wrote:
ZhangHuangbin wrote:

You can try this, but i just want to repeat myself, mix inbound and outbound on same port is a very bad idea, and this is not recommended at all.

*) Update Amavisd config file /etc/amavis/conf.d/50-user, add lines like below:

$originating = 1;
$enable_dkim_signing = 1;

*) Restart Amavisd service.

Hi, ZhangHuangbin

I know is a bad idea ... Thanks a lot. I'm going to try installing a SSL certtificate to avoid Outlook certificate alert when I use TLS port. This would the best solution, of course.

Thanks a lot for your help and support. Great !

Best regards from Spain.

Hi, ZhangHuangbin,

I have tried your suggestion but it doesn't work.

The mails sent throught GMail using port 25 and plain auth doesn't include disclaimer, but if I configure GMail to send using port 587 the mails include disclaimer.

Any other thing to try ???

Thanks a lot

7

Re: Disclaimer not working when sending SMTP port 25

You'd better turn on debug mode in Amavisd to figure out why it doesn't work:
https://docs.iredmail.org/debug.amavisd.html

8

Re: Disclaimer not working when sending SMTP port 25

ZhangHuangbin wrote:

You'd better turn on debug mode in Amavisd to figure out why it doesn't work:
https://docs.iredmail.org/debug.amavisd.html

Hi,

Here is my log "DISCLAIMER" portion ...

May 24 09:19:05 deucalion02 amavis[15981]: (15981-01) lookup: (scalar) matches, result="disclaimer"
May 24 09:19:05 deucalion02 amavis[15981]: (15981-01) lookup [Mangling1] => true,  "dest@dest.com" matches, result="disclaimer", matching_key="(constant:disclaimer)"
May 24 09:19:05 deucalion02 amavis[15981]: (15981-01) will not add disclaimer, allow_disclaimers is false
May 24 09:19:05 deucalion02 amavis[15981]: (15981-01) mangling NO: 0 (was: disclaimer), discl_allowed=0, <origin@origin.com> -> <dest@dest.com>
May 24 09:19:05 deucalion02 amavis[15981]: (15981-01) final_destiny PASS, recip dest@dest.com

Of course if you need a bigger piece of log I can post it ...

I don't know because "allow_disclaimers is false" is there ...

Can you help me ?

Thanks a lot.

9

Re: Disclaimer not working when sending SMTP port 25

Yes we need and always need the FULL log related to the email. Filtered log will become useless because it may hide important log for troubleshooting.