Open jraffa opened 4 years ago
This is definitely an issue to look into. Many of the emails are also going to my spam folder.
A few thoughts on improving our emails:
Are our PTR records set up correctly? A reverse DNS lookup on our IP returns physionet.mit.edu
. This is not the domain used in our sender address. Is that a problem?
dig -x 18.13.52.205
;; ANSWER SECTION:
205.52.13.18.in-addr.arpa. 1800 IN PTR physionet.mit.edu.
I assume that DKIM has not been set up, but it seems like a good idea. The process involves (1) creating public/private keypairs (2) adding a couple of TXT records to our DNS, one which references the public key (3) signing the emails with the key.
This seems the most straightforward of the three steps (and the least beneficial). It involves adding our sender IP/s to another TXT record in the DNS.
@Lucas-Mc @bemoody this seems to be a fairly major issue, because from a couple of recent messages it seems that some networks are completely blocking our emails (they don't even arrive in spam folders). Has anyone had a chance to look into it? If not, I'll take a look into the steps above today.
I set up DKIM last week. Look at recent messages, you should be able to verify them (e.g. using opendkim-testmsg.) SPF was done ages ago.
I wouldn't assume something's wrong with the mail server just because people complain. The system is fragile in a lot of ways that are not related to email per se. Have you verified that the messages were actually sent in the last few days and that they were accepted (or rejected) by the destination server?
Thanks for setting up the DKIM, and glad to hear that SPF is already in existence! Do you have any thoughts on the first point, around PTR records (i.e. does it matter that the reverse DNS lookup returns physionet.mit.edu when our sender address is physionet.org?).
I wouldn't assume something's wrong with the mail server just because people complain. The system is fragile in a lot of ways that are not related to email per se. Have you verified that the messages were actually sent in the last few days and that they were accepted (or rejected) by the destination server?
All I know is that there are reports from ~3 or 4 users saying that (1) registering with an institution email address was not possible because the email wasn't received (2) switching to a different address immediately solved the problem.
I haven't investigated why this is happening (e.g. it is possible that the emails were just not sent at all), but it seems likely that something may be preventing delivery. I'm happy to explore, but if so it would be helpful to chat to understand more about what I should be looking out for (unfortunately I'm not able to get onto jabber at the moment, but I'll try to fix that!).
On 8/19/20, Tom Pollard notifications@github.com wrote:
Thanks for setting up the DKIM, and glad to hear that SPF is already in existence! Do you have any thoughts on the first point, around PTR records (i.e. does it matter that the reverse DNS lookup returns physionet.mit.edu when our sender address is physionet.org?).
Certainly the conventional wisdom was always that it didn't matter. It's not at all uncommon to have many domains' outgoing mail routed through a single IP address, and obviously one address can't be mapped to multiple hostnames at once. Even big senders don't follow that rule: if you send mail "from" gmail.com, the machine that actually sends it is something-or-other.google.com.
The only sensible way to check if an IP address is allowed to send mail for a particular domain would be... SPF, or something very much like it. But nothing about email is sensible nowadays, so who knows?
BTW, you're looking at the wrong IP address. Outgoing mail comes from 128.30.29.50, not 18.13.52.205. It doesn't matter what 18.13.52.205 maps to.
All I know is that there are reports from ~3 or 4 users saying that (1) registering with an institution email address was not possible because the email wasn't received (2) switching to a different address immediately solved the problem.
A good place to start would be to make a list of domains that are failing. Of course, check whether the messages are being accepted or rejected. See if there are any patterns, and try to find out if there's anyone on the other side who's both willing and able to debug the problem (a tall order, I'm sure!)
BTW, you're looking at the wrong IP address. Outgoing mail comes from 128.30.29.50, not 18.13.52.205. It doesn't matter what 18.13.52.205 maps to.
Got it, so it looks like heimdallr.csail.mit.edu which is even further away!
A good place to start would be to make a list of domains that are failing. Of course, check whether the messages are being accepted or rejected. See if there are any patterns, and try to find out if there's anyone on the other side who's both willing and able to debug the problem (a tall order, I'm sure!)
Good suggestion, I will collate a list of domains and then we can work out next steps.
After looking into this (and thanks to a related bug for one of our users), I think I understand what is happening (and @bemoody, you were correct to question my assumption that the problem was emails being filtered!).
In all cases where emails were reported not to have been received, the user was attempting to register. After registration, later emails were fine. What these users had in common was that they did not have an associated email in the system.
The reasons for this can be discussed in a separate issue, but either (1) the associated email object was not created or (2) the associated email object was deleted in a cron task.
The fix for this is to follow the steps in the AssociatedEmail.create_associated_email
method to create a new AssociatedEmail for the user.
It sounds like we are doing what we can to ensure emails are delivered to our users, so I think this issue can be closed.
Received a non-critical e-mail about a physionet project that ended up in my spam folder. Looks like it might be a known issue, but thought I'd fwd headers. Only noticed because I was waiting for a different e-mail today, and gave that folder a look.
Maybe DKIM would help?