0

I just installed mutt and postfix on my server and I've been playing around with it. Now, however, I want to make sure that no one can remotely send mail with my server as a SMTP relay.

I don't know that much about Mail servers, so for the sake of being overly clear, I want to be able to receive messages to local user accounts, send messages from local accounts to outside addresses, but not remotely send messages through the server.

Currently it receives and send's messages just how I want it, but I haven't been able to find a clear way of only disabling remote relaying.

Does anyone have any suggestions? It's a default installation of mutt and postfix, I can post any details you request. Thank you, all!

Logan
  • 125
  • 2
  • 10

2 Answers2

2

Postfix is secured that way by default. You have to explicitly misconfigure it to be an so called open relay.

For different requirements there is a documentation about several common scenarios: http://www.postfix.org/STANDARD_CONFIGURATION_README.html

mailq
  • 16,882
  • 2
  • 36
  • 66
0

Check the parameter relay_domains in postfix.

In addition to the mynetworks, postfix by default accepts mail that Postfix is final destination for:

  • destinations that match $inet_interfaces or $proxy_interfaces,
  • destinations that match $mydestination
  • destinations that match $virtual_alias_domains,
  • destinations that match $virtual_mailbox_domains.

These destinations do not need to be listed in $relay_domains so make sure to change them appropriately.

So as a hint make sure that mynetworks = 127.0.0.1. In that way no one, except for the local users will be able to use your smtp as a relay.

golja
  • 1,611
  • 10
  • 14
  • is relay_domains in main.cf? Where are all of those variables set? It looks like exactly what I need, but I can't test it until I get home. – Logan Aug 06 '12 at 13:36
  • yeah everything is in the main.cf. To check all the config parameters just run `postconf` – golja Aug 08 '12 at 01:30