cURL / Mailing Lists / curl-library / Single Mail

curl-library

RE: Problem with AUTH against Telia SMTP server

From: Steve Holme <steve_holme_at_hotmail.com>
Date: Tue, 30 Jul 2013 20:44:31 +0100

Hi Kim,

On Tue, 30 Jul 2013, Kim Johansson wrote:

> Log from smtp-multi , username & password is correct !
> Is it possible to change so that curl uses plain AUTH ?

What version of libcurl are you using?

Libcurl will use the best level of authentication from the list of supported
mechanisms reported by the server.

If however, you are using libcurl v7.31, you can specify the preferred
authentication mechanism in the URL or by using the CURL_EASY_SETOPT option
instead of CURLOPT_USERPWD instead of CURLOPT_USERNAME and CURLOPT_PASSWORD.
If you go for the later then you will need to modify smtp-multi by removing
the following:

   curl_easy_setopt(curl, CURLOPT_USERNAME, USERNAME);
   curl_easy_setopt(curl, CURLOPT_PASSWORD, PASSWORD);

and replacing it with:

   curl_easy_setopt(curl, CURLOPT_USERNAME, "username:password;options");

For example: "testuser:testpass;auth=PLAIN".

However, I would be more interested to know why the DIGEST-MD5 mechanism is
failing.

Kind Regards

Steve
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2013-07-30