I want to setup a home mail server to receive incoming mails, but my ISP blocked port 25, so other mail clients (e.g., gmail) can't connect to my home mail server, right? I mean, I can
telnet from remote site to my home server via other ports, ssh/ftp/www etc, but not port 25 (timeout). This means my ISP is blocking port 25, right?
If so, is there any way for my
sendmail home mail server still be able to receive incoming mails? My own searches found many articles talking about this but the final solution offered is a paid commercial service. I'm wondering if it is the only option.
Historically, in Internet mail, both MTA and MSA functions use port number 25, but the official port for MSAs is 587. The MTA accepts locally-destined mail from other domains, and an MSA accepts submitted mail from local users.
And according to my sendmail.mc:
$ grep Port= sendmail.mc DAEMON_OPTIONS(`Family=inet, Name=MTA-v4, Port=smtp')dnl DAEMON_OPTIONS(`Family=inet, Name=MSP-v4, Port=submission, M=Ea, Addr=127.0.0.1')dnl
The submission port is for MSA, which is for accepting submitted mail from local users. It is the smtp port, that used by the MTA to accept locally-destined mail from other domains, that really counts when accepting incoming emails, right? How can it be done?
Update, Thank to @davidgo's reply, which concurs what I've also read that there is no workaround for this, but let me throw in some counter-arguments.
Before using smart-host, I'm getting "Connection timed out" errors from some of the email servers, like google:
$ tail -1 /var/log/mail.log Jun 15 15:55:52 coral sm-mta: s5FAo29p007675: to=<firstname.lastname@example.org>, delay=09:05:50, xdelay=00:10:36, mailer=esmtp, pri=2550569, relay=alt4.gmail-smtp-in.l.google.com. [188.8.131.52], dsn=4.0.0, stat=Deferred: Connection timed out with alt4.gmail-smtp-in.l.google.com.
So I tried using telnet to port 25 to see if we're able to connect to the destination host...
$ telnet alt4.gmail-smtp-in.l.google.com 25 Trying 184.108.40.206... Trying 2a00:1450:4013:c01::1a... telnet: Unable to connect to remote host: Network is unreachable
Hmmm, I was going to say that gmail's port 25 is blocked as well, but I now think it is the IPS not gmail that is blocking port 25. So, no workaround huh? Ok...
Suppose it is the one, but still there are two sides for enabling port 587, one for outgoing and one for incoming, I should enable the incoming part right? Would that make my home mail server an open relay then? Do I have to do anything else? E.g., here it says, "For instance when I configure sendmail to listen to port 587 it will typically only accept incoming e-mail over that port when the user has authenticated", without any further elaboration. Is this the all the steps needed?