cURL / Mailing Lists / curl-library / Single Mail

curl-library

RE: SMTP functionality with authentication fails!

From: Steve Holme <steve_holme_at_hotmail.com>
Date: Mon, 3 Dec 2012 23:06:05 +0000

Hi Daniel,

> > I hope Daniel will be able to shed some light here, as I have no
> > real "programming" experience with sending data through a
> > proxy server - and it has been a few years since I even set one
> > up (if you include Microsoft's TMG!).
>
> The fact that it went through a proxy to reach the server
> doesn't really change anything in regards to SMTP here. It is
> by all means normal SMTP.

Cool and the overview is much appreciate btw - thank you.

> > What I don't know is if libcurl supports TLS upgraded connections
> > through a proxy server - if it does then you might have found a
> > bug in the SMTP module :(
>
> It does. The proxy connection is transparent (to most parts of the
> code) and it should be able to upgrade that to TLS if there's a need.
> Since libcurl gives up here without trying it makes me suspect that
> possibly this libcurl was built without SSL support. Wouldn't that
> basically have this effect? (If so, we should probably consider
> adding some logging saying so...)

I think so yes - I've just been reviewing the code since my last email and I
believe (if memory serves me correct) that data->set.use_ssl will be zero
when there is no SSL support. As a result smtp_authenticate() will be called
from smtp_state_ehlo_resp() instead of starting off the upgrade, this in
turn will return CURLE_LOGIN_DENIED as the error code and set the logging
info to "No known authentication mechanisms supported!" as is being seen.

We could change the infof() call to set something more meaningful if there
is no SSL support, however, how can we determine whether the user requested
SSL support or not if data->use_ssl is always zero?

Kind Regards

Steve
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2012-12-04