(Im sorry for double posting,im still confused of how this mailing list works) Halo Matt,
First of all, I want to thank you for the solution provided and for the explanation. I try to follow your instruction by adding said <smtpserver> tag and change the <bind>, and <tlsSocket> to true (I copy paste the info from my port 25 SMTP and didn’t include the jmxname because it can be ignored): <smtpserver enabled="true"> <bind>0.0.0.0:465</bind> <tls socketTLS="true" startTLS="false"> <keystore>file://conf/keystore</keystore> <secret>pass</secret> <provider>org.bouncycastle.jce.provider.BouncyCastleProvider</provider> <algorithm>SunX509</algorithm> </tls> <connectiontimeout>360</connectiontimeout> <!-- Set the maximum simultaneous incoming connections for this service --> <connectionLimit>0</connectionLimit> <!-- Set the maximum simultaneous incoming connections per IP for this service --> <connectionLimitPerIP>0</connectionLimitPerIP> <authRequired>true</authRequired> <authorizedAddresses>127.0.0.0/8</authorizedAddresses> <maxmessagesize>0</maxmessagesize> <addressBracketsEnforcement>true</addressBracketsEnforcement> <handlerchain> <handler class="org.apache.james.smtpserver.fastfail.ValidRcptHandler"/> <handler class="org.apache.james.smtpserver.CoreCmdHandlerLoader"/> </handlerchain> </smtpserver> And I try to get my mail server from thunderbird (also changed the setting to port 465 SSL/TLS), but the connection got refused and I cant even send email. I try putting the SMTP port 465 code under the SMTP port 25, so maybe the SMTP port 25 get loaded first before the 465, but still no luck. Is there something im doing wrong or I miss or I need to look out? Sincerely, Jason Sorry for any wrong word, and thank you for the help Sent from Mail for Windows 10 From: cryptearth Sent: Thursday, June 27, 2019 11:03 AM To: server-user@james.apache.org Subject: Re: How to configure SMTP so thunderbird can send email / receiveemail from outside world? Hello Jason, if I remeber correctly from an older topic, it's possible to use more than one port per service. In <james>/conf/smtpserver.xml you normal have this layout: <smtpservers> <smtpserver> <bind>0.0.0.0:25</bind> </smtpserver> </smtpservers> This is the required one on TCP/25 for receiving e-mails from the outside world. Why? SMTP uses TCP/25 for inter-server communication: each MTA that want to talk to another MTA has to do this on TCP/25 - if TCP/25 isn't open or there is no SMTP server on this port mails can't be delievered. If you want additional ports for TCP/465 (socketTLS) or TCP/587 (startTLS) you just have to add another <smtpserver>-block. You can just copy the existing block. But you have to change the jmxName, or delete it, as there can't multiple jmx entries with the same name. So you can do this: <smtpservers> <smtpserver> <bind>0.0.0.0:25</bind> <tls socketTLS="false" startTLS="true"> <!-- stuff --> </tls> </smtpserver> <smtpserver> <bind>0.0.0.0:465</bind> <tls socketTLS="true" startTLS="false"> <!-- stuff --> </tls> </smtpserver> <smtpserver> <bind>0.0.0.0:587</bind> <tls socketTLS="false" startTLS="true"> <!-- stuff --> </tls> </smtpserver> </smtpservers> This way you open your james on ports 25, 465 and 587. The startTLS on 25 is so other MTA can drop mails over encrypted channel, but you can set it to false. Make sure to set authRequired to announce to enforce SMTP AUTH or set authroizedAddress correctly (also check mailetcontainer.xml !). About TCP/25 is marked as spam - I guess you're either in a larger network or use an ISP with strict policies, as it shouldn't be blocked allthough it's a good anti-spam mechanic. Try contact the admin/support about policies about TCP/25. Matt Am 27.06.2019 um 05:09 schrieb Jason Tjankilisan: > Halo, > After doing some research about my problem, I found this > https://www.mail-archive.com/server-user@james.apache.org/msg15590.html and > from what im understanding that if my SMTP use port other than 25, I cannot > get any email from outside world? (Gmail, Yahoo I pressume) > > I might be wrong since im new but, to send email to outside world, I need > port 465 with SSL/TLS Socket on so it wont be recognized as spam. In > addition, it seems using port 25 as SMTP port to send email using thunderbird > always create a connection time out error. > > For the IMAP server, I can use port 993 with socketTLS and port 143 with no > problem to get new email, as long as the SMTP port stay on 25. (Additional > Info : keystore was created using Letsencrypt) > > (When I change SMTP port to 465, I got this error from gmail) > The recipient server did not accept our requests to connect. Learn more at > https://support.google.com/mail/answer/7720 [jason.107.jp. 5.189.160.138: > generic::failed_precondition: connect error (111): Connection refused] > So is there any way for my SMTP to use port 465 and still get email from > outside my server? > Sincerely, Jason > Sorry for any wrong word, and thank you for the help > > Sent from Mail for Windows 10 > --------------------------------------------------------------------- To unsubscribe, e-mail: server-user-unsubscr...@james.apache.org For additional commands, e-mail: server-user-h...@james.apache.org