Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
Go Back > Forums > Linux Forums > Linux - Server
User Name
Linux - Server This forum is for the discussion of Linux Software used in a server related context.


  Search this Thread
Old 10-29-2009, 12:38 PM   #1
LQ Newbie
Registered: Jul 2009
Posts: 15

Rep: Reputation: 0
Postfix SMTP Authentication

I'm hoping someone can help me with Postfix/Dovecot SMTP authentication.

When trying to send a test message with a mail client over the internet I get the following error:

The message could not be sent because one of the recipients was rejected by the server. The rejected e-mail address was'. Subject 'test', Account: '', Server: '', Protocol: SMTP, Server Response: '554 5.7.1 <>: Relay access denied', Port: 25, Secure(SSL): No, Server Error: 554, Error Number: 0x800CCC79
The g-mail account is the address I'm sending to. The account i'm sending from has an account on the server and I can successfully download messages using this client. I can also log in to squirrelmail using this account. So I know that dovecot is authenticating it.

Ideally I would like anyone that can authenticate from domain to be able to send mail through my server.

Below are what I think are the relevant portions of my and dovecot.conf file.
virtual_mailbox_domains = /etc/postfix/virtual_config/virtual_domains
virtual_mailbox_maps = hash:/etc/postfix/virtual_config/virtual_mailboxes
virtual_mailbox_base = /var/spool/virtual_mail
virtual_minimum_uid = 100
virtual_uid_maps = static:501
virtual_gid_maps = static:501
virtual_alias_maps = hash:/etc/postfix/virtual_config/virtual_aliases

smtpd_sasl_auth_enable = yes
smtpd_sasl_type = dovecot
smtpd_sasl_path = private/auth
broken_sasl_auth_clients = yes
#smtpd_recipient_restrictions = permit_mynetworks,permit_sasl_authenticated,reject_unauth_destination
smtpd_sender_restrictions = permit_sasl_authenticated, permit_mynetworks

auth default {
  # Space separated list of wanted authentication mechanisms:
  #   plain login digest-md5 cram-md5 ntlm rpa apop anonymous gssapi otp skey
  #   gss-spnego
  # NOTE: See also disable_plaintext_auth setting.
  mechanisms = plain login cram-md5

 passdb passwd-file {
    # File contains a list of usernames, one per line
    args = /etc/postfix/virtual_config/virtual_passwords
    #args = /etc/dovecot.deny
    #deny = yes

  userdb passwd {
  userdb static {
        args = uid=501 gid=501 home=/var/spool/virtual_mail/%d/%n

socket listen {
    #master {
      # Master socket provides access to userdb information. It's typically
      # used to give Dovecot's local delivery agent access to userdb so it
      # can find mailbox locations.
      #path = /var/run/dovecot/auth-master
      #mode = 0600
      # Default user/group is the one who started dovecot-auth (root)
      #user =
      #group =
    client {
      # The client socket is generally safe to export to everyone. Typical use
      # is to export it to your SMTP server so it can do SMTP AUTH lookups
      # using it.
      #path = /var/run/dovecot/auth-client
      path = /var/spool/postfix/private/auth
      mode = 0660
      user = postfix
      group = postfix
Any help is much appreciated. This server hosts e-mail for multiple domains and it's done with virtual users.
Old 10-30-2009, 01:23 PM   #2
Registered: Sep 2003
Location: GMT -08:00
Distribution: Ubuntu, RHEL/CentOS, Fedora
Posts: 234

Rep: Reputation: 42
In my, I have these lines:

smtpd_recipient_restrictions =
I'd have to re-read the differences beween smtpd_sender vs smtpd_recipient restrictions again so all I can say is "works for me" ... I don't have any smtpd_sender_restrictions in my config these days. Everything is under recipient_restrictions.

- Arch


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
SMTP authentication in postfix aravind1024004 Linux - Server 12 09-04-2010 10:32 AM
postfix smtp authentication hariiyer Linux - Server 4 09-14-2009 03:30 AM
postfix smtp authentication problem ssilayaraja Linux - Server 0 08-07-2009 07:39 AM
Postfix SMTP Authentication lasantha Linux - Server 0 10-26-2007 02:06 PM
Postfix smtp authentication help dt23 Mandriva 1 09-28-2004 09:32 PM > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 03:18 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration