summaryrefslogtreecommitdiff
path: root/docs/cmdline-opts/page-footer
blob: 42a379b9b06f009253bc463fdfbaae2795e7ddb7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
.SH FILES
.I ~/.curlrc
.RS
Default config file, see --config for details.
.SH ENVIRONMENT
The environment variables can be specified in lower case or upper case. The
lower case version has precedence. http_proxy is an exception as it is only
available in lower case.

Using an environment variable to set the proxy has the same effect as using
the --proxy option.

.IP "http_proxy [protocol://]<host>[:port]"
Sets the proxy server to use for HTTP.
.IP "HTTPS_PROXY [protocol://]<host>[:port]"
Sets the proxy server to use for HTTPS.
.IP "[url-protocol]_PROXY [protocol://]<host>[:port]"
Sets the proxy server to use for [url-protocol], where the protocol is a
protocol that curl supports and as specified in a URL. FTP, FTPS, POP3, IMAP,
SMTP, LDAP, etc.
.IP "ALL_PROXY [protocol://]<host>[:port]"
Sets the proxy server to use if no protocol-specific proxy is set.
.IP "NO_PROXY <comma-separated list of hosts/domains>"
list of host names that should not go through any proxy. If set to an asterisk
\&'*' only, it matches all hosts. Each name in this list is matched as either
a domain name which contains the hostname, or the hostname itself.

This environment variable disables use of the proxy even when specified with
the --proxy option. That is
.B NO_PROXY=direct.example.com curl -x http://proxy.example.com
.B http://direct.example.com
accesses the target URL directly, and
.B NO_PROXY=direct.example.com curl -x http://proxy.example.com
.B http://somewhere.example.com
accesses the target URL through the proxy.

The list of host names can also be include numerical IP addresses, and IPv6
versions should then be given without enclosing brackets.

IPv6 numerical addresses are compared as strings, so they will only match if
the representations are the same: "::1" is the same as "::0:1" but they do not
match.
.IP "APPDATA <dir>"
On Windows, this variable is used when trying to find the home directory. If
the primary home variable are all unset.
.IP "COLUMNS <terminal width>"
If set, the specified number of characters will be used as the terminal width
when the alternative progress-bar is shown. If not set, curl will try to
figure it out using other ways.
.IP "CURL_CA_BUNDLE <file>"
If set, will be used as the \fI--cacert\fP value.
.IP "CURL_HOME <dir>"
If set, is the first variable curl checks when trying to find its home
directory. If not set, it continues to check \fBXDG_CONFIG_HOME\fP.
.IP "CURL_SSL_BACKEND <TLS backend>"
If curl was built with support for "MultiSSL", meaning that it has built-in
support for more than one TLS backend, this environment variable can be set to
the case insensitive name of the particular backend to use when curl is
invoked. Setting a name that is not a built-in alternative will make curl
stay with the default.

SSL backend names (case-insensitive): bearssl, gnutls, gskit, mbedtls,
mesalink, nss, openssl, rustls, schannel, secure-transport, wolfssl
.IP "HOME <dir>"
If set, this is used to find the home directory when that is needed. Like when
looking for the default .curlrc. \fBCURL_HOME\fP and \fBXDG_CONFIG_HOME\fP
have preference.
.IP "QLOGDIR <directory name>"
If curl was built with HTTP/3 support, setting this environment variable to a
local directory will make curl produce qlogs in that directory, using file
names named after the destination connection id (in hex). Do note that these
files can become rather large. Works with both QUIC backends.
.IP SHELL
Used on VMS when trying to detect if using a DCL or a "unix" shell.
.IP "SSL_CERT_DIR <dir>"
If set, will be used as the \fI--capath\fP value.
.IP "SSL_CERT_FILE <path>"
If set, will be used as the \fI--cacert\fP value.
.IP "SSLKEYLOGFILE <file name>"
If you set this environment variable to a file name, curl will store TLS
secrets from its connections in that file when invoked to enable you to
analyze the TLS traffic in real time using network analyzing tools such as
Wireshark. This works with the following TLS backends: OpenSSL, libressl,
BoringSSL, GnuTLS, NSS and wolfSSL.
.IP "USERPROFILE <dir>"
On Windows, this variable is used when trying to find the home directory. If
the other, primary, variable are all unset. If set, curl will use the path
"$USERPROFILE\\Application Data".
.IP "XDG_CONFIG_HOME <dir>"
If \fBCURL_HOME\fP is not set, this variable is checked when looking for a
default .curlrc file.
.SH "PROXY PROTOCOL PREFIXES"
The proxy string may be specified with a protocol:// prefix to specify
alternative proxy protocols. (Added in 7.21.7)

