Closed hostbox2 closed 5 years ago
Version: Latest commit 2b0e257 on Oct 31, 2018
Does this happen consistently, regardless of which machine you try to query their servers from?
Because, this is a caught exception in a pretty specific case: https://github.com/zytzagoo/smtp-validate-email/blob/master/src/Validator.php#L843
The fatal error can maybe be avoided, since the actual cause in case of this specific server is that the server does not allow NOOP commands, and actually kills the connection when a second NOOP is attempted after the first one: (this is my debug log, slightly different from yours, who knows why...)
...
[2019-05-21T08:27:07.584384+0000] <<<recv: 250 OK
[2019-05-21T08:27:07.585328+0000] send>>>: MAIL FROM:<myemail@domain.com>
[2019-05-21T08:27:07.651797+0000] <<<recv: 250 2.1.0 myemail@domain.com....Sender OK
[2019-05-21T08:27:07.652530+0000] send>>>: NOOP
[2019-05-21T08:27:07.718555+0000] <<<recv: 500 Command not allowed
[2019-05-21T08:27:07.719367+0000] send>>>: NOOPPHP Notice: fwrite(): send of 6 bytes failed with errno=10054 An existing connection was forcibly closed by the remote host.
So perhaps the NOOPs could be made optional, if it doesn't break any existing use cases... Not sure when I'll get around to have a chance at fully investigating this...
If you care to fix it on your end, you can try just removing the $this->noop();
calls (or better yet just insert an early return into the noop()
method), and see if that helps you get rid of the fatal...
There's an option now in latest master that allows one to disable sending NOOP commands (along with tests for it confirming it works).
https://github.com/zytzagoo/smtp-validate-email/blob/master/src/Validator.php#L1191 https://github.com/zytzagoo/smtp-validate-email/blob/master/tests/Functional/ValidatorTest.php#L161
When/if that becomes a part of some official tag/release... no idea.
Fatal error: Uncaught SMTPValidateEmail\Exceptions\NoMailFrom: Need MAIL FROM before RCPT TO
Other check the mailing address handles correctly without error. Only this email gives an error.
Here is the debug output: