The CRM is hosted on a shared hosting plan with GoDaddy. Do you think of any issues with GoDaddy server?
It takes hardly a couple of seconds to throw up the error message.
I tried with smtp.office365.com without any port number. It gave me following error. The credentials are same as that of IMAP settings.
[23-Jun-2015 13:17:36 +0000]: SMTP Error: SMTP error: Authentication failure: Invalid response code received from server (Code: 535) in /home/lsbme/public_html/modules/CRM/Roundcube/RC/program/lib/Roundcube/rcube.php on line 1505 (POST /modules/CRM/Roundcube/RC/?_task=mail&_unlock=loading1435065456232&_lang=en_US&_framed=1?_task=mail&_action=send)
As soon as I added the port 587 (smtp.office365.com:587), it started giving me the original error.
[23-Jun-2015 13:28:42 UTC] Connection refused (111):
[23-Jun-2015 13:28:42 UTC] Failed to connect socket: Connection refused ():
[23-Jun-2015 13:28:42 +0000]: SMTP Error: SMTP error: Connection failed: Failed to connect socket: Connection refused in /home/lsbme/public_html/modules/CRM/Roundcube/RC/program/lib/Roundcube/rcube.php on line 1505 (POST /modules/CRM/Roundcube/RC/?_task=mail&_unlock=loading1435066115837&_lang=en_US&_framed=1?_task=mail&_action=send)
Hope this may help you to pin point the cause of the problem.
Thanks & Regards
Ketan