If no protocol is specified in the proxy string or if the string does not match
a supported one, the proxy will be treated as an HTTP proxy.

The supported proxy protocol prefixes are as follows:
.IP "http://"
Makes it use it as an HTTP proxy. The default if no scheme prefix is used.
.IP "https://"
Makes it treated as an **HTTPS** proxy.
.IP "socks4://"
Makes it the equivalent of --socks4
.IP "socks4a://"
Makes it the equivalent of --socks4a
.IP "socks5://"
Makes it the equivalent of --socks5
.IP "socks5h://"
Makes it the equivalent of --socks5-hostname
.SH EXIT CODES
There are a bunch of different error codes and their corresponding error
messages that may appear under error conditions. At the time of this writing,
the exit codes are:
.IP 1
Unsupported protocol. This build of curl has no support for this protocol.
.IP 2
Failed to initialize.
.IP 3
URL malformed. The syntax was not correct.
.IP 4
A feature or option that was needed to perform the desired request was not
enabled or was explicitly disabled at build-time. To make curl able to do
this, you probably need another build of libcurl!
.IP 5
Could not resolve proxy. The given proxy host could not be resolved.
.IP 6
Could not resolve host. The given remote host could not be resolved.
.IP 7
Failed to connect to host.
.IP 8
Weird server reply. The server sent data curl could not parse.
.IP 9
FTP access denied. The server denied login or denied access to the particular
resource or directory you wanted to reach. Most often you tried to change to a
directory that does not exist on the server.
.IP 10
FTP accept failed. While waiting for the server to connect back when an active
FTP session is used, an error code was sent over the control connection or
similar.
.IP 11
FTP weird PASS reply. Curl could not parse the reply sent to the PASS request.
.IP 12
During an active FTP session while waiting for the server to connect back to
curl, the timeout expired.
.IP 13
FTP weird PASV reply, Curl could not parse the reply sent to the PASV request.
.IP 14
FTP weird 227 format. Curl could not parse the 227-line the server sent.
.IP 15
FTP cannot use host. Could not resolve the host IP we got in the 227-line.
.IP 16
HTTP/2 error. A problem was detected in the HTTP2 framing layer. This is
somewhat generic and can be one out of several problems, see the error message
for details.
.IP 17
FTP could not set binary. Could not change transfer method to binary.
.IP 18
Partial file. Only a part of the file was transferred.
.IP 19
FTP could not download/access the given file, the RETR (or similar) command
failed.
.IP 21
FTP quote error. A quote command returned error from the server.
.IP 22
HTTP page not retrieved. The requested url was not found or returned another
error with the HTTP error code being 400 or above. This return code only
appears if --fail is used.
.IP 23
Write error. Curl could not write data to a local filesystem or similar.
.IP 25
FTP could not STOR file. The server denied the STOR operation, used for FTP
uploading.
.IP 26
Read error. Various reading problems.
.IP 27
Out of memory. A memory allocation request failed.
.IP 28
Operation timeout. The specified time-out period was reached according to the
conditions.
.IP 30
FTP PORT failed. The PORT command failed. Not all FTP servers support the PORT
command, try doing a transfer using PASV instead!
.IP 31
FTP could not use REST. The REST command failed. This command is used for
resumed FTP transfers.
.IP 33
HTTP range error. The range "command" did not work.
.IP 34
HTTP post error. Internal post-request generation error.
.IP 35
SSL connect error. The SSL handshaking failed.
.IP 36
Bad download resume. Could not continue an earlier aborted download.
.IP 37
FILE could not read file. Failed to open the file. Permissions?
.IP 38
LDAP cannot bind. LDAP bind operation failed.
.IP 39
LDAP search failed.
.IP 41
Function not found. A required LDAP function was not found.
.IP 42
Aborted by callback. An application told curl to abort the operation.
.IP 43
Internal error. A function was called with a bad parameter.
.IP 45
Interface error. A specified outgoing interface could not be used.
.IP 47
Too many redirects. When following redirects, curl hit the maximum amount.
.IP 48
Unknown option specified to libcurl. This indicates that you passed a weird
option to curl that was passed on to libcurl and rejected. Read up in the
manual!
.IP 49
Malformed telnet option.
.IP 51
The peer's SSL certificate or SSH MD5 fingerprint was not OK.
.IP 52
The server did not reply anything, which here is considered an error.
.IP 53
SSL crypto engine not found.
.IP 54
Cannot set SSL crypto engine as default.
.IP 55
Failed sending network data.
.IP 56
Failure in receiving network data.
.IP 58
Problem with the local certificate.
.IP 59
Could not use specified SSL cipher.
.IP 60
Peer certificate cannot be authenticated with known CA certificates.
.IP 61
Unrecognized transfer encoding.
.IP 62
Invalid LDAP URL.
.IP 63
Maximum file size exceeded.
.IP 64
Requested FTP SSL level failed.
.IP 65
Sending the data requires a rewind that failed.
.IP 66
Failed to initialise SSL Engine.
.IP 67
The user name, password, or similar was not accepted and curl failed to log in.
.IP 68
File not found on TFTP server.
.IP 69
Permission problem on TFTP server.
.IP 70
Out of disk space on TFTP server.
.IP 71
Illegal TFTP operation.
.IP 72
Unknown TFTP transfer ID.
.IP 73
File already exists (TFTP).
.IP 74
No such user (TFTP).
.IP 75
Character conversion failed.
.IP 76
Character conversion functions required.
.IP 77
Problem reading the SSL CA cert (path? access rights?).
.IP 78
The resource referenced in the URL does not exist.
.IP 79
An unspecified error occurred during the SSH session.
.IP 80
Failed to shut down the SSL connection.
.IP 82
Could not load CRL file, missing or wrong format (added in 7.19.0).
.IP 83
Issuer check failed (added in 7.19.0).
.IP 84
The FTP PRET command failed.
.IP 85
Mismatch of RTSP CSeq numbers.
.IP 86
Mismatch of RTSP Session Identifiers.
.IP 87
Unable to parse FTP file list.
.IP 88
FTP chunk callback reported error.
.IP 89
No connection available, the session will be queued.
.IP 90
SSL public key does not matched pinned public key.
.IP 91
Invalid SSL certificate status.
.IP 92
Stream error in HTTP/2 framing layer.
.IP 93
An API function was called from inside a callback.
.IP 94
An authentication function returned an error.
.IP 95
A problem was detected in the HTTP/3 layer. This is somewhat generic and can
be one out of several problems, see the error message for details.
.IP 96
QUIC connection error. This error may be caused by an SSL library error. QUIC
is the protocol used for HTTP/3 transfers.
.IP XX
More error codes will appear here in future releases. The existing ones
are meant to never change.
.SH BUGS
If you experience any problems with curl, submit an issue in the project's bug
tracker on GitHub: https://github.com/curl/curl/issues
.SH AUTHORS / CONTRIBUTORS
Daniel Stenberg is the main author, but the whole list of contributors is
found in the separate THANKS file.
.SH WWW
https://curl.se
.SH "SEE ALSO"
.BR ftp (1),
.BR wget (1)