c - Hotmail/Outlook.com connection failure on AUTH commands -


i'm working on embedded application (running mqx rtos, written in c) has smtp functionality. recently, tls support added using mocana nanossl library. i'm able send emails using gmail, yahoo, , private exchange servers. unfortunately, hotmail not work. here's connection parameters i've used:

server: smtp.live.com
port: 25 , 587
auth method: plain , login

basically, i'm able connect server, perform ssl/tls handshake (using starttls), , send encrypted ehlo message server (receiving response). according response, server supports both auth plain , auth login. however, once send either of these commands, following ssl_recv() call make response fails either timeout or connection reset peer.

update:
ok, after experimentation appear issue lies @ ssl library level , not microsoft's smtp server. tried replacing ssl_recv() calls standard rtcs socket recv() calls , able receive , view encrypted data. disabling response verification, able continue through smtp process , send message. @ time i'm not sure why ssl_recv() calls unable socket data, i'll keep digging , find answer.

well, got working here too. had replace the

ssl_ctx=ssl_ctx_new(sslv23_client_method());

with either:

ssl_ctx=ssl_ctx_new(sslv3_client_method()); 

or

ssl_ctx=ssl_ctx_new(tlsv1_client_method()); 

my understanding 23_client method sends ssl2 client hello first , confuses server. read in hp ssl programming tutorial:

http://h71000.www7.hp.com/doc/83final/ba554_90007/ch04s03.html

it says: "however, ssl client using sslv23 method cannot establish connection ssl server sslv3/tlsv1 method because sslv2 hello message sent client."

ssl3 works since can continue after starttls ssl, not have use tls.

see here: https://www.fastmail.fm/help/technology_ssl_vs_tls_starttls.html


Comments

Popular posts from this blog

c++ - Creating new partition disk winapi -

Android Prevent Bluetooth Pairing Dialog -

VBA function to include CDATA -