1

Topic: SMTP relay rejection despite white listing

======== Required information ====
- iRedMail version (check /etc/iredmail-release): 0.9.6
- Linux/BSD distribution name and version:  Ubuntu 16.04
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): mySQL
- Web server (Apache or Nginx): Apache
- Manage mail accounts with iRedAdmin-Pro? No
- [IMPORTANT] Related original log or error message is required if you're experiencing an issue.
====
I have now successfully gotten a couple of servers which use a remote SMTP server to logon successfully for their update reports - thank you for your help on that - but I still have one small obstacle. I have one server which requires a local copy of postfix to send out its emails. This is working perfectly with the existing mailserver I am looking to replace but I cannot get iRedMail to accept the incoming mail.

I have modified iRedMail as follows (taken from the thread http://www.iredmail.org/forum/topic1257 … work.html)

/etc/postfix/main.cf parameter "mynetworks ="
is now "mynetworks =127.0.0.1, 172.16.1.50".

/opt/iredapd/settings.py, parameter "MYNETWORKS ="
is now "MYNETWORKS =172.16.1.50"

iRedMail server generates the following response as taken from /var/log/mail.log

Jul  4 11:14:26 mail2 postfix/postscreen[20367]: CONNECT from [172.16.1.50]:38150 to [172.16.1.42]:25
Jul  4 11:14:26 mail2 postfix/postscreen[20367]: WHITELISTED [172.16.1.50]:38150
Jul  4 11:14:26 mail2 postfix/smtpd[20368]: connect from server1.domain.net[172.16.1.50]
Jul  4 11:14:26 mail2 postfix/smtpd[20368]: NOQUEUE: reject: RCPT from server1.domain.net[172.16.1.50]: 554 5.7.1 <chris@domain.net>: Recipient address rejected: Policy rejection not logged in; from=<root@domain.net> to=<chris@domain.net> proto=ESMTP helo=<server1>
Jul  4 11:14:26 mail2 postfix/smtpd[20368]: disconnect from server1.domain.net[172.16.1.50] ehlo=1 mail=1 rcpt=0/1 data=0/1 rset=1 quit=1 commands=4/6
Jul  4 11:14:26 mail2 postfix/postscreen[20367]: CONNECT from [172.16.1.50]:38151 to [172.16.1.42]:25
Jul  4 11:14:26 mail2 postfix/postscreen[20367]: WHITELISTED [172.16.1.50]:38151
Jul  4 11:14:26 mail2 postfix/smtpd[20368]: connect from server1.domain.net[172.16.1.50]
Jul  4 11:14:26 mail2 postfix/smtpd[20368]: NOQUEUE: reject: RCPT from server1.domain.net[172.16.1.50]: 451 4.7.1 <root@domain.net>: Recipient address rejected: Intentional policy rejection, please try again later; from=<> to=<root@domain.net> proto=ESMTP helo=<server1>
Jul  4 11:14:26 mail2 postfix/smtpd[20368]: disconnect from server1.domain.net[172.16.1.50] ehlo=1 mail=1 rcpt=0/1 data=0/1 rset=1 quit=1 commands=4/6

Can you please advise what I need to do to allow this through? Thank you.

----

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

2

Re: SMTP relay rejection despite white listing

have you tried this?

http://www.iredmail.org/docs/manage.iredapd.html

3

Re: SMTP relay rejection despite white listing

I have looked at so many things lately I am not sure. It looks familiar, but I cannot recall if it was before or after this issue. I will work my way through it again anyway and see. Thanks for the heads up.

4

Re: SMTP relay rejection despite white listing

chc-pr wrote:

/opt/iredapd/settings.py, parameter "MYNETWORKS ="
is now "MYNETWORKS =172.16.1.50"

Syntax is wrong. it must be a Python list object like this:

MYNETWORKS = ['172.16.1.50', '192.168.1.1']

After modified iRedAPD, restarting iredapd service is required.

5

Re: SMTP relay rejection despite white listing

Thanks, I tried that syntax (it was commented out - all I had to do was uncomment), but I guess I didn't restart iRedAPD (doh!) It works now :-)