Breaking RFC 2821

Someone call the internet police, SmashTech has broken RFC 2821, the RFC for SMTP. If you send an email to a non-valid address on the server, the system will accept and delete it, all without ever sending a 550 Undeliverable error message back.

As RFC 2821 says, “If an SMTP server has accepted the task of relaying the mail and later finds that the destination is incorrect or that the mail cannot be delivered for some other reason, then it MUST construct an “undeliverable mail” notification message and send it to the originator of the undeliverable mail (as indicated by the reverse-path).”, a bounce message is required.

But with all the spam these days, sending a bounce message for every single invalid email is just not practical. So far today, there have been almost 500 messages to invalid SmashTech addresses. Under RFC 2821, I am required to send a Undeliverable message back to the source. But guess what? Every single one of those bad email addresses is from spam with forged headers. If I attempt to send a bounce message back, chances are pretty good that I will get another bounce message because SmashTech would try to send to the fake address in the header. This means another mail process running, trying to send this, retrying until it gives up.

Finding out how to break RFC 2821 took a while, because every time someone brings up the topic of disabling bounce messages, they are quickly flamed into oblivion with violating the RFC and ignoring adopted standards, but Im going to tell you how to do it easily.

Add a catch all address to your virtusertable file like so (replace deleteme with a valid user on your system):

@domain.com deleteme

Then setup a cron job to delete that users email file at /var/spool/mail/deleteme, probably on an hourly basis. Make sure you do this step, or their mail file will fill up all space on the system.