cURL
| curl | |
|---|---|
| Original author | Daniel Stenberg[1] |
| Developer | Contributors to the curl project |
| Initial release | 1996[2] |
| Stable release | 8.16.0[3] |
| Repository | |
| Written in | C |
| Platform | 29 platforms (see § libcurl for details) |
| Type | Web client (supports e.g. HTTPS, and FTP) |
| License | curl license[4][5] (inspired on the MIT License[5]), also ISC, 3-clause BSD, 4-clause BSD[6] |
| Website | curl |
cURL (pronounced like "curl",[7] /kɜːrl/) is a free and open source CLI app for uploading and downloading individual files. It can download a URL from a web server over HTTP, and supports a variety of other network protocols, URI schemes, multiple versions of HTTP, and proxying. The project consists of a library (libcurl) and command-line tool (curl), which have been widely ported to different computing platforms.
It was created by Daniel Stenberg, who is still the lead developer of the project.
History
[edit]The software was first released in 1996,[8] originally named httpget and then became urlget, before adopting the current name of curl.[9][10] The name stands for "Client for URL".[11] The original author and lead developer is the Swedish developer Daniel Stenberg, who created curl to power part of an IRC bot, because he wanted to automatically provide currency exchange rates, fetched from a website, to users in an IRC chat room.[2]
Components
[edit]libcurl
[edit]libcurl is a client-side URL transfer library that powers curl.[12] It supports numerous internet protocols including DICT, FTP, FTPS, Gopher, HTTP (versions 1.x[13]) with HTTP/2 and HTTP/3 support (including h2c, prior-knowledge, dual-connect modes, and QUIC with 0-RTT handshakes), as well as HTTPS, IMAP, LDAPS, MQTT, POP3, RTSP, RTMP, SCP, SFTP, SMTP, SMB, Telnet, and TFTP. It also implements the file URI scheme.
The library provides features such as cookie handling, standard HTTP request methods (GET, POST, PUT, HEAD, multipart form uploads), and authentication mechanisms including Basic, Digest, NTLM, Negotiate, CRAM-MD5, SCRAM-SHA, Kerberos, Bearer tokens, AWS Sigv4, SASL, and reading credentials from .netrc.
libcurl supports a variety of security and transport features, including TLS 1.0-1.3, mutual authentication, STARTTLS, OCSP stapling, Encrypted Client Hello (ECH), False Start, key pinning, post-quantum readiness, session resumption, early data, session import/export, HSTS, Alt-Svc, Public Suffix List (PSL), entity tags (ETags), range requests, transfer compression (gzip, Brotli, zstd), custom headers, custom methods, and redirect following.
It also offers proxy and networking support, including SOCKS4, SOCKS5, HAProxy, and HTTP proxies with chaining and Unix domain sockets, as well as user-plus-password authentication[14]. Advanced name-resolution features include DNS-over-HTTPS, custom DNS servers, host/port mappings, and DNS caching.
Additional functionality includes file transfer resume, FTP uploading, form-based HTTP upload, HTTPS certificates, and mechanisms for controlling and monitoring transfers such as configurable timeouts, automatic retries, rate limiting, and detection of stalled connections. The library also provides enhanced reporting features, including JSON-formatted metadata, content-disposition handling, IDN hostname display, and customizable transfer information.
The libcurl library is portable, as it builds and works identically on most platforms, including:[15][16][17]
- AIX
- AmigaOS
- Android[citation needed]
- Azure Sphere OS
- BeOS
- BlackBerry Tablet OS and BlackBerry 10[18]
- Cesium
- Darwin
- DOS
- Deos
- FreeBSD
- FreeRTOS
- HP-UX
- HURD
- iOS
- IRIX
- Linux
- macOS
- NetBSD
- NetWare
- OpenBSD
- OpenHarmony
- OpenVMS
- OS/2
- QNX
- QNX Neutrino
- RISC OS
- RTEMS
- Solaris
- Symbian
- Tru64
- Ultrix
- UnixWare
- Windows
- VxWorks
- Zephyr
The libcurl library is thread-safe and IPv6 compatible. Bindings are available for more than 50 languages, including C, C++, Java, Julia (is bundled with), PHP and Python.[19]
The libcurl library supports GnuTLS, mbed TLS, NSS, GSKit on IBM i, SChannel on Windows, Secure Transport on macOS and iOS, SSL/TLS through OpenSSL, BoringSSL, libreSSL, AmiSSL, wolfSSL, BearSSL and rustls.[20]
curl
[edit]curl is a command-line tool for getting or sending data, including files, using URL syntax. curl provides an interface to the libcurl library; it supports every protocol libcurl supports.[14]
curl supports HTTPS, and performs SSL or TLS certificate verification by default. When curl connects to a remote server via HTTPS, it will obtain the remote server certificate, then checks against its CA certificate store the validity of the remote server to ensure the remote server is the one it claims to be. Some curl packages are bundled with a CA certificate store file. There are several options to specify a CA certificate, such as --cacert and --capath. The --cacert option can be used to specify the location of the CA certificate store file.
Starting with Windows 10 version 1809, Windows ships with curl.exe.[17] On Microsoft Windows, if a CA certificate file is not specified, curl will look for the curl-ca-bundle.crt file in the following locations, in the order given:[21]
- App's folder (where
curl.exeis located) - Current working directory
C:\Windows\System32directoryC:\Windowsdirectory- Directories specified in the
PATHenvironment variable
curl will return an error message if the remote server is using a self-signed certificate, or if the remote server certificate is not signed by a CA listed in the CA cert file. -k or --insecure option can be used to skip certificate verification. Alternatively, if the remote server is trusted, the remote server CA certificate can be added to the CA certificate store file.
tiny-curl
[edit]tiny-curl is a lightweight version of libcurl developed by wolfSSL Inc. for embedded and resource-constrained devices. It implements HTTPS functionality in roughly 100 KB of code on typical 32-bit architectures.
Licensing
[edit]curl and libcurl are distributed under the MIT License. tiny-curl, a version of curl optimized for embedded systems and supported by wolfSSL, is available under both the GNU GPLv3-or-later and commercial licensing.
Rock-solid curl[22], the long-term support (LTS) edition, uses the same curl license by default, with an option for commercial licensing for organizations that require contractual support or warranty coverage.
See also
[edit]- curl-loader – an open-source testing tool based on curl
- libwww – an early library that comes with a command line interface
- PowerShell – the iwr (Invoke-WebRequest) Windows PowerShell had functionality similar to curl; class Web-client too.[23]
- Web crawler – an internet bot that can crawl the web
- Wget – similar command-line tool with no associated library but capable of recursive downloading
References
[edit]- ^ Stenberg, Daniel (20 March 2015). "curl, 17 years old today". daniel.haxx.se. Retrieved 20 March 2015.
- ^ a b "History of curl - How curl Became Like This". curl. Archived from the original on September 30, 2017. Retrieved November 17, 2016.
Daniel simply adopted an existing command-line open-source tool, httpget, that Brazilian Rafael Sagula had written and recently release version 0.1 of. After a few minor adjustments, it did just what he needed. [...] HttpGet 1.0 was released on April 8th 1997 with brand new HTTP proxy support. [...] Stenberg was spending time writing an IRC bot for an Amiga related channel on EFnet. He then came up with the idea to make currency-exchange calculations available to Internet Relay Chat (IRC) users.
- ^ Daniel Stenberg (10 September 2025). "curl 8.16.0". Retrieved 10 September 2025.
- ^ "curl License". spdx.org.
- ^ a b "curl - copyright". curl.se. Archived from the original on 2024-01-15. Retrieved 2024-01-17.
- ^ Mehl, Max; Stenberg, Daniel (June 13, 2022). "Commit "copyright: make repository REUSE compliant"". GitHub.com.
- ^ "curl - Frequently Asked Questions". curl.se.
- ^ "History of curl". fossies.org. Archived from the original on September 17, 2021. Retrieved May 11, 2021.
- ^ "Changelog". 4 January 2020. Retrieved 4 January 2020.
The first curl release. The tool was named urlget before this. And httpget before that.
- ^ Stenberg, Daniel (4 January 2020). "Restored complete curl changelog" (html). Haxx Se. Retrieved 2 January 2020.
- ^ Stenberg, Daniel. "Origin of the name". curl.se. Retrieved 2021-03-27.
- ^ Jones, M. Tim (8 September 2009). "Conversing through the Internet with cURL and libcurl - Using libcurl with C and Python". IBM Developerworks. Archived from the original on 14 April 2015. Retrieved 12 September 2018.
- ^ Stenberg, Daniel (5 August 2019). "http09: disable HTTP/0.9 by default in both tool and library". GitHub. Archived from the original (html) on 5 August 2019. Retrieved 5 August 2019.
As the plan has been laid out in Deprecated. Update docs accordingly and verify in test 1174.
- ^ a b "curl - How To Use". curl.se.
- ^ "Third-party open-source software Curl". Gitee. OpenAtom OpenHarmony. Retrieved 17 March 2024.
- ^ "Third-party open-source software Curl". GitHub. OpenAtom OpenHarmony. Retrieved 17 March 2024.
- ^ a b Turner, Rich (18 January 2018). "Tar and Curl Come to Windows!". Windows Command Line. Microsoft.
- ^ "Open Source Components for the Native SDK for BlackBerry Tablet OS". Archived from the original on 2013-01-27. Retrieved 2017-09-19.
- ^ "libcurl bindings". curl.se.
- ^ "curl supports rustls | daniel.haxx.se". 9 February 2021. Retrieved 2022-01-01.
- ^ "curl - SSL CA Certificates". curl.se.
- ^ "Rock-solid curl".
- ^ Del, Ryan (2 March 2018). "Comandi equivalenti a cURL e Wget per Windows command-line con Powershell" [cURL and Wget equivalent commands for Windows command-line with Powershell] (html). Ryadel (in Italian). Retrieved 4 January 2020.
Per emulare il comportamento del comando Linux cURL, è sufficiente creare un file cURL.ps1 contenente la seguente riga di codice
External links
[edit]