1

Topic: Relay access denied

Hi all,

First of all, thanks to iredmail for this great installer!
Let's begin : After i installed everything step by step using freeBsd tutorial, i added an email account, etc and everything works fine (smtp auth -plain/ssl,pop3,webmail)
I tryed to send an email(with smtp auth):

Mar 15 16:44:38 mail postfix/smtpd[1354]: NOQUEUE: reject: RCPT from unknown[192.168.100.150]: 554 5.7.1 <xxxxxxxxx@ymail.com>: Relay access denied; from=<user@mydomain.com> to=<xxxxxxxxx@ymail.com> proto=ESMTP helo=<icedevilPc>

I think this need a simple fix, but i'm a beginner and i don't know what is wrong with my configuration.

Please advice.
Thanks!

----

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

2

Re: Relay access denied

Post your postfix config via 'postconf -n', it should be like this:

smtpd_recipient_restrictions =
    ...
    check_policy_service inet:127.0.0.1:7777,
    permit_mynetworks,
    permit_sasl_authenticated,
    reject_unauth_destination,
    ...

reject_unauth_destination should be after 'permit_sasl_authenticated'.

3

Re: Relay access denied

Thanks for reply!
I modifyed the main.cf to:
"permit_sasl_authenticated,
  reject_unauth_destination,"
they were reversed in my original file.

After this:
1. auth
Mar 15 17:31:40 mail postfix/smtpd[1350]: 2DBB74D0A81C: client=unknown[192.168.100.150], sasl_method=LOGIN, sasl_username=user@domain.com

2.error

Mar 15 17:31:40 mail postfix/smtp[1356]: 2DBB74D0A81C: to=<xxxxxxxxx@ymail.com>, relay=none, delay=0.09, delays=0.07/0.01/0/0, dsn=4.4.1, status=deferred (connect to 127.0.0.1[127.0.0.1]:10024: Connection refused)

here is my opened ports on localhost(127.0.0.1)
dovecot  managesiev 1311  4  tcp4   127.0.0.1:2000        *:*
dovecot  managesiev 1310  4  tcp4   127.0.0.1:2000        *:*
dovecot  managesiev 1309  4  tcp4   127.0.0.1:2000        *:*
root     dovecot    1214  10 tcp4   127.0.0.1:2000        *:*
root     master     1185  100 tcp4  127.0.0.1:10025       *:*
policyd  postfix-po 1128  6  tcp4   127.0.0.1:10031       *:*
policyd  postfix-po 1128  7  tcp4   127.0.0.1:19837       127.0.0.1:3306
mysql    mysqld     1090  25 tcp4   127.0.0.1:3306        127.0.0.1:19837

there is no 10024 open port.

Thank you very much!

4

Re: Relay access denied

Is amavis running ?
Because that port belongs to it.

5

Re: Relay access denied

well, look at this:

mail# /usr/local/etc/rc.d/amavisd status
amavisd is not running.
mail# /usr/local/etc/rc.d/amavisd start
Starting amavisd.
mail# /usr/local/etc/rc.d/amavisd status
amavisd is not running.

mail# cat /var/log/maillog
...
...
...
Mar 15 18:02:26 mail amavis[1560]: Using primary internal av scanner code for ClamAV-clamd
Mar 15 18:02:26 mail amavis[1560]: Found secondary av scanner ClamAV-clamscan at /usr/local/bin/clamscan
Mar 15 18:02:26 mail amavis[1560]: Creating db in /var/amavis/db/; BerkeleyDB 0.41, libdb 4.6
Mar 15 18:02:26 mail amavis[1560]: (!!)TROUBLE in pre_loop_hook: config: no rules were found!  Do you need to run 'sa-update'?
Mar 15 18:02:26 mail amavis[1560]: (!)_DIE: Suicide () TROUBLE in pre_loop_hook: config: no rules were found!  Do you need to run 'sa-update'?

it works now! thanks

mail# sa-update
mail# /usr/local/etc/rc.d/amavisd status
amavisd is not running.
mail# /usr/local/etc/rc.d/amavisd start
Starting amavisd.
^[[Amail# /usr/local/etc/rc.d/amavisd status
amavisd is running as pid 1595.

6

Re: Relay access denied

These two bugs were already fixed several days ago smile

7

Re: Relay access denied

sorry sad this is the last time i ask before i search :d
Thanks

8

Re: Relay access denied

i have the same problem, Relay access denied

9

Re: Relay access denied

here my postconf -n

smtpd_helo_restrictions = permit_mynetworks permit_sasl_authenticated check_helo_access pcre:/etc/postfix/helo_access.pcre reject_non_fqdn_helo_hostname
smtpd_recipient_restrictions = reject_non_fqdn_recipient reject_unlisted_recipient check_policy_service inet:127.0.0.1:7777 permit_mynetworks permit_sasl_authenticated reject_unauth_destination check_policy_service inet:127.0.0.1:12340
smtpd_reject_unlisted_recipient = yes
smtpd_reject_unlisted_sender = yes
smtpd_sasl_path = private/dovecot-auth
smtpd_sasl_type = dovecot
smtpd_sender_login_maps = proxy:mysql:/etc/postfix/mysql/sender_login_maps.cf
smtpd_sender_restrictions = reject_non_fqdn_sender reject_unlisted_sender permit_mynetworks permit_sasl_authenticated check_sender_access pcre:/etc/postfix/sender_access.pcre reject_unknown_sender_domain
smtpd_tls_CAfile = /etc/pki/tls/certs/iRedMail.crt
smtpd_tls_CApath = /etc/pki/tls/certs
smtpd_tls_cert_file = /etc/pki/tls/certs/iRedMail.crt

10

Re: Relay access denied

You replied to a 10 year old thread. Please create a new forum topic with your issue clearly explained, and paste related error message/log.