Email routing to GMail leaves mailserver open

Discussion in 'ISPConfig 3 Priority Support' started by iqpascal, Aug 3, 2018.

  1. iqpascal

    iqpascal Member

    I've set email routing for GMail, Outlook and others to relay them through a secondary server for better mail delivery results however this left my server open for relaying mail for others to GMail and outlook. Ouch...
    Can I change this behaviour by removing the mysql:/etc/postfix/ from relay_domains in Or will this break things?
    I will not have "own" domains that I need to relay for to another server so I will just use this feature to relay mail to GMail and others
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    If you do not want to have any relay domains, then don't add relay domains under mail > relay recipients in ISPConfig. There is no need to remove that line from the config.
  3. iqpascal

    iqpascal Member

    Thank you.

    Grmbl, if I configure it that way nobody is allowed to send mail to GMail except localhost. So no allowed hosts in mynetworks or SMTP users. They all get "Recipient address rejected: User unknown in relay recipient table (in reply to RCPT TO command)"

    I just want SMTP users or other allowed hosts to send mail to all domains just route some domains to an external party for better delivery results.
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    On an ISPConfig server, the following users are allowed to relay emails:

    1) IP addresses that are configured under mynetworks in postfix
    2) Users that have authenticated themself with username and password before sending email.

    This kind of setup is the normal way mail servers are configured on the internet, if you would allow non authenticated users to relay trough your server or IP addresses that do not belong to your own systems, then your mail servers woiuld be an 'open relay' and it would be used for spam sending.

    The relay domain feature you referred above is used in setups where you use the ISPConfig server as a spam filter system in front of an internal system like an exchange server.

    This can be done with e.g recipient canonical maps, but I haven't used that postfix feature yet, so I can't tell you any details.
  5. iqpascal

    iqpascal Member

    So it's not possible to use EMail routing as can be configured through ISPConfig but without the fact everybody can route mail to that domain through my server?

    As the solution does work very nice (and as wanted) if only not everybody could use my mail server as a relay for those domains. It should only work for allowed hosts or authenticated SMTP users.

Share This Page