whiteout-io/smtpclient — pull request #20 by asutherland (2014-11-08 21:15:06+00:00)
Title: Do not allow HELO to bypass requireTLS enforcement

If the server generated an error when EHLO was issued, HELO would be tried,
bypassing the logic at the bottom of the EHLO handler that tries to initiate
STARTTLS. This would enable an attacker to bypass the protections of
requireTLS.

This fix assumes that if EHLO fails then STARTTLS is inherently not a
possibility and immediately generates an error.