A command line tool and library for transferring data with URL syntax, supporting DICT, FILE, FTP, FTPS, GOPHER, GOPHERS, HTTP, HTTPS, IMAP, IMAPS, LDAP, LDAPS, MQTT, POP3, POP3S, RTMP, RTMPS, RTSP, SCP, SFTP, SMB, SMBS, SMTP, SMTPS, TELNET, TFTP, WS and WSS. libcurl offers a myriad of powerful features
Find a file
Stefan Eissing 5651a36d1a
cf-socket: improvements in socket I/O handling
- Curl_write_plain/Curl_read_plain have been eliminated. Last code use
  now uses Curl_conn_send/recv so that requests use conn->send/revc
  callbacks which defaults to cfilters use.
- Curl_recv_plain/Curl_send_plain have been internalized in cf-socket.c.
- USE_RECV_BEFORE_SEND_WORKAROUND (active on Windows) has been moved
  into cf-socket.c. The pre_recv buffer is held at the socket filter
  context.  `postponed_data` structures have been removed from
  `connectdata`.
- the hanger in HTTP/2 request handling was a result of read buffering
  on all sends and the multi handling is not prepared for this. The
  following happens:

   - multi preforms on a HTTP/2 easy handle
   - h2 reads and processes data
   - this leads to a send of h2 data
   - which receives and buffers before the send
   - h2 returns
   - multi selects on the socket, but no data arrives (its in the buffer already)
   the workaround now receives data in a loop as long as there is something in
   the buffer. The real fix would be for multi to change, so that `data_pending`
   is evaluated before deciding to wait on the socket.

io_buffer, optional, in cf-socket.c, http/2 sets state.drain if lower
filter have pending data.

This io_buffer is only available/used when the
-DUSE_RECV_BEFORE_SEND_WORKAROUND is active, e.g. on Windows
configurations. It also maintains the original checks on protocol
handler being HTTP and conn->send/recv not being replaced.

The HTTP/2 (nghttp2) cfilter now sets data->state.drain when it finds
out that the "lower" filter chain has still pending data at the end of
its IO operation. This prevents the processing from becoming stalled.

Closes #10280
2023-01-31 11:23:59 +01:00
.circleci copyright: update all copyright lines and remove year ranges 2023-01-03 09:19:21 +01:00
.github zuul: stop using this CI service 2023-01-30 15:42:15 +01:00
.lift tests-httpd: basic infra to run curl against an apache httpd plus nghttpx for h3 2023-01-09 17:40:04 +01:00
.reuse copyright: update all copyright lines and remove year ranges 2023-01-03 09:19:21 +01:00
CMake cmake: use list APPEND syntax for CMAKE_REQUIRED_DEFINITIONS 2023-01-24 03:09:09 -05:00
docs curl_free.3: fix return type of curl_free 2023-01-31 08:32:37 +01:00
include system.h: assume OS400 is always built with ILEC compiler 2023-01-21 15:08:23 -05:00
lib cf-socket: improvements in socket I/O handling 2023-01-31 11:23:59 +01:00
LICENSES copyright: update all copyright lines and remove year ranges 2023-01-03 09:19:21 +01:00
m4 copyright: update all copyright lines and remove year ranges 2023-01-03 09:19:21 +01:00
packages os400: fixes to make-lib.sh and initscript.sh 2023-01-10 09:29:04 +01:00
plan9 copyright: update all copyright lines and remove year ranges 2023-01-03 09:19:21 +01:00
projects copyright: update all copyright lines and remove year ranges 2023-01-03 09:19:21 +01:00
scripts zuul: stop using this CI service 2023-01-30 15:42:15 +01:00
src tool_operate: repair --rate 2023-01-29 16:06:06 +01:00
tests zuul: stop using this CI service 2023-01-30 15:42:15 +01:00
winbuild winbuild: document that arm64 is supported 2023-01-24 03:42:17 -05:00
.azure-pipelines.yml copyright: update all copyright lines and remove year ranges 2023-01-03 09:19:21 +01:00
.cirrus.yml copyright: update all copyright lines and remove year ranges 2023-01-03 09:19:21 +01:00
.dcignore copyright: update all copyright lines and remove year ranges 2023-01-03 09:19:21 +01:00
.dir-locals.el copyright: update all copyright lines and remove year ranges 2023-01-03 09:19:21 +01:00
.git-blame-ignore-revs copyright: update all copyright lines and remove year ranges 2023-01-03 09:19:21 +01:00
.gitattributes copyright: update all copyright lines and remove year ranges 2023-01-03 09:19:21 +01:00
.gitignore copyright: update all copyright lines and remove year ranges 2023-01-03 09:19:21 +01:00
.mailmap mailmap: Andy Alt 2022-12-06 23:23:13 +01:00
acinclude.m4 copyright: update all copyright lines and remove year ranges 2023-01-03 09:19:21 +01:00
appveyor.yml copyright: update all copyright lines and remove year ranges 2023-01-03 09:19:21 +01:00
buildconf copyright: update all copyright lines and remove year ranges 2023-01-03 09:19:21 +01:00
buildconf.bat copyright: update all copyright lines and remove year ranges 2023-01-03 09:19:21 +01:00
CHANGES curl.se: new home 2020-11-04 23:59:47 +01:00
CMakeLists.txt cmake: delete redundant macro definition SECURITY_WIN32 2023-01-25 11:55:57 +00:00
configure.ac tests-httpd: basic infra to run curl against an apache httpd plus nghttpx for h3 2023-01-09 17:40:04 +01:00
COPYING copyright: update all copyright lines and remove year ranges 2023-01-03 09:19:21 +01:00
curl-config.in copyright: update all copyright lines and remove year ranges 2023-01-03 09:19:21 +01:00
GIT-INFO GIT-INFO: rephrase to adapt to s/buildconf/autoreconf 2021-09-24 13:14:52 +02:00
libcurl.pc.in copyright: update all copyright lines and remove year ranges 2023-01-03 09:19:21 +01:00
MacOSX-Framework copyright: update all copyright lines and remove year ranges 2023-01-03 09:19:21 +01:00
Makefile.am copyright: update all copyright lines and remove year ranges 2023-01-03 09:19:21 +01:00
Makefile.dist copyright: update all copyright lines and remove year ranges 2023-01-03 09:19:21 +01:00
maketgz copyright: update all copyright lines and remove year ranges 2023-01-03 09:19:21 +01:00
mlc_config.json mlc: curl.zuul.vexxhost.dev is reachable again 2022-04-24 23:29:38 +02:00
README docs: minor grammar fixes 2022-09-29 10:44:12 +02:00
README.md copyright: update all copyright lines and remove year ranges 2023-01-03 09:19:21 +01:00
RELEASE-NOTES RELEASE-NOTES: synced 2023-01-29 10:44:11 +01:00
SECURITY.md copyright: update all copyright lines and remove year ranges 2023-01-03 09:19:21 +01:00

curl logo

Curl is a command-line tool for transferring data specified with URL syntax. Find out how to use curl by reading the curl.1 man page or the MANUAL document. Find out how to install Curl by reading the INSTALL document.

libcurl is the library curl is using to do its job. It is readily available to be used by your software. Read the libcurl.3 man page to learn how.

You can find answers to the most frequent questions we get in the FAQ document.

Study the COPYING file for distribution terms.

Contact

If you have problems, questions, ideas or suggestions, please contact us by posting to a suitable mailing list.

All contributors to the project are listed in the THANKS document.

Commercial support

For commercial support, maybe private and dedicated help with your problems or applications using (lib)curl visit the support page.

Website

Visit the curl website for the latest news and downloads.

Git

To download the latest source from the Git server, do this:

git clone https://github.com/curl/curl.git

(you will get a directory named curl created, filled with the source code)

Security problems

Report suspected security problems via our HackerOne page and not in public.

Notice

Curl contains pieces of source code that is Copyright (c) 1998, 1999 Kungliga Tekniska Högskolan. This notice is included here to comply with the distribution terms.

Backers

Thank you to all our backers! 🙏 [Become a backer]

Sponsors

Support this project by becoming a sponsor.