EllisLab/CodeIgniter — Issue #1080: $this->email->send() returns TRUE if authentication fails
Author: AeroCross
Created: 2012-02-24 19:23:51+00:00
State: open

After a few tests, I can successfully reproduce the following error:

Configuration:
``php
$config = array(
'protocol' => 'smtp',
'smtp_host' => 'mail.server.com',
'smtp_user' => 'nonexisting@email.com',
'smtp_pass' => 'password',
'smtp_port' => '587',
'mailtype' => 'text',
'validate' => TRUE,
'crlf' => '\r\n',
'newline' => '\r\n'
);
``
Debugger:

``
hello: 250-ingeni.ingenium-dv.com Hello localhost [200.75.111.150]
250-SIZE 52428800
250-PIPELINING
250-AUTH LOGIN
250 HELP
Failed to authenticate password. Error: 535 Incorrect authentication data
from: 250 OK
data: 503 valid RCPT command must precede DATA
The following SMTP error was encountered: 503 valid RCPT command must precede DATA
500 unrecognized command
The following SMTP error was encountered: 500 unrecognized command
Unable to send email using PHP SMTP. Your server might not be configured to send mail using this method.
Your message has been successfully sent using the following protocol: smtp
``

Yet, as you can see in the debugger (last line), it returns TRUE.