Zope ZEO and MailHost - email

I have a webpage running with a ZEO server and 2 Zope Servers, one of which is on a different machine from the ZEO server. Both machines have sendmail installed (I can send mails from the shell).
Now in the Zope MailHost object the SMTP Host is set to localhost. Sending mail is only working when the website is accessed on the same server as the ZEO server, otherwise there is an error:
SMTPRecipientsRefused'{'my#email.com':'554, 5.7.1 'my#email.com': Relay access denied')}
Is there a way to use localhost as SMTP for a MailHost object in Zope with ZEO? I would have guessed that the Zope MailHost uses sendmail from the same server as the Zope instance, but my guess was obviously wrong.
My workaround is currently to use the MailHost object with an external SMTP server.

Related

Local email to root should not leave the host

I am trying to set up the most simple email server on an Amazon Linux 2 host for simple outbound mail (e.g. sending system messages). Following instructions on the net, I have installed mailx and sendmail. I am not committed to either package, I just want a simple setup with a minimal footprint. I have no problem switching to postfix if that is a better solution.
For configuration I have made the following changes.
/etc/sysconfig/sendmail:
DAEMON=no
/etc/mail/submit.cf (hostname obfuscated):
D{MTAHost}smtp.******.com
This works fine, and I am able to receive mail that is sent from the system.
There is a wrinkle. The anacron process is sending mail to the root account. However, rather than the mail being kept internal to the system it is being sent to the SMTP server. The SMTP server sends the message back to my host, which doesn't accept mail, and a loop is created when an 'undeliverable' message is send back to root on the host that doesn't accept mail.
How can I configure my system so email to root stays local and is not sent to the SMTP server? Any other 'best practices' suggestions would be welcome as well. And again, if switching to postfix is better, I am willing to do so (but will need configuration guidance).

Query reg SMTP port

Hi am having a confusion reg SMTP ports. I have configured an application in my local machine to use gmail's smtp server by getting the details from here - https://www.siteground.com/kb/google_free_smtp_server/ and am able to trigger emails without any issues.
When I set the same application in a windows server and use the same smtp settings the emails aren't going and I keep getting errors like "unable to connect to smtp port 465". So is the port being mentioned here - 465 - is this port being used from my machine to connect to gmail's smtp server or is this port being referred to the port in the machine where gmail's smtp server is hosted?

Telnet works but email doesn't

I'm setting up an Alfresco AWS instance and trying to configure inbound email.
As per the documentation I've configured it, hosted the Alfresco mail server on port 1025, set up an iptable rule to forward port 25 --> 1025, set up an folder in Alfresco with the alias 'dropoff' and added my work email as an allowed user for sending emails. I've also ensured all the ports are open on the EC2 instance
So far so good. If I test everything from my local computer with telnet:
helo mywork.com
mail from:myname#mywork.com
rcpt to:dropoff#alfresco.mywork.com
data
From: adinihan#mywork.com
Subject: test mail from command line
this is test number 1
sent from linux box
.
Then it works. I look in the Alfresco folder and there's the test email document. However, if I use Gmail and sign into myname#mywork.com and send an email through Gmail, then it doesn't work. It sends alright and there's nothing in Alfresco logging, however the document just never appears in the Alfresco folder. The from/to address is the same as the telnet command's one.
Since I can telnet from my local computer to the instance I assume it's not an issue with ports on the EC2 instance. Why would telnet work but sending it via Gmail not?
EDIT: got an email back from Google about an hour after I sent it with the error message TLS Negotiation failed: generic::failed_precondition: starttls error (0): protocol error
EDIT 2: here are my inbound emai settings in the global properties file
# Inbound #
email.inbound.unknownUser=anonymous
email.inbound.enabled=true
email.server.enabled=true
email.server.hideTLS=false
email.server.enableTLS=true
email.server.requireTLS=false
email.server.port=1025
email.server.domain=alfresco.amritmro.com
imap.server.enabled=true
imap.server.port=1143
imap.server.host=0.0.0.0

Mail sending but not receiving on Plesk server

I am having some PLESK Mail receiving issues.
I just setup a dedicated server with 1and1. The server console is PLESK 12. I am using 1and1 nameserver which are pointed correctly from the domain registrars. I am able to send mail using webmail but not able to receive it.
When I do a mail server check it I get the following error:
Error connecting to mailserver: No route to host
If anyone is aware of some missing SMTP settings that need to be set up in the initial Plesk configuration it would be appreciated.

MATLAB sendmail configuration for a SMTP server

We were using an internal SMTP server and Matlab's sendmail function worked well. However, our SMTP server has changed and instead of smtp.companyname.com, we now have an ip address, say 10.23.154.2.
The new server doesn't require authentication and also no SSL connection. Still, we are not able to send emails
Version - R2013a,
setpref('Internet','E_mail','XYZ')
Old Config: setpref('Internet','SMTP_Server','smtp.xxx.com'),
New Config: setpref('Internet','SMTP_Server','10.23.154.2'),
As per IT team, telnet worked on the server and SMTP worked fine with IronPorts. Please comment.