Copy link to clipboard
Copied
Hi
I work with a non-profit in northern California that facilitates high-tech internships for teachers.
While their site host is Hostmysite.com - they recently moved their email services to Microsoft Online's hosted Exchange services. As such, I need to update their code to send email notifications off of their new exchange servers so email dont appear as spoofs. '
Microsoft provides the following settings:
http://blogs.technet.com/msonline/archive/2009/09/02/using-smtp-relay-with-exchange-online.aspx
I've set my cfmail tag as such - however, regardless if I use useTLS, useSSL or both, the emails are not sent. A quick review of the CF mail log file reveals:
"Error","scheduler-1","04/14/10","14:47:00",,"Could not connect to SMTP host: smtp.mail.microsoftonline.com, port: 587"
<cfmail server="smtp.mail.microsoftonline.com"
username="web@***.org"
password="********"
useTLS="true"
port="587"
subject="Hello World"
to="****@yahoo.com"
from="web@***.org">
This is my test email - did it work?
</cfmail>
Any ideas? Your help is appreciated!
Ben
<cfmail server="smtp.mail.microsoftonline.com" username="web@****.org" password="********" useTLS="true" port="587" subject="Hello World" to="****@yahoo.com" from="web@****.org"> This is my test email - did it work? </cfmail>
Copy link to clipboard
Copied
Can you telnet onto it from the server running CF?
--
Adam
Copy link to clipboard
Copied
As Adam's getting at, that sounds a lot like your firewall is blocking you - seeing as it's on a weird port I wouldn't be surprised.
Open a command prompt and type the following:
telnet smtp.mail.microsoftonline.com 587
From here, I get this header, which means I've connected:
220 smtp.mail.microsoftonline.com Microsoft ESMTP MAIL Service ready at Fri, 16
Apr 2010 00:24:09 -0700
If the prompt just hangs instead, it's a networking or firewall issue.
O.
Copy link to clipboard
Copied
got it. i tried your telnet and received the following error:
Connecting To smtp.mail.microsoftonline.com...Could not open connection to the host, on port 587: Connect failed
What would this mean?
Thanks again for your help!
Ben
Copy link to clipboard
Copied
Your firewall is probably blocking that port.
--
Adam
Copy link to clipboard
Copied
Im not sure - I am able to connect to this account using Outlook Express. Would I be able to do that if the port was blocked?
Copy link to clipboard
Copied
Outlook can use multiple protocols and ports to connect. You need to talk to whomever controls the firewalls between the CF server and internet.
Copy link to clipboard
Copied
thanks and i understand that; but in outlook express i did specify the port and the protocol (tls) so it should go out 587 if i specified it right?
Copy link to clipboard
Copied
You're running Outlook Express on your CF server? And can you send email via this OE connection?
I dunno how OE works, but I back what telnet says. Also, if I can telnet onto the Exchange server and you cannot... the port or the IP address is blocked on your end.
Firewalls can also have application-specific settings, so maybe it's been opened for OE and not other things. Dunno. But the person responsible for your firewall will know, so go ask them. It's a more sensible approach than just speculating what might be going on.
--
Adam