ListManager forwards to Sendmail
Note that this documentation is current for Sendmail versions up to 8.12.9. For further inquiries about Sendmail beyond the scope of this documentation, please see http://www.sendmail.org/.
Move Sendmail to an alternate port and inform ListManager to forward non-ListManager bound mail to Sendmail.
The advantage of this approach is that it is very easy to implement. The disadvantage is that it establishes a dependency of Sendmail on ListManager, so it is less reliable.
Please Note: We do not recommend that you use ListManager as a general purpose mail relay host for relaying outbound mail to the Internet. ListManager is not optimized for this use and its ability to act as a "virtual server" can make successful relaying complicated. If you need a relay host on your machine, we recommend that you run Sendmail and ListManager on separate TCP/IP addresses, or configure Sendmail to forward to ListManager, leaving Sendmail on port 25.
To move Sendmail to another port, such as port 26, do the following. Note that you will have to either perform Step 1 (if you are running earlier versions of Sendmail), or Step 2, for later versions:
Step 1:
In earlier versions of Sendmail, you may only need to add the following line to your /etc/mail/sendmail.cf file:
OOPort=26
This option is explained in the "Options" chapter of the O'Reilly Sendmail book.
Step 2:
Open sendmail.cf, and find the following line(s):
O DaemonPortOptions=Name=MTA
O DaemonPortOptions=Port=587, Name=MSA, M=E
Change the first line to:
O DaemonPortOptions=Port=26, Name=MTA
O DaemonPortOptions=Port=587, Name=MSA, M=E
You can then install ListManager. Once you have installed it you need to tell it to forward non-ListManager mail to Sendmail. You can do this from the web interface Utilities: Administration: Server: Server Settings: Network Settings: Receive Email page, or with the "forward" command line parameter. For example:
lm forward 127.0.0.1 26
ListManager will validate your forward rule and reply with "Checking forwarding rule: 127.0.0.1 26" and then "Successfully updated forwarding rule". This example forwarding command tells it to forward non-ListManager mail to port 26 on the local machine ("localhost"). If no SMTP server is running on that TCP/IP / port combination, ListManager will not save your forwarding rule.
Configuring Sendmail So It Does Not Relay
ListManager by itself cannot be an open relay. However, if it forwards non-ListManager mail to Sendmail, Sendmail can itself become an open relay.
In order to prevent Sendmail from becoming an open relay, you must comment out the following entries in your access file (usually in /etc/mail):
localhost.localdomain RELAY
localhost RELAY
127.0.0.1 RELAY