Support ⇒ Dragonfly CMS v10 ⇒ Issue creating a new user ⇒ Community Forums ⇒ CPG Dragonfly™ CMS
Forum IndexDragonfly CMS v10

Issue creating a new user Reply to topic


A friend of mine is trying to create an account on my site, but when we try using his email address we get this message:

The request could not be completed due to a conflict with the current state of the resource. nathan @ xxxxxx.net.au: SMTP Error 220: c4s1-2e-syd.xxxxxx.net.au ESMTP Exim 4.93 #2 Thu, 19 Mar 2020 15:08:19 +1100 We do not authorize the use of this system to transport unsolicited, and/or bulk e-mail. Command: QUIT

While we're typing the email address in, we see this:



It seems that the website is somehow interpreting the 220 banner messages as errors. I can send an email manually from the server:

telnet xxxxxx.net.au 25 Trying 110.232.xxx.xxx... Connected to xxxxxx.net.au. Escape character is '^]'. HELO mustangtech.com.au 220-c4s1-2e-syd.xxxxxx.net.au ESMTP Exim 4.93 #2 Thu, 19 Mar 2020 15:10:34 +1100 220-We do not authorize the use of this system to transport unsolicited, 220 and/or bulk e-mail. 250 c4s1-2e-syd.xxxxxx.net.au Hello www.mustangtech.com.au [162.221.205.248] MAIL FROM: xxxxxadminxxxx @ mustangtech.com.au 250 OK RCPT TO: nathan @ xxxxxx.net.au 250 Accepted DATA 354 Enter message, ending with "." on a line by itself Hello Nathan, this is a test email. . 250 OK id=1jEmWv-00EdLW-1V QUIT 221 c4s1-2e-syd.xxxxxx.net.au closing connection

Can this be disabled somehow?

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):

Last edited by hybrid on Thu Mar 19, 2020 5:45 am; edited 4 times in total


I've fixed this by adding 220 to the $args array in includes/dragonfly/security/validateemail.php

protected function sendCommand($cmd, $error_msg=null, $ok=250) { $this->debug[] = "=> {$cmd}"; # See mail/l10n/en.php for all error codes fwrite($this->socket, "{$cmd}\r\n"); list($code, $msg) = $this->getResponse(); $args = func_get_args(); $args[] = $ok; $args[] = 220; if (!in_array($code, $args)) { $this->errno = $code; $this->error = $msg; $fark = print_r($args); throw new \Exception("SMTP Error {$code}: {$msg}\n\nCommand: {$cmd}"); } return $msg; }

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):


It seems the Exim server is incorrect.
RFC5321 section 4.2.1 wrote
The reply text may be longer than a single line; in these cases the
complete text must be marked so the SMTP client knows when it can
stop reading the reply. This requires a special format to indicate a
multiple line reply.

The format for multiline replies requires that every line, except the
last, begin with the reply code, followed immediately by a hyphen,
"-" (also known as minus), followed by text. The last line will
begin with the reply code, followed immediately by <SP>,
optionally
some text, and <CRLF>. As noted above, servers SHOULD send the <SP>
if subsequent text is not sent, but clients MUST be prepared for it
to be omitted.

For example:

250-First line
250-Second line
250-234 Text beginning with numbers
250 The last line

In a multiline reply, the reply code on each of the lines MUST be the
same.
It is reasonable for the client to rely on this, so it can
make processing decisions based on the code in any line, assuming
that all others will be the same. In a few cases, there is important
data for the client in the reply "text". The client will be able to
identify these cases from the current context.


So the respone 220 and/or bulk e-mail. 250 c4s1-2e-syd.xxxxxx.net.au is incorrect.

Could you debug the SMTP with telnet/openssl?

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):
Fedora 25 / Apache 2.4.27 / MariaDB 10.1.26 / PHP 7.1.10 / Mercurial

Last edited by DJ Maze on Sun Mar 29, 2020 3:09 pm; edited 1 time in total


I don't see how its incorrect?
They are different codes.

This is the banner, and the last line of the banner without the dash.
220-c4s1-2e-syd.xxxxxx.net.au ESMTP Exim 4.93 #2 Thu, 19 Mar 2020 15:10:34 +1100 220-We do not authorize the use of this system to transport unsolicited, 220 and/or bulk e-mail.

The following 250 code is the response to my HELO command above.

So the missing dash on the last 220 should tell you that it is the end of the banner (220 code) and the next code is unrelated.

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):

Last edited by hybrid on Sun Mar 29, 2020 11:16 pm; edited 2 times in total

All times are UTC


Jump to: