cURL / Mailing Lists / curl-library / Single Mail


RE: issue while using SMTP

From: Patrick Monnerat <>
Date: Wed, 25 Aug 2010 10:26:28 +0200

Harshdeep Singh wrote:
> I am trying to send a mail using SMTP with libcurl. I manage to do it
using command line option i use the command:

> curl --ssl --mail-from "<>" --mail-rcpt
"<>" -v --url smtp:// -u harshcalsoft
-T text
> curl_easy_setopt(curl,CURLOPT_URL,"smtps://");
> curl_easy_setopt (curl, CURLOPT_USERPWD, "username:password");

The only reason I can imagine for now is:
1) You use a curl/libcurl version in which the smtp authentication was
not yet implemented, and
2) Smtp is not smtps: seems that the two ports answer properly on the
same server, but unlike the smtp port, the smtps port requires an

If I'm right, the verbose output of the command line tool (not present
in your mail) should also show an unauthenticated client/server dialog.
List admin:
Received on 2010-08-25