<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<META NAME="Generator" CONTENT="MS Exchange Server version 6.5.7652.24">
<TITLE>RE: Problem accessing http sites using libcurl on maemo platform</TITLE>
</HEAD>
<BODY>
<!-- Converted from text/plain format -->
<P><FONT SIZE=2>Hi,<BR>
I am using following code and it is working for me.<BR>
******************************************************************************<BR>
char userid_passwd[256];<BR>
memset(userid_passwd, 0, sizeof(userid_passwd));<BR>
sprintf(userid_passwd,"%s:%s", "userid", "passwd");<BR>
<BR>
curl_easy_setopt(curl, CURLOPT_PROXY, "proxy_ip_address:port_no");<BR>
curl_easy_setopt(curl, CURLOPT_PROXYUSERPWD, userid_passwd);<BR>
*******************************************************************************<BR>
<BR>
Best Regards,<BR>
ABhijit<BR>
<BR>
<BR>
<BR>
<BR>
-----Original Message-----<BR>
From: maemo-users-bounces@maemo.org on behalf of TietoEnator LinuxTeam<BR>
Sent: Fri 5/23/2008 11:04 AM<BR>
To: maemo-users@maemo.org<BR>
Subject: Fwd: Problem accessing http sites using libcurl on maemo platform<BR>
<BR>
Hi all,<BR>
<BR>
i am unable to connect and get the html page of my blog account in<BR>
blogger.com website<BR>
Authentication problem with user name and password.<BR>
I hope some body can help me on this issue<BR>
here i am giving you the code snippet i used.<BR>
<BR>
<BR>
<BR>
curl_easy_setopt(curl_handle, CURLOPT_SSL_VERIFYPEER, FALSE);<BR>
<BR>
<BR>
curl_easy_setopt(curl_handle, CURLOPT_PROXY, "<my proxy settings>");<BR>
<BR>
<BR>
curl_easy_setopt(curl_handle, CURLOPT_TIMEOUT, 20);<BR>
<BR>
<BR>
<BR>
curl_easy_setopt(curl_handle, CURLOPT_HTTPAUTH, CURLAUTH_ANY);<BR>
<BR>
curl_easy_setopt(curl_handle, CURLOPT_URL, "<A HREF="http://blogger.com">http://blogger.com</A>");<BR>
<BR>
curl_easy_setopt (curl_handle, CURLOPT_FOLLOWLOCATION, 1);<BR>
curl_easy_setopt (curl_handle, CURLOPT_UNRESTRICTED_AUTH, 1);<BR>
curl_easy_setopt(curl_handle, CURLOPT_MAXREDIRS, 10);<BR>
curl_easy_setopt (curl_handle, CURLOPT_MAXCONNECTS, 20);<BR>
curl_easy_setopt (curl_handle, CURLOPT_AUTOREFERER, 1);<BR>
curl_easy_setopt (curl_handle, CURLOPT_COOKIEFILE, cookie);<BR>
curl_easy_setopt(curl_handle, CURLOPT_HTTP_VERSION,CURL_HTTP_VERSION_NONE);<BR>
curl_easy_setopt(curl_handle, CURLOPT_HTTPGET,1);<BR>
curl_easy_setopt(curl_handle, CURLOPT_HTTPHEADER,NULL);<BR>
curl_easy_setopt(curl_handle, CURLOPT_USERPWD, "username:password");<BR>
<BR>
curl_easy_setopt(curl_handle, CURLOPT_FILE, my_file);<BR>
<BR>
authentication is failing all the time.<BR>
<BR>
</FONT>
</P>
</BODY>
</HTML>