curl-users
RE: Possible issue with SMTP/TLS or SMTP/SSLū
Date: Wed, 6 Nov 2013 19:11:31 +0000
On Wed, 6 Nov 2013, Jaya Kumar wrote:
> So a quick question before I struggle further, has anyone been
> successful using curl to send mail using hotmail? If possible,
> would you mind sharing the command line or test C program?
Yes... Both the following commands worked for me:
curl -v -k smtp://smtp.live.com:587 -u myhotmailaddress --mail-from myhotmailaddress --mail-rcpt analternativeaddress -T c:\curl\mail.txt --ssl
and
curl -v -k smtp://smtp.live.com:587 -u myhotmailaddress --mail-from myhotmailaddress --mail-rcpt analternativeaddress -T c:\curl\mail.txt --ssl-req
I can either specify my password on the command line or let curl prompt for it. Rather oddly hotmail have either a) just enabled LOGIN as well as PLAIN as an authentication mechanism or b) some of their servers in the farm don't offer LOGIN. Either way both LOGIN and PLAIN worked for me ;-)
Can you check that your username and password details are correct?
I base64 decoded what appears after the AUTH PLAIN in the log you gave and it doesn't quite look right to me (although you may have edited this for the purpose of your post - hopefully - as you don't want to publically advertise your log in details!)
PLAIN authentication isn't very secure - hence why hotmail and google require a TLS upgrade to use it, but it should be in the following format should you decode it:
username\0username\0password
I hope this help.
Kind Regards
Steve
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-users
FAQ: http://curl.haxx.se/docs/faq.html
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2013-11-06