Page MenuHomePhabricator

wgSMTP does not reply correctly on error
Closed, ResolvedPublic

Description

Author: sancelot

Description:
I am using wgSMTP with auth mode.

If you made a mistake in wgSMTP setup,you should receive a mistake page
unfortunately this does not happens, because the error muistake message is a PEAR_Error object and can not be converted to string.

to solve this problem, you have to modify includes/UserMailer.php as follow :

lines 160 :

$err = $mail_object->send($dest, $headers, $body);

				if (PEAR::isError($err))
				{
					return $err->toString();
				}
				else return '';

my wrong wgSMTP setup was :

$wgSMTP=array (
"host" => "mail.xxxxx.com",
"IDHost" => "xxxx.com",
"port" => "25",
"auth" => "true",
"username" => "sancelot@xxxx.com",
"password" => "pass",
);

and the right wgSMTP setup is (port and auth mistakes) :
$wgSMTP=array (
"host" => "mail.xxxxx.com",
"IDHost" => "xxxx.com",
"port" => 25,
"auth" => true,
"username" => "sancelot@xxxx.com",
"password" => "pass",
);


Version: unspecified
Severity: critical

Details

Reference
bz13411

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 21 2014, 10:04 PM
bzimport set Reference to bz13411.
bzimport added a subscriber: Unknown Object (MLST).
  • This bug has been marked as a duplicate of bug 11567 ***