Questions tagged [libcurl]

Use this tag only for questions related to the multiprotocol internet transfer library, for question related to command line tool please use the specific curl tag

libcurl is a free and easy-to-use client-side URL transfer library, supporting DICT, FILE, FTP, FTPS, GOPHER, HTTP, HTTPS, IMAP, IMAPS, LDAP, LDAPS, POP3, POP3S, RTMP, RTSP, SCP, SFTP, SMTP, SMTPS, TELNET and TFTP. libcurl supports SSL certificates, HTTP POST, HTTP PUT, FTP uploading, HTTP form based upload, proxies, cookies, user+password authentication (Basic, Digest, NTLM, Negotiate, Kerberos), file transfer resume, http proxy tunneling and more!

libcurl is highly portable, it builds and works identically on numerous platforms, including Solaris, NetBSD, FreeBSD, OpenBSD, Darwin, HPUX, IRIX, AIX, Tru64, Linux, UnixWare, HURD, Windows, Amiga, OS/2, BeOs, Mac OS X, Ultrix, QNX, OpenVMS, RISC OS, Novell NetWare, DOS and more...

libcurl is free, thread-safe, IPv6 compatible, feature rich, well supported, fast, thoroughly documented and is already used by many known, big and successful companies and numerous applications.

libcurl provides a few different APIs, the most common and popular one being the easy interface - which does internet transfers synchronously. The documentation for this is for the C API but most language bindings follows that pretty closely which makes the C documentation fairly universal.

See also:

3187 questions
258
votes
13 answers

curl : (1) Protocol https not supported or disabled in libcurl

I'm trying to install the Rails environments on Ubuntu 11.04. When I launch the command rvm install 1.9.2 --with-openssl-dir=/usr/local the following error is received: curl : (1) Protocol https not supported or disabled in libcurl How can this be…
Giuseppe Di Federico
  • 3,501
  • 4
  • 20
  • 19
155
votes
7 answers

Why can't Python find shared objects that are in directories in sys.path?

I'm trying to import pycurl: $ python -c "import pycurl" Traceback (most recent call last): File "", line 1, in ImportError: libcurl.so.4: cannot open shared object file: No such file or directory Now, libcurl.so.4 is in…
user135171
114
votes
4 answers

C libcurl get output into a string

I want to store the result of this curl function in a variable, how can I do so? #include #include int main(void) { CURL *curl; CURLcode res; curl = curl_easy_init(); if(curl) { curl_easy_setopt(curl,…
frx08
  • 4,222
  • 8
  • 37
  • 45
102
votes
2 answers

Http status code with libcurl?

How do I get the HTTP status code (eg 200 or 500) after calling curl_easy_perform?
twk
  • 16,760
  • 23
  • 73
  • 97
99
votes
5 answers

Show Curl POST Request Headers? Is there a way to do this?

I'm building a Curl web automation app and am having some issue with not getting the desired outcome of my POST action, I am having some trouble figuring out how I can show the full POST request I am sending over (with headers), I have been…
Rick
  • 16,612
  • 34
  • 110
  • 163
96
votes
1 answer

What is the incentive for curl to release the library for free?

I recently started using libCurl for my VC++ project. I've been wondering: what is the incentive for the curl creators to release the entire library for free? Is it purely to help their fellow developers? This is one of the best open source…
nsivakr
  • 1,565
  • 2
  • 25
  • 46
79
votes
6 answers

Django returning HTTP 301?

I have a django view that returns HTTP 301 on a curl request: grapefruit:~ pete$ curl -I http://someurl HTTP/1.1 301 MOVED PERMANENTLY Date: Fri, 16 Oct 2009 19:01:08 GMT Server: Apache/2.2.9 (Win32) mod_wsgi/2.5 Python/2.6.2 PHP/5.2.6 Location:…
slypete
  • 5,538
  • 11
  • 47
  • 64
69
votes
2 answers

Download file using libcurl in C/C++

I am building an application (on windows using Dev-C++) and I want it to download a file. I am doing this using libcurl (I have already installed the source code using packman). I found a working example…
user197967
65
votes
4 answers

Persistent/keepalive HTTP with the PHP Curl library?

I'm using a simple PHP library to add documents to a SOLR index, via HTTP. There are 3 servers involved, currently: The PHP box running the indexing job A database box holding the data being indexed The solr box. At 80 documents/sec (out of 1…
Frank Farmer
  • 38,246
  • 12
  • 71
  • 89
64
votes
4 answers

undefined reference to curl_global_init, curl_easy_init and other function(C)

I am trying to use Curl in C. I visited Curl official page, and copied sample source code. below is the link: http://curl.haxx.se/libcurl/c/sepheaders.html when I run this code with command "gcc test.c", the console shows message like…
Juneyoung Oh
  • 7,318
  • 16
  • 73
  • 121
53
votes
5 answers

How can I get rid of the __imp__ prefix in the linker in VC++?

I'm using libcurl and am getting the following sort of linker errors in VC++ 10. 1>main.obj : error LNK2019: unresolved external symbol __imp__curl_easy_strerror referenced in function "class std::basic_string
BeeBand
  • 10,953
  • 19
  • 61
  • 83
52
votes
10 answers

Getting LibCurl to work with Visual Studio 2013

I am having trouble getting LibCurl to work with Visual Studio 2013. I downloaded the current version (curl-7.33.0) and tried following the instructions I found on this site: Using LibCurl with Visual 2010 But I can't find curllib.lib in the folder…
Quaxton Hale
  • 2,460
  • 5
  • 40
  • 71
50
votes
1 answer

Build working libcurl with WinSSL, NTLM, HTTP2, SSH2 and IPv6 support

In our PHP application, we need the PHP curl-extension built in a way, that it supports the following features: WinSSL (Access to the Windows certificate store) NTLM, Basic and Digest authentication HTTP/2 support SSH2 support IPv6 support I've…
Jost
  • 5,948
  • 8
  • 42
  • 72
44
votes
10 answers

Building libcurl with SSL support on Windows

I'm using libcurl in a Win32 C++ application. I have the curllib.vcproj project added to my solution and set my other projects to depend on it. How do I build it with SSL support enabled?
sharkin
  • 12,162
  • 24
  • 86
  • 122
38
votes
9 answers

How to solve 'libcurl' not found with Rails on Windows

This is giving me a headache. I'm continuing a Rails project that started on Linux and I keep getting this when I run Puma on Ruby Mine: Error:[rake --tasks] DL is deprecated, please use Fiddle rake aborted! LoadError: Could not open library…
JStriedinger
  • 549
  • 1
  • 5
  • 8
1
2 3
99 100