Consider "Reversing" Email Verification Flow #14048
Labels
needs discussion
a product management/policy issue maintainers and users should discuss
security
Security-related issues and pull requests
usability
Currently we implement a pretty typical email verification flow:
This flow works, it's well known, and it's secure.
Unfortunately it has one major problem-- it requires sending emails to addresses that you've never verified that you are allowed to send emails too. This becomes a problem because people can enter in emails that they don't own, causing us to email that person, which then often times get marked as spam when the person who really owns it receives it.
Traditionally the way that you prevented this from happening is by trying to raise the bar for automated uses of your verification form, typically by putting some sort of captcha in place, which brings it's own problems (captchas aren't full proof, often have accessibility concerns, are not always available in every country, etc).
This has been a problem for us, we don't have a particularly high volume of email that we send, so the email verification emails take up a dis-proportionally large amount of our outgoing email. When they get marked as spam that ends up hurting our reputation, and it has even gotten to the point in the past where AWS has disallowed our ability to send new emails because our spam rate was too high.
#13234 attempts to minimize the impact of these spam reports by just sending more email so that our email verification emails are a smaller % of our overall emails, so the couple that get marked as spam don't hurt as much. I think that issue is overall a good idea, as long as the new emails we're sending are emails that provide value (which I think most or all of the suggestions are). However it doesn't really solve the underlying problem of sending emails to unverified addresses, it just tries to reduce the impact of the spam reports we do get.
@woodruffw had previously blogged about a an idea he had about reversing the email verification flow, that could solve this problem.
The whole post is good, but a rough idea of the flow would be:
mailto
link (probably with some temporary email inbox).This is an interesting idea, though it's not without it's own shortcomings:
mailto:
links for instance.The last one is probably the biggest problem. By default email has basically no way to determine or prevent anyone from sending an email from any email address, so a malicious user who doesn't control
@example.com
could craft an email that claims to be from[email protected]
and the email protocol itself has no real mechanism to validate it.This is obviously terrible, so there have been things bolted onto the side of email to try and fix it (as Will mentions in his post): namely SPF and DKIM.
Using SPF and DKIM, it is possible to determine that the sender is sending from a mail server that is authorized to send for some particular domain. Unfortunately at best I can tell, in the general population something like 30% of email domains have SPF/DKIM setup properly and like 60-70% do not. This means, to keep security, that we would have to hard fail in those cases, but the user can't actually do anything about the problem unless they happen to operate their own mail server. Fortunately the big mail providers are all within the 30% of domains that do it correctly, so likely the vast bulk of addresses would be fine, but likely not all of them.
I suspect that this problem kills this idea dead in the water (particularly when you add the other problems), but I wanted to open the issue just to give a space to consider it and see if I'm wrong, and at the very least to document that we thought about it and decided not to do it.
The text was updated successfully, but these errors were encountered: