reference/curl/functions/curl-setopt.xml
310963ad9ab1c2ca315361ff94314a21fa65f8b8
...
...
@@ -10,7 +10,7 @@
10
10
&reftitle.description;
11
11
<methodsynopsis>
12
12
<type>bool</type><methodname>curl_setopt</methodname>
13
-
<methodparam><type>resource</type><parameter>ch</parameter></methodparam>
13
+
<methodparam><type>CurlHandle</type><parameter>handle</parameter></methodparam>
14
14
<methodparam><type>int</type><parameter>option</parameter></methodparam>
15
15
<methodparam><type>mixed</type><parameter>value</parameter></methodparam>
16
16
</methodsynopsis>
...
...
@@ -61,18 +61,6 @@
61
61
</entry>
62
62
</row>
63
63
<row>
64
-
<entry valign="top"><constant>CURLOPT_BINARYTRANSFER</constant></entry>
65
-
<entry valign="top">
66
-
&true; to return the raw output when
67
-
<constant>CURLOPT_RETURNTRANSFER</constant> is used.
68
-
</entry>
69
-
<entry valign="top">
70
-
From PHP 5.1.3, this option has no effect: the raw output will
71
-
always be returned when
72
-
<constant>CURLOPT_RETURNTRANSFER</constant> is used.
73
-
</entry>
74
-
</row>
75
-
<row>
76
64
<entry valign="top"><constant>CURLOPT_COOKIESESSION</constant></entry>
77
65
<entry valign="top">
78
66
&true; to mark this as a new cookie "session". It will force libcurl
...
...
@@ -88,12 +76,11 @@
88
76
<row>
89
77
<entry valign="top"><constant>CURLOPT_CERTINFO</constant></entry>
90
78
<entry valign="top">
91
-
&true; to output SSL certification information to <literal>STDERR</literal>
79
+
&true; to output SSL certification information to <constant>STDERR</constant>
92
80
on secure transfers.
93
81
</entry>
94
82
<entry valign="top">
95
83
Added in cURL 7.19.1.
96
-
Available since PHP 5.3.2.
97
84
Requires <constant>CURLOPT_VERBOSE</constant> to be on to have an effect.
98
85
</entry>
99
86
</row>
...
...
@@ -106,7 +93,6 @@
106
93
</entry>
107
94
<entry valign="top">
108
95
Added in 7.15.2.
109
-
Available since PHP 5.5.0.
110
96
</entry>
111
97
</row>
112
98
<row>
...
...
@@ -119,10 +105,51 @@
119
105
</entry>
120
106
</row>
121
107
<row>
108
+
<entry valign="top"><constant>CURLOPT_DISALLOW_USERNAME_IN_URL</constant></entry>
109
+
<entry valign="top">
110
+
&true; to not allow URLs that include a username. Usernames are allowed by default (0).
111
+
</entry>
112
+
<entry valign="top">
113
+
Added in cURL 7.61.0. Available since PHP 7.3.0.
114
+
</entry>
115
+
</row>
116
+
<row>
117
+
<entry valign="top"><constant>CURLOPT_DNS_SHUFFLE_ADDRESSES</constant></entry>
118
+
<entry valign="top">
119
+
&true; to shuffle the order of all returned addresses so that they will be used
120
+
in a random order, when a name is resolved and more than one IP address is returned.
121
+
This may cause IPv4 to be used before IPv6 or vice versa.
122
+
</entry>
123
+
<entry valign="top">
124
+
Added in cURL 7.60.0. Available since PHP 7.3.0.
125
+
</entry>
126
+
</row>
127
+
<row>
128
+
<entry valign="top"><constant>CURLOPT_HAPROXYPROTOCOL</constant></entry>
129
+
<entry valign="top">
130
+
&true; to send an HAProxy PROXY protocol v1 header at the start of the connection.
131
+
The default action is not to send this header.
132
+
</entry>
133
+
<entry valign="top">
134
+
Added in cURL 7.60.0. Available since PHP 7.3.0.
135
+
</entry>
136
+
</row>
137
+
<row>
138
+
<entry valign="top"><constant>CURLOPT_SSH_COMPRESSION</constant></entry>
139
+
<entry valign="top">
140
+
&true; to enable built-in SSH compression. This is a request, not an order;
141
+
the server may or may not do it.
142
+
</entry>
143
+
<entry valign="top">
144
+
Added in cURL 7.56.0. Available since PHP 7.3.0.
145
+
</entry>
146
+
</row>
147
+
<row>
122
148
<entry valign="top"><constant>CURLOPT_DNS_USE_GLOBAL_CACHE</constant></entry>
123
149
<entry valign="top">
124
-
&true; to use a global DNS cache. This option is
125
-
not thread-safe and is enabled by default.
150
+
&true; to use a global DNS cache. This option is not thread-safe.
151
+
It is conditionally enabled by default if PHP is built for non-threaded use
152
+
(CLI, FCGI, Apache2-Prefork, etc.).
126
153
</entry>
127
154
<entry valign="top">
128
155
</entry>
...
...
@@ -138,11 +165,20 @@
138
165
</entry>
139
166
</row>
140
167
<row>
168
+
<entry valign="top"><constant>CURLOPT_SSL_FALSESTART</constant></entry>
169
+
<entry valign="top">
170
+
&true; to enable TLS false start.
171
+
</entry>
172
+
<entry valign="top">
173
+
Added in cURL 7.42.0. Available since PHP 7.0.7.
174
+
</entry>
175
+
</row>
176
+
<row>
141
177
<entry valign="top"><constant>CURLOPT_FILETIME</constant></entry>
142
178
<entry valign="top">
143
179
&true; to attempt to retrieve the modification
144
180
date of the remote document. This value can be retrieved using
145
-
the <parameter>CURLINFO_FILETIME</parameter> option with
181
+
the <constant>CURLINFO_FILETIME</constant> option with
146
182
<function>curl_getinfo</function>.
147
183
</entry>
148
184
<entry valign="top">
...
...
@@ -153,9 +189,8 @@
153
189
<entry valign="top">
154
190
&true; to follow any
155
191
<literal>"Location: "</literal> header that the server sends as
156
-
part of the HTTP header (note this is recursive, PHP will follow as
157
-
many <literal>"Location: "</literal> headers that it is sent,
158
-
unless <constant>CURLOPT_MAXREDIRS</constant> is set).
192
+
part of the HTTP header.
193
+
See also <constant>CURLOPT_MAXREDIRS</constant>.
159
194
</entry>
160
195
<entry valign="top">
161
196
</entry>
...
...
@@ -223,7 +258,7 @@
223
258
the number of small packets on the network.
224
259
</entry>
225
260
<entry valign="top">
226
-
Available since PHP 5.2.1 for versions compiled with libcurl 7.11.2 or
261
+
Available for versions compiled with libcurl 7.11.2 or
227
262
greater.
228
263
</entry>
229
264
</row>
...
...
@@ -259,11 +294,21 @@
259
294
&true; to track the handle's request string.
260
295
</entry>
261
296
<entry valign="top">
262
-
Available since PHP 5.1.3. The <constant>CURLINFO_</constant>
297
+
The <constant>CURLINFO_</constant>
263
298
prefix is intentional.
264
299
</entry>
265
300
</row>
266
301
<row>
302
+
<entry valign="top"><constant>CURLOPT_HTTP09_ALLOWED</constant></entry>
303
+
<entry valign="top">
304
+
Whether to allow HTTP/0.9 responses. Defaults to &false; as of libcurl 7.66.0;
305
+
formerly it defaulted to &true;.
306
+
</entry>
307
+
<entry valign="top">
308
+
Available since PHP 7.3.15 and 7.4.3, respectively, if built against libcurl &gt;= 7.64.0
309
+
</entry>
310
+
</row>
311
+
<row>
267
312
<entry valign="top"><constant>CURLOPT_HTTPGET</constant></entry>
268
313
<entry valign="top">
269
314
&true; to reset the HTTP request method to GET.
...
...
@@ -282,6 +327,27 @@
282
327
</entry>
283
328
</row>
284
329
<row>
330
+
<entry valign="top"><constant>CURLOPT_HTTP_CONTENT_DECODING</constant></entry>
331
+
<entry valign="top">
332
+
&false; to get the raw HTTP response body.
333
+
</entry>
334
+
<entry valign="top">
335
+
Available if built against libcurl &gt;= 7.16.2.
336
+
</entry>
337
+
</row>
338
+
<row>
339
+
<entry valign="top"><constant>CURLOPT_KEEP_SENDING_ON_ERROR</constant></entry>
340
+
<entry valign="top">
341
+
&true; to keep sending the request body if the HTTP code returned is
342
+
equal to or larger than 300. The default action would be to stop sending
343
+
and close the stream or connection. Suitable for manual NTLM authentication.
344
+
Most applications do not need this option.
345
+
</entry>
346
+
<entry valign="top">
347
+
Available as of PHP 7.3.0 if built against libcurl &gt;= 7.51.0.
348
+
</entry>
349
+
</row>
350
+
<row>
285
351
<entry valign="top"><constant>CURLOPT_MUTE</constant></entry>
286
352
<entry valign="top">
287
353
&true; to be completely silent with regards to
...
...
@@ -337,6 +403,24 @@
337
403
</entry>
338
404
</row>
339
405
<row>
406
+
<entry valign="top"><constant>CURLOPT_PATH_AS_IS</constant></entry>
407
+
<entry valign="top">
408
+
&true; to not handle dot dot sequences.
409
+
</entry>
410
+
<entry valign="top">
411
+
Added in cURL 7.42.0. Available since PHP 7.0.7.
412
+
</entry>
413
+
</row>
414
+
<row>
415
+
<entry valign="top"><constant>CURLOPT_PIPEWAIT</constant></entry>
416
+
<entry valign="top">
417
+
&true; to wait for pipelining/multiplexing.
418
+
</entry>
419
+
<entry valign="top">
420
+
Added in cURL 7.43.0. Available since PHP 7.0.7.
421
+
</entry>
422
+
</row>
423
+
<row>
340
424
<entry valign="top"><constant>CURLOPT_POST</constant></entry>
341
425
<entry valign="top">
342
426
&true; to do a regular HTTP POST. This POST is the
...
...
@@ -361,23 +445,40 @@
361
445
<entry valign="top">
362
446
&true; to return the transfer as a string of the
363
447
return value of <function>curl_exec</function> instead of outputting
364
-
it out directly.
448
+
it directly.
365
449
</entry>
366
450
<entry valign="top">
367
451
</entry>
368
452
</row>
369
453
<row>
370
-
<entry valign="top"><constant>CURLOPT_SAFE_UPLOAD</constant></entry>
454
+
<entry valign="top"><constant>CURLOPT_SASL_IR</constant></entry>
371
455
<entry valign="top">
372
-
&true; to disable support for the <literal>@</literal> prefix for
373
-
uploading files in <constant>CURLOPT_POSTFIELDS</constant>, which
374
-
means that values starting with <literal>@</literal> can be safely
375
-
passed as fields. <classname>CURLFile</classname> may be used for
376
-
uploads instead.
456
+
&true; to enable sending the initial response in the first packet.
457
+
</entry>
458
+
<entry valign="top">
459
+
Added in cURL 7.31.10. Available since PHP 7.0.7.
460
+
</entry>
461
+
</row>
462
+
<row>
463
+
<entry valign="top"><constant>CURLOPT_SSL_ENABLE_ALPN</constant></entry>
464
+
<entry valign="top">
465
+
&false; to disable ALPN in the SSL handshake (if the SSL backend
466
+
libcurl is built to use supports it), which can be used to
467
+
negotiate http2.
468
+
</entry>
469
+
<entry valign="top">
470
+
Added in cURL 7.36.0. Available since PHP 7.0.7.
471
+
</entry>
472
+
</row>
473
+
<row>
474
+
<entry valign="top"><constant>CURLOPT_SSL_ENABLE_NPN</constant></entry>
475
+
<entry valign="top">
476
+
&false; to disable NPN in the SSL handshake (if the SSL backend
477
+
libcurl is built to use supports it), which can be used to
478
+
negotiate http2.
377
479
</entry>
378
480
<entry valign="top">
379
-
Added in PHP 5.5.0 with &false; as the default value. PHP 5.6.0
380
-
changes the default value to &true;.
481
+
Added in cURL 7.36.0. Available since PHP 7.0.7.
381
482
</entry>
382
483
</row>
383
484
<row>
...
...
@@ -395,11 +496,75 @@
395
496
</entry>
396
497
</row>
397
498
<row>
499
+
<entry valign="top"><constant>CURLOPT_SSL_VERIFYSTATUS</constant></entry>
500
+
<entry valign="top">
501
+
&true; to verify the certificate's status.
502
+
</entry>
503
+
<entry valign="top">
504
+
Added in cURL 7.41.0. Available since PHP 7.0.7.
505
+
</entry>
506
+
</row>
507
+
<row>
508
+
<entry valign="top"><constant>CURLOPT_PROXY_SSL_VERIFYPEER</constant></entry>
509
+
<entry valign="top">
510
+
&false; to stop cURL from verifying the peer's certificate.
511
+
Alternate certificates to verify against can be
512
+
specified with the <constant>CURLOPT_CAINFO</constant> option
513
+
or a certificate directory can be specified with the
514
+
<constant>CURLOPT_CAPATH</constant> option.
515
+
When set to false, the peer certificate verification succeeds regardless.
516
+
</entry>
517
+
<entry valign="top">
518
+
&true; by default. Available since PHP 7.3.0 and libcurl &gt;= cURL 7.52.0.
519
+
</entry>
520
+
</row>
521
+
<row>
522
+
<entry valign="top"><constant>CURLOPT_SAFE_UPLOAD</constant></entry>
523
+
<entry valign="top">
524
+
Always &true;, what disables support for the <literal>@</literal> prefix for
525
+
uploading files in <constant>CURLOPT_POSTFIELDS</constant>, which
526
+
means that values starting with <literal>@</literal> can be safely
527
+
passed as fields. <classname>CURLFile</classname> may be used for
528
+
uploads instead.
529
+
</entry>
530
+
<entry valign="top">
531
+
</entry>
532
+
</row>
533
+
<row>
534
+
<entry valign="top"><constant>CURLOPT_SUPPRESS_CONNECT_HEADERS</constant></entry>
535
+
<entry valign="top">
536
+
&true; to suppress proxy CONNECT response headers from the user callback functions
537
+
<constant>CURLOPT_HEADERFUNCTION</constant> and <constant>CURLOPT_WRITEFUNCTION</constant>,
538
+
when <constant>CURLOPT_HTTPPROXYTUNNEL</constant> is used and a CONNECT request is made.
539
+
</entry>
540
+
<entry valign="top">
541
+
Added in cURL 7.54.0. Available since PHP 7.3.0.
542
+
</entry>
543
+
</row>
544
+
<row>
545
+
<entry valign="top"><constant>CURLOPT_TCP_FASTOPEN</constant></entry>
546
+
<entry valign="top">
547
+
&true; to enable TCP Fast Open.
548
+
</entry>
549
+
<entry valign="top">
550
+
Added in cURL 7.49.0. Available since PHP 7.0.7.
551
+
</entry>
552
+
</row>
553
+
<row>
554
+
<entry valign="top"><constant>CURLOPT_TFTP_NO_OPTIONS</constant></entry>
555
+
<entry valign="top">
556
+
&true; to not send TFTP options requests.
557
+
</entry>
558
+
<entry valign="top">
559
+
Added in cURL 7.48.0. Available since PHP 7.0.7.
560
+
</entry>
561
+
</row>
562
+
<row>
398
563
<entry valign="top"><constant>CURLOPT_TRANSFERTEXT</constant></entry>
399
564
<entry valign="top">
400
565
&true; to use ASCII mode for FTP transfers.
401
566
For LDAP, it retrieves data in plain text instead of HTML. On
402
-
Windows systems, it will not set <literal>STDOUT</literal> to binary
567
+
Windows systems, it will not set <constant>STDOUT</constant> to binary
403
568
mode.
404
569
</entry>
405
570
<entry valign="top">
...
...
@@ -428,7 +593,7 @@
428
593
<entry valign="top"><constant>CURLOPT_VERBOSE</constant></entry>
429
594
<entry valign="top">
430
595
&true; to output verbose information. Writes
431
-
output to <literal>STDERR</literal>, or the file specified using
596
+
output to <constant>STDERR</constant>, or the file specified using
432
597
<constant>CURLOPT_STDERR</constant>.
433
598
</entry>
434
599
<entry valign="top">
...
...
@@ -439,7 +604,7 @@
439
604
</informaltable>
440
605
</para>
441
606
<para>
442
-
<parameter>value</parameter> should be an <type>integer</type> for the
607
+
<parameter>value</parameter> should be an <type>int</type> for the
443
608
following values of the <parameter>option</parameter> parameter:
444
609
<informaltable>
445
610
<tgroup cols="3">
...
...
@@ -462,21 +627,6 @@
462
627
</entry>
463
628
</row>
464
629
<row>
465
-
<entry valign="top"><constant>CURLOPT_CLOSEPOLICY</constant></entry>
466
-
<entry valign="top">
467
-
One of the <constant>CURLCLOSEPOLICY_*</constant> values.
468
-
<note>
469
-
<para>
470
-
This option is deprecated, as it was never implemented in cURL and
471
-
never had any effect.
472
-
</para>
473
-
</note>
474
-
</entry>
475
-
<entry valign="top">
476
-
Removed in PHP 5.6.0.
477
-
</entry>
478
-
</row>
479
-
<row>
480
630
<entry><constant>CURLOPT_CONNECTTIMEOUT</constant></entry>
481
631
<entry valign="top">
482
632
The number of seconds to wait while trying to connect. Use 0 to
...
...
@@ -496,7 +646,7 @@
496
646
timeouts with a minimum timeout allowed of one second.
497
647
</entry>
498
648
<entry valign="top">
499
-
Added in cURL 7.16.2. Available since PHP 5.2.3.
649
+
Added in cURL 7.16.2.
500
650
</entry>
501
651
</row>
502
652
<row>
...
...
@@ -509,24 +659,100 @@
509
659
</entry>
510
660
</row>
511
661
<row>
662
+
<entry valign="top"><constant>CURLOPT_EXPECT_100_TIMEOUT_MS</constant></entry>
663
+
<entry valign="top">
664
+
The timeout for <literal>Expect: 100-continue</literal> responses in milliseconds.
665
+
Defaults to 1000 milliseconds.
666
+
</entry>
667
+
<entry valign="top">
668
+
Added in cURL 7.36.0. Available since PHP 7.0.7.
669
+
</entry>
670
+
</row>
671
+
<row>
672
+
<entry valign="top"><constant>CURLOPT_HAPPY_EYEBALLS_TIMEOUT_MS</constant></entry>
673
+
<entry valign="top">
674
+
Head start for ipv6 for the happy eyeballs algorithm. Happy eyeballs attempts
675
+
to connect to both IPv4 and IPv6 addresses for dual-stack hosts,
676
+
preferring IPv6 first for timeout milliseconds.
677
+
Defaults to CURL_HET_DEFAULT, which is currently 200 milliseconds.
678
+
</entry>
679
+
<entry valign="top">
680
+
Added in cURL 7.59.0. Available since PHP 7.3.0.
681
+
</entry>
682
+
</row>
683
+
<row>
512
684
<entry valign="top"><constant>CURLOPT_FTPSSLAUTH</constant></entry>
513
685
<entry valign="top">
514
686
The FTP authentication method (when is activated):
515
-
<literal>CURLFTPAUTH_SSL</literal> (try SSL first),
516
-
<literal>CURLFTPAUTH_TLS</literal> (try TLS first), or
517
-
<literal>CURLFTPAUTH_DEFAULT</literal> (let cURL decide).
687
+
<constant>CURLFTPAUTH_SSL</constant> (try SSL first),
688
+
<constant>CURLFTPAUTH_TLS</constant> (try TLS first), or
689
+
<constant>CURLFTPAUTH_DEFAULT</constant> (let cURL decide).
518
690
</entry>
519
691
<entry valign="top">
520
692
Added in cURL 7.12.2.
521
693
</entry>
522
694
</row>
523
695
<row>
696
+
<entry valign="top"><constant>CURLOPT_HEADEROPT</constant></entry>
697
+
<entry valign="top">
698
+
<para>
699
+
How to deal with headers.
700
+
One of the following constants:
701
+
<variablelist>
702
+
<varlistentry>
703
+
<term>CURLHEADER_UNIFIED</term>
704
+
<listitem>
705
+
<simpara>
706
+
The headers specified in
707
+
<constant>CURLOPT_HTTPHEADER</constant>
708
+
will be used in requests both to servers and proxies.
709
+
With this option enabled,
710
+
<constant>CURLOPT_PROXYHEADER</constant>
711
+
will not have any effect.
712
+
</simpara>
713
+
</listitem>
714
+
</varlistentry>
715
+
<varlistentry>
716
+
<term>CURLHEADER_SEPARATE</term>
717
+
<listitem>
718
+
<simpara>
719
+
Makes <constant>CURLOPT_HTTPHEADER</constant>
720
+
headers only get sent to a server and not to a proxy.
721
+
Proxy headers must be set with
722
+
<constant>CURLOPT_PROXYHEADER</constant>
723
+
to get used.
724
+
Note that if a non-CONNECT request is sent to a proxy,
725
+
libcurl will send both server headers and proxy headers.
726
+
When doing CONNECT, libcurl will send
727
+
<constant>CURLOPT_PROXYHEADER</constant>
728
+
headers only to the proxy and then
729
+
<constant>CURLOPT_HTTPHEADER</constant>
730
+
headers only to the server.
731
+
</simpara>
732
+
</listitem>
733
+
</varlistentry>
734
+
</variablelist>
735
+
</para>
736
+
<simpara>
737
+
Defaults to <constant>CURLHEADER_SEPARATE</constant> as of cURL
738
+
7.42.1, and <constant>CURLHEADER_UNIFIED</constant> before.
739
+
</simpara>
740
+
</entry>
741
+
<entry valign="top">
742
+
Added in cURL 7.37.0. Available since PHP 7.0.7.
743
+
</entry>
744
+
</row>
745
+
<row>
524
746
<entry valign="top"><constant>CURLOPT_HTTP_VERSION</constant></entry>
525
747
<entry valign="top">
526
-
<parameter>CURL_HTTP_VERSION_NONE</parameter> (default, lets CURL
748
+
<constant>CURL_HTTP_VERSION_NONE</constant> (default, lets CURL
527
749
decide which version to use),
528
-
<parameter>CURL_HTTP_VERSION_1_0</parameter> (forces HTTP/1.0),
529
-
or <parameter>CURL_HTTP_VERSION_1_1</parameter> (forces HTTP/1.1).
750
+
<constant>CURL_HTTP_VERSION_1_0</constant> (forces HTTP/1.0),
751
+
<constant>CURL_HTTP_VERSION_1_1</constant> (forces HTTP/1.1),
752
+
<constant>CURL_HTTP_VERSION_2_0</constant> (attempts HTTP 2),
753
+
<constant>CURL_HTTP_VERSION_2</constant> (alias of <constant>CURL_HTTP_VERSION_2_0</constant>),
754
+
<constant>CURL_HTTP_VERSION_2TLS</constant> (attempts HTTP 2 over TLS (HTTPS) only) or
755
+
<constant>CURL_HTTP_VERSION_2_PRIOR_KNOWLEDGE</constant> (issues non-TLS HTTP requests using HTTP/2 without HTTP/1.1 Upgrade).
530
756
</entry>
531
757
<entry valign="top">
532
758
</entry>
...
...
@@ -536,12 +762,13 @@
536
762
<entry valign="top">
537
763
<para>
538
764
The HTTP authentication method(s) to use. The options are:
539
-
<parameter>CURLAUTH_BASIC</parameter>,
540
-
<parameter>CURLAUTH_DIGEST</parameter>,
541
-
<parameter>CURLAUTH_GSSNEGOTIATE</parameter>,
542
-
<parameter>CURLAUTH_NTLM</parameter>,
543
-
<parameter>CURLAUTH_ANY</parameter>, and
544
-
<parameter>CURLAUTH_ANYSAFE</parameter>.
765
+
<constant>CURLAUTH_BASIC</constant>,
766
+
<constant>CURLAUTH_DIGEST</constant>,
767
+
<constant>CURLAUTH_GSSNEGOTIATE</constant>,
768
+
<constant>CURLAUTH_NTLM</constant>,
769
+
<constant>CURLAUTH_AWS_SIGV4</constant>,
770
+
<constant>CURLAUTH_ANY</constant>, and
771
+
<constant>CURLAUTH_ANYSAFE</constant>.
545
772
</para>
546
773
<para>
547
774
The bitwise <literal>|</literal> (or) operator can be used to combine
...
...
@@ -549,12 +776,12 @@
549
776
what methods it supports and pick the best one.
550
777
</para>
551
778
<para>
552
-
<parameter>CURLAUTH_ANY</parameter> is an alias for
553
-
<literal>CURLAUTH_BASIC | CURLAUTH_DIGEST | CURLAUTH_GSSNEGOTIATE | CURLAUTH_NTLM</literal>.
779
+
<constant>CURLAUTH_ANY</constant> sets all bits. cURL will automatically select
780
+
the one it finds most secure.
554
781
</para>
555
782
<para>
556
-
<parameter>CURLAUTH_ANYSAFE</parameter> is an alias for
557
-
<literal>CURLAUTH_DIGEST | CURLAUTH_GSSNEGOTIATE | CURLAUTH_NTLM</literal>.
783
+
<constant>CURLAUTH_ANYSAFE</constant> sets all bits except <constant>CURLAUTH_BASIC</constant>.
784
+
cURL will automatically select the one it finds most secure.
558
785
</para>
559
786
</entry>
560
787
<entry valign="top">
...
...
@@ -592,12 +819,56 @@
592
819
</entry>
593
820
</row>
594
821
<row>
822
+
<entry valign="top"><constant>CURLOPT_MAIL_RCPT_ALLLOWFAILS</constant></entry>
823
+
<entry valign="top">
824
+
Allow RCPT TO command to fail for some recipients.
825
+
</entry>
826
+
<entry valign="top">
827
+
When sending data to multiple recipients, by default cURL will abort SMTP conversation if at least one of
828
+
the recipients causes RCPT TO command to return an error. This option tells cURL to ignore errors and
829
+
proceed with the remaining valid recipients. If all recipients trigger RCPT TO failures and this flag is
830
+
set, cURL will abort the SMTP conversation and return the error received from the last RCPT TO command.
831
+
</entry>
832
+
<entry valign="top">
833
+
</entry>
834
+
</row>
835
+
<row>
836
+
<entry valign="top"><constant>CURLOPT_MAXAGE_CONN</constant></entry>
837
+
<entry valign="top">
838
+
The maximum idle time allowed for an existing connection to be considered for reuse.
839
+
Default maximum age is set to <literal>118</literal> seconds.
840
+
</entry>
841
+
<entry valign="top">
842
+
</entry>
843
+
</row>
844
+
<row>
845
+
<entry valign="top"><constant>CURLOPT_MAXFILESIZE_LARGE</constant></entry>
846
+
<entry valign="top">
847
+
The maximum file size in bytes allowed to download. If the file requested is found larger than this value,
848
+
the transfer will not start and <constant>CURLE_FILESIZE_EXCEEDED</constant> will be returned.
849
+
The file size is not always known prior to download, and for such files this option has no effect even if
850
+
the file transfer ends up being larger than this given limit.
851
+
</entry>
852
+
<entry valign="top">
853
+
</entry>
854
+
</row>
855
+
<row>
856
+
<entry valign="top"><constant>CURLOPT_MAXLIFETIME_CONN</constant></entry>
857
+
<entry valign="top">
858
+
The maximum time in seconds, since the creation of the connection, that is allowed for an existing
859
+
connection to have for it to be considered for reuse. If a connection is found in the cache that is older
860
+
than this value, it will instead be closed once any in-progress transfers are complete.
861
+
Default is 0 seconds, meaning the option is disabled and all connections are eligible for reuse.
862
+
</entry>
863
+
<entry valign="top">
864
+
</entry>
865
+
</row>
866
+
<row>
595
867
<entry valign="top"><constant>CURLOPT_MAXCONNECTS</constant></entry>
596
868
<entry valign="top">
597
869
The maximum amount of persistent connections that are allowed.
598
-
When the limit is reached,
599
-
<constant>CURLOPT_CLOSEPOLICY</constant> is used to determine
600
-
which connection to close.
870
+
When the limit is reached, the oldest one in the cache is closed
871
+
to prevent increasing the number of open connections.
601
872
</entry>
602
873
<entry valign="top">
603
874
</entry>
...
...
@@ -607,6 +878,9 @@
607
878
<entry valign="top">
608
879
The maximum amount of HTTP redirections to follow. Use this option
609
880
alongside <constant>CURLOPT_FOLLOWLOCATION</constant>.
881
+
Default value of <literal>20</literal> is set to prevent infinite redirects.
882
+
Setting to <literal>-1</literal> allows inifinite redirects, and <literal>0</literal>
883
+
refuses all redirects.
610
884
</entry>
611
885
<entry valign="top">
612
886
</entry>
...
...
@@ -628,7 +902,7 @@
628
902
specific type of redirect occurs.
629
903
</entry>
630
904
<entry valign="top">
631
-
Added in cURL 7.19.1. Available since PHP 5.3.2.
905
+
Added in cURL 7.19.1.
632
906
</entry>
633
907
</row>
634
908
<row>
...
...
@@ -644,19 +918,20 @@
644
918
</para>
645
919
<para>
646
920
Valid protocol options are:
647
-
<parameter>CURLPROTO_HTTP</parameter>,
648
-
<parameter>CURLPROTO_HTTPS</parameter>,
649
-
<parameter>CURLPROTO_FTP</parameter>,
650
-
<parameter>CURLPROTO_FTPS</parameter>,
651
-
<parameter>CURLPROTO_SCP</parameter>,
652
-
<parameter>CURLPROTO_SFTP</parameter>,
653
-
<parameter>CURLPROTO_TELNET</parameter>,
654
-
<parameter>CURLPROTO_LDAP</parameter>,
655
-
<parameter>CURLPROTO_LDAPS</parameter>,
656
-
<parameter>CURLPROTO_DICT</parameter>,
657
-
<parameter>CURLPROTO_FILE</parameter>,
658
-
<parameter>CURLPROTO_TFTP</parameter>,
659
-
<parameter>CURLPROTO_ALL</parameter>
921
+
<constant>CURLPROTO_HTTP</constant>,
922
+
<constant>CURLPROTO_HTTPS</constant>,
923
+
<constant>CURLPROTO_FTP</constant>,
924
+
<constant>CURLPROTO_FTPS</constant>,
925
+
<constant>CURLPROTO_SCP</constant>,
926
+
<constant>CURLPROTO_SFTP</constant>,
927
+
<constant>CURLPROTO_TELNET</constant>,
928
+
<constant>CURLPROTO_LDAP</constant>,
929
+
<constant>CURLPROTO_LDAPS</constant>,
930
+
<constant>CURLPROTO_DICT</constant>,
931
+
<constant>CURLPROTO_FILE</constant>,
932
+
<constant>CURLPROTO_TFTP</constant>,
933
+
<constant>CURLPROTO_MQTT</constant>,
934
+
<constant>CURLPROTO_ALL</constant>
660
935
</para>
661
936
</entry>
662
937
<entry valign="top">
...
...
@@ -669,8 +944,8 @@
669
944
The HTTP authentication method(s) to use for the proxy connection.
670
945
Use the same bitmasks as described in
671
946
<constant>CURLOPT_HTTPAUTH</constant>. For proxy authentication,
672
-
only <parameter>CURLAUTH_BASIC</parameter> and
673
-
<parameter>CURLAUTH_NTLM</parameter> are currently supported.
947
+
only <constant>CURLAUTH_BASIC</constant> and
948
+
<constant>CURLAUTH_NTLM</constant> are currently supported.
674
949
</entry>
675
950
<entry valign="top">
676
951
Added in cURL 7.10.7.
...
...
@@ -723,118 +998,437 @@
723
998
</entry>
724
999
</row>
725
1000
<row>
726
-
<entry valign="top"><constant>CURLOPT_SSL_VERIFYHOST</constant></entry>
1001
+
<entry valign="top"><constant>CURLOPT_SOCKS5_AUTH</constant></entry>
727
1002
<entry valign="top">
728
-
1 to check the existence of a common name in the
729
-
SSL peer certificate. 2 to check the existence of
730
-
a common name and also verify that it matches the hostname
731
-
provided. In production environments the value of this option
732
-
should be kept at 2 (default value).
1003
+
<para>
1004
+
The SOCKS5 authentication method(s) to use. The options are:
1005
+
<constant>CURLAUTH_BASIC</constant>,
1006
+
<constant>CURLAUTH_GSSAPI</constant>,
1007
+
<constant>CURLAUTH_NONE</constant>.
1008
+
</para>
1009
+
<para>
1010
+
The bitwise <literal>|</literal> (or) operator can be used to combine
1011
+
more than one method. If this is done, cURL will poll the server to see
1012
+
what methods it supports and pick the best one.
1013
+
</para>
1014
+
<para>
1015
+
<constant>CURLAUTH_BASIC</constant> allows username/password authentication.
1016
+
</para>
1017
+
<para>
1018
+
<constant>CURLAUTH_GSSAPI</constant> allows GSS-API authentication.
1019
+
</para>
1020
+
<para>
1021
+
<constant>CURLAUTH_NONE</constant> allows no authentication.
1022
+
</para>
1023
+
<para>
1024
+
Defaults to <literal>CURLAUTH_BASIC|CURLAUTH_GSSAPI</literal>.
1025
+
Set the actual username and password with the <constant>CURLOPT_PROXYUSERPWD</constant> option.
1026
+
</para>
733
1027
</entry>
734
1028
<entry valign="top">
735
-
Support for value 1 removed in cURL 7.28.1
1029
+
Available as of 7.3.0 and curl &gt;= 7.55.0.
736
1030
</entry>
737
1031
</row>
738
1032
<row>
739
-
<entry valign="top"><constant>CURLOPT_SSLVERSION</constant></entry>
1033
+
<entry valign="top"><constant>CURLOPT_SSL_OPTIONS</constant></entry>
740
1034
<entry valign="top">
741
-
One of <constant>CURL_SSLVERSION_DEFAULT</constant> (0),
742
-
<constant>CURL_SSLVERSION_TLSv1</constant> (1),
743
-
<constant>CURL_SSLVERSION_SSLv2</constant> (2),
744
-
<constant>CURL_SSLVERSION_SSLv3</constant> (3),
745
-
<constant>CURL_SSLVERSION_TLSv1_0</constant> (4),
746
-
<constant>CURL_SSLVERSION_TLSv1_1</constant> (5) or
747
-
<constant>CURL_SSLVERSION_TLSv1_2</constant> (6).
748
-
<note>
749
-
<para>
750
-
Your best bet is to not set this and let it use the default.
751
-
Setting it to 2 or 3 is very dangerous given the known
752
-
vulnerabilities in SSLv2 and SSLv3.
753
-
</para>
754
-
</note>
1035
+
<para>
1036
+
Set SSL behavior options, which is a bitmask of the following constants:
1037
+
<variablelist>
1038
+
<varlistentry>
1039
+
<term>CURLSSLOPT_ALLOW_BEAST</term>
1040
+
<listitem>
1041
+
<simpara>
1042
+
Do not attempt to use any workarounds for a security flaw
1043
+
in the SSL3 and TLS1.0 protocols.
1044
+
</simpara>
1045
+
</listitem>
1046
+
</varlistentry>
1047
+
<varlistentry>
1048
+
<term>CURLSSLOPT_NO_REVOKE</term>
1049
+
<listitem>
1050
+
<simpara>
1051
+
Disable certificate revocation checks for those SSL backends
1052
+
where such behavior is present.
1053
+
</simpara>
1054
+
</listitem>
1055
+
</varlistentry>
1056
+
<varlistentry>
1057
+
<term>CURLSSLOPT_AUTO_CLIENT_CERT</term>
1058
+
<listitem>
1059
+
<simpara>
1060
+
Automatically locate and use a client certificate for
1061
+
authentication, when requested by the server.
1062
+
This option is only supported for Schannel
1063
+
(the native Windows SSL library).
1064
+
</simpara>
1065
+
</listitem>
1066
+
</varlistentry>
1067
+
<varlistentry>
1068
+
<term>CURLSSLOPT_NATIVE_CA</term>
1069
+
<listitem>
1070
+
<simpara>
1071
+
Use the operating system's native CA store for certificate verification.
1072
+
Works only on Windows when built to use OpenSSL.
1073
+
</simpara>
1074
+
<note>
1075
+
<simpara>
1076
+
This option is experimental and behavior is subject to change.
1077
+
</simpara>
1078
+
</note>
1079
+
</listitem>
1080
+
</varlistentry>
1081
+
<varlistentry>
1082
+
<term>CURLSSLOPT_NO_PARTIALCHAIN</term>
1083
+
<listitem>
1084
+
<simpara>
1085
+
Do not accept "partial" certificate chains, which cURL otherwise does by default.
1086
+
This option is only supported for OpenSSL and will fail the
1087
+
certificate verification if the chain ends with an
1088
+
intermediate certificate and not with a root certificate.
1089
+
</simpara>
1090
+
</listitem>
1091
+
</varlistentry>
1092
+
<varlistentry>
1093
+
<term>CURLSSLOPT_REVOKE_BEST_EFFORT</term>
1094
+
<listitem>
1095
+
<simpara>
1096
+
Ignore certificate revocation checks in case of missing
1097
+
or offline distribution points for those SSL backends where
1098
+
such behavior is present.
1099
+
This option is only supported for Schannel
1100
+
(the native Windows SSL library).
1101
+
</simpara>
1102
+
<note>
1103
+
<simpara>
1104
+
If combined with <constant>CURLSSLOPT_NO_REVOKE</constant>,
1105
+
the latter takes precedence.
1106
+
</simpara>
1107
+
</note>
1108
+
</listitem>
1109
+
</varlistentry>
1110
+
</variablelist>
1111
+
</para>
755
1112
</entry>
756
1113
<entry valign="top">
1114
+
Added in cURL 7.25.0. Available since PHP 7.0.7.
757
1115
</entry>
758
1116
</row>
759
1117
<row>
760
-
<entry valign="top"><constant>CURLOPT_TIMECONDITION</constant></entry>
1118
+
<entry valign="top"><constant>CURLOPT_SSL_VERIFYHOST</constant></entry>
761
1119
<entry valign="top">
762
-
How <constant>CURLOPT_TIMEVALUE</constant> is treated.
763
-
Use <parameter>CURL_TIMECOND_IFMODSINCE</parameter> to return the
764
-
page only if it has been modified since the time specified in
765
-
<constant>CURLOPT_TIMEVALUE</constant>. If it hasn't been modified,
766
-
a <literal>"304 Not Modified"</literal> header will be returned
767
-
assuming <constant>CURLOPT_HEADER</constant> is &true;.
768
-
Use <parameter>CURL_TIMECOND_IFUNMODSINCE</parameter> for the reverse
769
-
effect. <parameter>CURL_TIMECOND_IFMODSINCE</parameter> is the
770
-
default.
1120
+
<literal>2</literal> to verify that a Common Name field or a Subject Alternate Name
1121
+
field in the SSL peer certificate matches the provided hostname.
1122
+
<literal>0</literal> to not check the names.
1123
+
<literal>1</literal> should not be used.
1124
+
In production environments the value of this option
1125
+
should be kept at <literal>2</literal> (default value).
771
1126
</entry>
772
1127
<entry valign="top">
1128
+
Support for value <literal>1</literal> removed in cURL 7.28.1.
773
1129
</entry>
774
1130
</row>
775
1131
<row>
776
-
<entry valign="top"><constant>CURLOPT_TIMEOUT</constant></entry>
1132
+
<entry valign="top"><constant>CURLOPT_SSLVERSION</constant></entry>
777
1133
<entry valign="top">
778
-
The maximum number of seconds to allow cURL functions to execute.
1134
+
<para>
1135
+
One of
1136
+
<simplelist type="inline">
1137
+
<member><constant>CURL_SSLVERSION_DEFAULT</constant></member>
1138
+
<member><constant>CURL_SSLVERSION_TLSv1</constant></member>
1139
+
<member><constant>CURL_SSLVERSION_SSLv2</constant></member>
1140
+
<member><constant>CURL_SSLVERSION_SSLv3</constant></member>
1141
+
<member><constant>CURL_SSLVERSION_TLSv1_0</constant></member>
1142
+
<member><constant>CURL_SSLVERSION_TLSv1_1</constant></member>
1143
+
<member><constant>CURL_SSLVERSION_TLSv1_2</constant></member>
1144
+
<member><constant>CURL_SSLVERSION_TLSv1_3</constant></member>
1145
+
</simplelist>
1146
+
.
1147
+
</para>
1148
+
<simpara>
1149
+
The maximum TLS version can be set by using one of the
1150
+
<constant>CURL_SSLVERSION_MAX_<replaceable>*</replaceable></constant>
1151
+
constants.
1152
+
</simpara>
1153
+
<para>
1154
+
It is also possible to bitwise OR one of the
1155
+
<constant>CURL_SSLVERSION_<replaceable>*</replaceable></constant>
1156
+
constants with one of the
1157
+
<constant>CURL_SSLVERSION_MAX_<replaceable>*</replaceable></constant>.
1158
+

1159
+
<simplelist type="inline">
1160
+
<member><constant>CURL_SSLVERSION_MAX_DEFAULT</constant> (the maximum version supported by the library)</member>
1161
+
<member><constant>CURL_SSLVERSION_MAX_TLSv1_0</constant></member>
1162
+
<member><constant>CURL_SSLVERSION_MAX_TLSv1_1</constant></member>
1163
+
<member><constant>CURL_SSLVERSION_MAX_TLSv1_2</constant></member>
1164
+
<member><constant>CURL_SSLVERSION_MAX_TLSv1_3</constant></member>
1165
+
</simplelist>
1166
+
.
1167
+
</para>
1168
+
<warning>
1169
+
<simpara>
1170
+
It is better to not set this option and leave the defaults.
1171
+
As setting this to
1172
+
<constant>CURL_SSLVERSION_SSLv2</constant>
1173
+
or
1174
+
<constant>CURL_SSLVERSION_SSLv3</constant>
1175
+
is very dangerous, given the known
1176
+
vulnerabilities in SSLv2 and SSLv3.
1177
+
</simpara>
1178
+
</warning>
779
1179
</entry>
780
1180
<entry valign="top">
781
1181
</entry>
782
1182
</row>
783
1183
<row>
784
-
<entry valign="top"><constant>CURLOPT_TIMEOUT_MS</constant></entry>
1184
+
<entry valign="top"><constant>CURLOPT_PROXY_SSL_OPTIONS</constant></entry>
785
1185
<entry valign="top">
786
-
The maximum number of milliseconds to allow cURL functions to
787
-
execute.
788
-
<!-- http://curl.haxx.se/libcurl/c/curl_easy_setopt.html -->
789
-
If libcurl is built to use the standard system name resolver, that
790
-
portion of the connect will still use full-second resolution for
791
-
timeouts with a minimum timeout allowed of one second.
1186
+
<para>
1187
+
Set proxy SSL behavior options, which is a bitmask of the following constants:
1188
+
<variablelist>
1189
+
<varlistentry>
1190
+
<term>CURLSSLOPT_ALLOW_BEAST</term>
1191
+
<listitem>
1192
+
<simpara>
1193
+
Do not attempt to use any workarounds for a security flaw
1194
+
in the SSL3 and TLS1.0 protocols.
1195
+
</simpara>
1196
+
</listitem>
1197
+
</varlistentry>
1198
+
<varlistentry>
1199
+
<term>CURLSSLOPT_NO_REVOKE</term>
1200
+
<listitem>
1201
+
<simpara>
1202
+
Disable certificate revocation checks for those SSL backends
1203
+
where such behavior is present. (curl &gt;= 7.44.0)
1204
+
</simpara>
1205
+
</listitem>
1206
+
</varlistentry>
1207
+
<varlistentry>
1208
+
<term>CURLSSLOPT_NO_PARTIALCHAIN</term>
1209
+
<listitem>
1210
+
<simpara>
1211
+
Do not accept "partial" certificate chains,
1212
+
which it otherwise does by default. (curl &gt;= 7.68.0)
1213
+
</simpara>
1214
+
</listitem>
1215
+
</varlistentry>
1216
+
</variablelist>
1217
+
</para>
792
1218
</entry>
793
1219
<entry valign="top">
794
-
Added in cURL 7.16.2. Available since PHP 5.2.3.
1220
+
Available since PHP 7.3.0 and libcurl &gt;= cURL 7.52.0.
795
1221
</entry>
796
1222
</row>
797
1223
<row>
798
-
<entry valign="top"><constant>CURLOPT_TIMEVALUE</constant></entry>
1224
+
<entry valign="top"><constant>CURLOPT_PROXY_SSL_VERIFYHOST</constant></entry>
799
1225
<entry valign="top">
800
-
The time in seconds since January 1st, 1970. The time will be used
801
-
by <constant>CURLOPT_TIMECONDITION</constant>. By default,
802
-
<parameter>CURL_TIMECOND_IFMODSINCE</parameter> is used.
1226
+
Set to <literal>2</literal> to verify in the HTTPS proxy's certificate name fields against the proxy name.
1227
+
When set to <literal>0</literal> the connection succeeds regardless of the names used in the certificate.
1228
+
Use that ability with caution!
1229
+
<literal>1</literal> treated as a debug option in curl 7.28.0 and earlier.
1230
+
From curl 7.28.1 to 7.65.3 <constant>CURLE_BAD_FUNCTION_ARGUMENT</constant> is returned.
1231
+
From curl 7.66.0 onwards <literal>1</literal> and <literal>2</literal> is treated as the same value.
1232
+
In production environments the value of this option should be kept at <literal>2</literal> (default value).
803
1233
</entry>
804
1234
<entry valign="top">
1235
+
Available since PHP 7.3.0 and libcurl &gt;= cURL 7.52.0.
805
1236
</entry>
806
1237
</row>
807
1238
<row>
808
-
<entry valign="top"><constant>CURLOPT_MAX_RECV_SPEED_LARGE</constant></entry>
1239
+
<entry valign="top"><constant>CURLOPT_PROXY_SSLVERSION</constant></entry>
809
1240
<entry valign="top">
810
-
If a download exceeds this speed (counted in bytes per second) on
811
-
cumulative average during the transfer, the transfer will pause to
812
-
keep the average rate less than or equal to the parameter value.
813
-
Defaults to unlimited speed.
1241
+
<para>
1242
+
One of
1243
+
<simplelist type="inline">
1244
+
<member><constant>CURL_SSLVERSION_DEFAULT</constant></member>
1245
+
<member><constant>CURL_SSLVERSION_TLSv1</constant></member>
1246
+
<member><constant>CURL_SSLVERSION_TLSv1_0</constant></member>
1247
+
<member><constant>CURL_SSLVERSION_TLSv1_1</constant></member>
1248
+
<member><constant>CURL_SSLVERSION_TLSv1_2</constant></member>
1249
+
<member><constant>CURL_SSLVERSION_TLSv1_3</constant></member>
1250
+
<member><constant>CURL_SSLVERSION_MAX_DEFAULT</constant></member>
1251
+
<member><constant>CURL_SSLVERSION_MAX_TLSv1_0</constant></member>
1252
+
<member><constant>CURL_SSLVERSION_MAX_TLSv1_1</constant></member>
1253
+
<member><constant>CURL_SSLVERSION_MAX_TLSv1_2</constant></member>
1254
+
<member><constant>CURL_SSLVERSION_MAX_TLSv1_3</constant></member>
1255
+
<member><constant>CURL_SSLVERSION_SSLv3</constant></member>
1256
+
</simplelist>
1257
+
.
1258
+
</para>
1259
+
<warning>
1260
+
<simpara>
1261
+
It is better to not set this option and leave the default
1262
+
<constant>CURL_SSLVERSION_DEFAULT</constant>
1263
+
which will attempt to figure out the remote SSL protocol version.
1264
+
</simpara>
1265
+
</warning>
814
1266
</entry>
815
1267
<entry valign="top">
816
-
Added in cURL 7.15.5. Available since PHP 5.4.0.
1268
+
Available since PHP 7.3.0 and libcurl &gt;= cURL 7.52.0.
817
1269
</entry>
818
1270
</row>
819
1271
<row>
820
-
<entry valign="top"><constant>CURLOPT_MAX_SEND_SPEED_LARGE</constant></entry>
1272
+
<entry valign="top"><constant>CURLOPT_STREAM_WEIGHT</constant></entry>
821
1273
<entry valign="top">
822
-
If an upload exceeds this speed (counted in bytes per second) on
823
-
cumulative average during the transfer, the transfer will pause to
824
-
keep the average rate less than or equal to the parameter value.
825
-
Defaults to unlimited speed.
1274
+
Set the numerical stream weight (a number between 1 and 256).
826
1275
</entry>
827
1276
<entry valign="top">
828
-
Added in cURL 7.15.5. Available since PHP 5.4.0.
1277
+
Added in cURL 7.46.0. Available since PHP 7.0.7.
829
1278
</entry>
830
1279
</row>
831
1280
<row>
832
-
<entry valign="top"><constant>CURLOPT_SSH_AUTH_TYPES</constant></entry>
1281
+
<entry valign="top"><constant>CURLOPT_TCP_KEEPALIVE</constant></entry>
833
1282
<entry valign="top">
834
-
A bitmask consisting of one or more of
835
-
<constant>CURLSSH_AUTH_PUBLICKEY</constant>,
836
-
<constant>CURLSSH_AUTH_PASSWORD</constant>,
837
-
<constant>CURLSSH_AUTH_HOST</constant>,
1283
+
If set to <literal>1</literal>, TCP keepalive probes will be sent. The delay and
1284
+
frequency of these probes can be controlled by the <constant>CURLOPT_TCP_KEEPIDLE</constant>
1285
+
and <constant>CURLOPT_TCP_KEEPINTVL</constant> options, provided the operating system
1286
+
supports them. If set to <literal>0</literal> (default) keepalive probes are disabled.
1287
+
</entry>
1288
+
<entry valign="top">
1289
+
Added in cURL 7.25.0.
1290
+
</entry>
1291
+
</row>
1292
+
<row>
1293
+
<entry valign="top"><constant>CURLOPT_TCP_KEEPIDLE</constant></entry>
1294
+
<entry valign="top">
1295
+
Sets the delay, in seconds, that the operating system will wait while the connection is
1296
+
idle before sending keepalive probes, if <constant>CURLOPT_TCP_KEEPALIVE</constant> is
1297
+
enabled. Not all operating systems support this option.
1298
+
The default is <literal>60</literal>.
1299
+
</entry>
1300
+
<entry valign="top">
1301
+
Added in cURL 7.25.0.
1302
+
</entry>
1303
+
</row>
1304
+
<row>
1305
+
<entry valign="top"><constant>CURLOPT_TCP_KEEPINTVL</constant></entry>
1306
+
<entry valign="top">
1307
+
Sets the interval, in seconds, that the operating system will wait between sending
1308
+
keepalive probes, if <constant>CURLOPT_TCP_KEEPALIVE</constant> is enabled.
1309
+
Not all operating systems support this option.
1310
+
The default is <literal>60</literal>.
1311
+
</entry>
1312
+
<entry valign="top">
1313
+
Added in cURL 7.25.0.
1314
+
</entry>
1315
+
</row>
1316
+
<row>
1317
+
<entry valign="top"><constant>CURLOPT_TIMECONDITION</constant></entry>
1318
+
<entry valign="top">
1319
+
How <constant>CURLOPT_TIMEVALUE</constant> is treated.
1320
+
Use <constant>CURL_TIMECOND_IFMODSINCE</constant> to return the
1321
+
page only if it has been modified since the time specified in
1322
+
<constant>CURLOPT_TIMEVALUE</constant>. If it hasn't been modified,
1323
+
a <literal>"304 Not Modified"</literal> header will be returned
1324
+
assuming <constant>CURLOPT_HEADER</constant> is &true;.
1325
+
Use <constant>CURL_TIMECOND_IFUNMODSINCE</constant> for the reverse
1326
+
effect. Use <constant>CURL_TIMECOND_NONE</constant> to ignore
1327
+
<constant>CURLOPT_TIMEVALUE</constant> and always return the page.
1328
+
<constant>CURL_TIMECOND_NONE</constant> is the default.
1329
+
</entry>
1330
+
<entry valign="top">
1331
+
Before cURL 7.46.0 the default was
1332
+
<constant>CURL_TIMECOND_IFMODSINCE</constant>.
1333
+
</entry>
1334
+
</row>
1335
+
<row>
1336
+
<entry valign="top"><constant>CURLOPT_TIMEOUT</constant></entry>
1337
+
<entry valign="top">
1338
+
The maximum number of seconds to allow cURL functions to execute.
1339
+
</entry>
1340
+
<entry valign="top">
1341
+
</entry>
1342
+
</row>
1343
+
<row>
1344
+
<entry valign="top"><constant>CURLOPT_TIMEOUT_MS</constant></entry>
1345
+
<entry valign="top">
1346
+
The maximum number of milliseconds to allow cURL functions to
1347
+
execute.
1348
+
<!-- http://curl.haxx.se/libcurl/c/curl_easy_setopt.html -->
1349
+
If libcurl is built to use the standard system name resolver, that
1350
+
portion of the connect will still use full-second resolution for
1351
+
timeouts with a minimum timeout allowed of one second.
1352
+
</entry>
1353
+
<entry valign="top">
1354
+
Added in cURL 7.16.2.
1355
+
</entry>
1356
+
</row>
1357
+
<row>
1358
+
<entry valign="top"><constant>CURLOPT_TIMEVALUE</constant></entry>
1359
+
<entry valign="top">
1360
+
The time in seconds since January 1st, 1970. The time will be used
1361
+
by <constant>CURLOPT_TIMECONDITION</constant>.
1362
+
</entry>
1363
+
<entry valign="top">
1364
+
</entry>
1365
+
</row>
1366
+
<row>
1367
+
<entry valign="top"><constant>CURLOPT_TIMEVALUE_LARGE</constant></entry>
1368
+
<entry valign="top">
1369
+
The time in seconds since January 1st, 1970. The time will be used
1370
+
by <constant>CURLOPT_TIMECONDITION</constant>. Defaults to zero.
1371
+
The difference between this option and <constant>CURLOPT_TIMEVALUE</constant>
1372
+
is the type of the argument. On systems where 'long' is only 32 bit wide,
1373
+
this option has to be used to set dates beyond the year 2038.
1374
+
</entry>
1375
+
<entry valign="top">
1376
+
Added in cURL 7.59.0. Available since PHP 7.3.0.
1377
+
</entry>
1378
+
</row>
1379
+
<row>
1380
+
<entry valign="top"><constant>CURLOPT_UPKEEP_INTERVAL_MS</constant></entry>
1381
+
<entry valign="top">
1382
+
Some protocols have "connection upkeep" mechanisms. These mechanisms usually send some traffic
1383
+
on existing connections in order to keep them alive. This option defines the connection upkeep interval.
1384
+
Currently, the only protocol with a connection upkeep mechanism is HTTP/2. When the connection upkeep
1385
+
interval is exceeded, an HTTP/2 PING frame is sent on the connection.
1386
+
Default is <literal>60</literal> seconds.
1387
+
</entry>
1388
+
<entry valign="top">
1389
+
</entry>
1390
+
</row>
1391
+
<row>
1392
+
<entry valign="top"><constant>CURLOPT_UPLOAD_BUFFERSIZE</constant></entry>
1393
+
<entry valign="top">
1394
+
Preferred buffer size in bytes for the cURL upload buffer.
1395
+
The upload buffer size by default is 64 kilobytes. The maximum buffer size allowed to be set is 2 megabytes.
1396
+
The minimum buffer size allowed to be set is 16 kilobytes.
1397
+
</entry>
1398
+
<entry valign="top">
1399
+
</entry>
1400
+
</row>
1401
+
<row>
1402
+
<entry valign="top"><constant>CURLOPT_MAX_RECV_SPEED_LARGE</constant></entry>
1403
+
<entry valign="top">
1404
+
If a download exceeds this speed (counted in bytes per second) on
1405
+
cumulative average during the transfer, the transfer will pause to
1406
+
keep the average rate less than or equal to the parameter value.
1407
+
Defaults to unlimited speed.
1408
+
</entry>
1409
+
<entry valign="top">
1410
+
Added in cURL 7.15.5.
1411
+
</entry>
1412
+
</row>
1413
+
<row>
1414
+
<entry valign="top"><constant>CURLOPT_MAX_SEND_SPEED_LARGE</constant></entry>
1415
+
<entry valign="top">
1416
+
If an upload exceeds this speed (counted in bytes per second) on
1417
+
cumulative average during the transfer, the transfer will pause to
1418
+
keep the average rate less than or equal to the parameter value.
1419
+
Defaults to unlimited speed.
1420
+
</entry>
1421
+
<entry valign="top">
1422
+
Added in cURL 7.15.5.
1423
+
</entry>
1424
+
</row>
1425
+
<row>
1426
+
<entry valign="top"><constant>CURLOPT_SSH_AUTH_TYPES</constant></entry>
1427
+
<entry valign="top">
1428
+
A bitmask consisting of one or more of
1429
+
<constant>CURLSSH_AUTH_PUBLICKEY</constant>,
1430
+
<constant>CURLSSH_AUTH_PASSWORD</constant>,
1431
+
<constant>CURLSSH_AUTH_HOST</constant>,
838
1432
<constant>CURLSSH_AUTH_KEYBOARD</constant>. Set to
839
1433
<constant>CURLSSH_AUTH_ANY</constant> to let libcurl pick one.
840
1434
</entry>
...
...
@@ -857,6 +1451,19 @@
857
1451
Added in cURL 7.10.8.
858
1452
</entry>
859
1453
</row>
1454
+
<row>
1455
+
<entry valign="top"><constant>CURLOPT_FTP_FILEMETHOD</constant></entry>
1456
+
<entry valign="top">
1457
+
Tell curl which method to use to reach a file on a FTP(S) server. Possible values are
1458
+
<constant>CURLFTPMETHOD_DEFAULT</constant>,
1459
+
<constant>CURLFTPMETHOD_MULTICWD</constant>,
1460
+
<constant>CURLFTPMETHOD_NOCWD</constant>, and
1461
+
<constant>CURLFTPMETHOD_SINGLECWD</constant>.
1462
+
</entry>
1463
+
<entry valign="top">
1464
+
Added in cURL 7.15.1.
1465
+
</entry>
1466
+
</row>
860
1467
</tbody>
861
1468
</tgroup>
862
1469
</informaltable>
...
...
@@ -875,6 +1482,59 @@
875
1482
</thead>
876
1483
<tbody>
877
1484
<row>
1485
+
<entry valign="top"><constant>CURLOPT_ABSTRACT_UNIX_SOCKET</constant></entry>
1486
+
<entry valign="top">
1487
+
Enables the use of an abstract Unix domain socket instead of
1488
+
establishing a TCP connection to a host and sets the path to
1489
+
the given <type>string</type>. This option shares the same semantics
1490
+
as <constant>CURLOPT_UNIX_SOCKET_PATH</constant>. These two options
1491
+
share the same storage and therefore only one of them can be set
1492
+
per handle.
1493
+
</entry>
1494
+
<entry valign="top">
1495
+
Available since PHP 7.3.0 and cURL 7.53.0
1496
+
</entry>
1497
+
</row>
1498
+
<row>
1499
+
<entry valign="top"><constant>CURLOPT_ALTSVC</constant></entry>
1500
+
<entry valign="top">
1501
+
Pass the filename for cURL to use as the Alt-Svc cache file to read existing cache contents from and
1502
+
possibly also write it back to a after a transfer, unless <constant>CURLALTSVC_READONLYFILE</constant>
1503
+
is set via <constant>CURLOPT_ALTSVC_CTRL</constant>.
1504
+
</entry>
1505
+
<entry valign="top">
1506
+
</entry>
1507
+
</row>
1508
+
<row>
1509
+
<entry valign="top"><constant>CURLOPT_ALTSVC_CTRL</constant></entry>
1510
+
<entry valign="top">
1511
+
Populate the bitmask with the correct set of features to instruct cURL how to handle Alt-Svc for the
1512
+
transfers using this handle. cURL only accepts Alt-Svc headers over HTTPS. It will also only complete
1513
+
a request to an alternative origin if that origin is properly hosted over HTTPS.
1514
+
Setting any bit will enable the alt-svc engine. The options are:
1515
+
<constant>CURLALTSVC_H1</constant>,
1516
+
<constant>CURLALTSVC_H2</constant>,
1517
+
<constant>CURLALTSVC_H3</constant>, and
1518
+
<constant>CURLALTSVC_READONLYFILE</constant>.
1519
+
</entry>
1520
+
<entry valign="top">
1521
+
</entry>
1522
+
</row>
1523
+
<row>
1524
+
<entry valign="top"><constant>CURLOPT_AWS_SIGV4</constant></entry>
1525
+
<entry valign="top">
1526
+
<para>
1527
+
Provides AWS V4 signature authentication on HTTP(S) header.
1528
+
</para>
1529
+
<para>
1530
+
This option overrides any other authentication types that have been set in
1531
+
<constant>CURLOPT_HTTPAUTH</constant>. This method cannot be combined with other authentication types.
1532
+
</para>
1533
+
</entry>
1534
+
<entry valign="top">
1535
+
</entry>
1536
+
</row>
1537
+
<row>
878
1538
<entry valign="top"><constant>CURLOPT_CAINFO</constant></entry>
879
1539
<entry valign="top">
880
1540
The name of a file holding one or more certificates to verify the
...
...
@@ -886,6 +1546,16 @@
886
1546
</entry>
887
1547
</row>
888
1548
<row>
1549
+
<entry valign="top"><constant>CURLOPT_CAINFO_BLOB</constant></entry>
1550
+
<entry valign="top">
1551
+
The name of a PEM file holding one or more certificates to verify the
1552
+
peer with. This option overrides <constant>CURLOPT_CAINFO</constant>.
1553
+
</entry>
1554
+
<entry valign="top">
1555
+
Available as of PHP 8.2.0 and cURL 7.77.0
1556
+
</entry>
1557
+
</row>
1558
+
<row>
889
1559
<entry valign="top"><constant>CURLOPT_CAPATH</constant></entry>
890
1560
<entry valign="top">
891
1561
A directory that holds multiple CA certificates. Use this option
...
...
@@ -920,10 +1590,34 @@
920
1590
<row>
921
1591
<entry valign="top"><constant>CURLOPT_COOKIEJAR</constant></entry>
922
1592
<entry valign="top">
923
-
The name of a file to save all internal cookies to when the handle is closed,
924
-
e.g. after a call to curl_close.
1593
+
<simpara>
1594
+
The name of a file to save all internal cookies to when the
1595
+
handle's destructor is called.
1596
+
</simpara>
1597
+
<warning>
1598
+
<simpara>
1599
+
As of PHP 8.0.0, <function>curl_close</function> is a no-op
1600
+
and does <emphasis>not</emphasis> destroy the handle.
1601
+
If cookies need to be written prior to the handle being automatically
1602
+
destroyed, call <function>unset</function> on the handle.
1603
+
</simpara>
1604
+
</warning>
1605
+
</entry>
1606
+
<entry valign="top">
925
1607
</entry>
1608
+
</row>
1609
+
<row>
1610
+
<entry valign="top"><constant>CURLOPT_COOKIELIST</constant></entry>
926
1611
<entry valign="top">
1612
+
A cookie string (i.e. a single line in Netscape/Mozilla format, or a regular
1613
+
HTTP-style Set-Cookie header) adds that single cookie to the internal cookie store.
1614
+
<literal>"ALL"</literal> erases all cookies held in memory.
1615
+
<literal>"SESS"</literal> erases all session cookies held in memory.
1616
+
<literal>"FLUSH"</literal> writes all known cookies to the file specified by <constant>CURLOPT_COOKIEJAR</constant>.
1617
+
<literal>"RELOAD"</literal> loads all cookies from the files specified by <constant>CURLOPT_COOKIEFILE</constant>.
1618
+
</entry>
1619
+
<entry valign="top">
1620
+
Available since cURL 7.14.1.
927
1621
</entry>
928
1622
</row>
929
1623
<row>
...
...
@@ -949,6 +1643,45 @@
949
1643
</entry>
950
1644
</row>
951
1645
<row>
1646
+
<entry valign="top"><constant>CURLOPT_DEFAULT_PROTOCOL</constant></entry>
1647
+
<entry valign="top"><para>
1648
+
The default protocol to use if the URL is missing a scheme name.
1649
+
</para></entry>
1650
+
<entry valign="top">
1651
+
Added in cURL 7.45.0. Available since PHP 7.0.7.
1652
+
</entry>
1653
+
</row>
1654
+
<row>
1655
+
<entry valign="top"><constant>CURLOPT_DNS_INTERFACE</constant></entry>
1656
+
<entry valign="top"><para>
1657
+
Set the name of the network interface that the DNS resolver should bind to.
1658
+
This must be an interface name (not an address).
1659
+
</para></entry>
1660
+
<entry valign="top">
1661
+
Added in cURL 7.33.0. Available since PHP 7.0.7.
1662
+
</entry>
1663
+
</row>
1664
+
<row>
1665
+
<entry valign="top"><constant>CURLOPT_DNS_LOCAL_IP4</constant></entry>
1666
+
<entry valign="top"><para>
1667
+
Set the local IPv4 address that the resolver should bind to. The argument
1668
+
should contain a single numerical IPv4 address as a string.
1669
+
</para></entry>
1670
+
<entry valign="top">
1671
+
Added in cURL 7.33.0. Available since PHP 7.0.7.
1672
+
</entry>
1673
+
</row>
1674
+
<row>
1675
+
<entry valign="top"><constant>CURLOPT_DNS_LOCAL_IP6</constant></entry>
1676
+
<entry valign="top"><para>
1677
+
Set the local IPv6 address that the resolver should bind to. The argument
1678
+
should contain a single numerical IPv6 address as a string.
1679
+
</para></entry>
1680
+
<entry valign="top">
1681
+
Added in cURL 7.33.0. Available since PHP 7.0.7.
1682
+
</entry>
1683
+
</row>
1684
+
<row>
952
1685
<entry valign="top"><constant>CURLOPT_EGDSOCKET</constant></entry>
953
1686
<entry valign="top">
954
1687
Like <constant>CURLOPT_RANDOM_FILE</constant>, except a filename
...
...
@@ -984,6 +1717,29 @@
984
1717
</entry>
985
1718
</row>
986
1719
<row>
1720
+
<entry valign="top"><constant>CURLOPT_HSTS</constant></entry>
1721
+
<entry valign="top">
1722
+
<para>
1723
+
HSTS (HTTP Strict Transport Security) cache file name.
1724
+
</para>
1725
+
</entry>
1726
+
<entry valign="top">
1727
+
</entry>
1728
+
</row>
1729
+
<row>
1730
+
<entry valign="top"><constant>CURLOPT_HSTS_CTRL</constant></entry>
1731
+
<entry valign="top">
1732
+
<para>
1733
+
Controls HSTS (HTTP Strict Transport Security) behavior. Populate the bitmask with the correct set of
1734
+
features to instruct cURL how to handle HSTS for the transfers using this handle.
1735
+
<constant>CURLHSTS_ENABLE</constant> enables the in-memory HSTS cache. If the HSTS cache file is defined,
1736
+
set <constant>CURLHSTS_READONLYFILE</constant> to make the file read-only.
1737
+
</para>
1738
+
</entry>
1739
+
<entry valign="top">
1740
+
</entry>
1741
+
</row>
1742
+
<row>
987
1743
<entry valign="top"><constant>CURLOPT_INTERFACE</constant></entry>
988
1744
<entry valign="top">
989
1745
The name of the outgoing network interface to use. This can be an
...
...
@@ -1020,14 +1776,36 @@
1020
1776
</entry>
1021
1777
</row>
1022
1778
<row>
1779
+
<entry valign="top"><constant>CURLOPT_LOGIN_OPTIONS</constant></entry>
1780
+
<entry valign="top">
1781
+
Can be used to set protocol specific login options, such as the
1782
+
preferred authentication mechanism via "AUTH=NTLM" or "AUTH=*",
1783
+
and should be used in conjunction with the
1784
+
<constant>CURLOPT_USERNAME</constant> option.
1785
+
</entry>
1786
+
<entry valign="top">
1787
+
Added in cURL 7.34.0. Available since PHP 7.0.7.
1788
+
</entry>
1789
+
</row>
1790
+
<row>
1791
+
<entry valign="top"><constant>CURLOPT_PINNEDPUBLICKEY</constant></entry>
1792
+
<entry valign="top">
1793
+
Set the pinned public key.
1794
+
The string can be the file name of your pinned public key. The file
1795
+
format expected is "PEM" or "DER". The string can also be any
1796
+
number of base64 encoded sha256 hashes preceded by "sha256//" and
1797
+
separated by ";".
1798
+
</entry>
1799
+
<entry valign="top">
1800
+
Added in cURL 7.39.0. Available since PHP 7.0.7.
1801
+
</entry>
1802
+
</row>
1803
+
<row>
1023
1804
<entry valign="top"><constant>CURLOPT_POSTFIELDS</constant></entry>
1024
1805
<entry valign="top">
1025
1806
<simpara>
1026
1807
The full data to post in a HTTP "POST" operation.
1027
-
To post a file, prepend a filename with <literal>@</literal> and
1028
-
use the full path. The filetype can be explicitly specified by
1029
-
following the filename with the type in the format
1030
-
'<literal>;type=mimetype</literal>'. This parameter can either be
1808
+
This parameter can either be
1031
1809
passed as a urlencoded string like '<literal>para1=val1&amp;para2=val2&amp;...</literal>'
1032
1810
or as an array with the field name as key and field data as value.
1033
1811
If <parameter>value</parameter> is an array, the
...
...
@@ -1035,21 +1813,48 @@
1035
1813
<literal>multipart/form-data</literal>.
1036
1814
</simpara>
1037
1815
<simpara>
1038
-
As of PHP 5.2.0, <parameter>value</parameter> must be an array if
1039
-
files are passed to this option with the <literal>@</literal> prefix.
1040
-
</simpara>
1041
-
<simpara>
1042
-
As of PHP 5.5.0, the <literal>@</literal> prefix is deprecated and
1043
-
files can be sent using <classname>CURLFile</classname>. The
1044
-
<literal>@</literal> prefix can be disabled for safe passing of
1045
-
values beginning with <literal>@</literal> by setting the
1046
-
<constant>CURLOPT_SAFE_UPLOAD</constant> option to &true;.
1816
+
Files can be sent using <classname>CURLFile</classname> or <classname>CURLStringFile</classname>,
1817
+
in which case <parameter>value</parameter> must be an array.
1047
1818
</simpara>
1048
1819
</entry>
1049
1820
<entry valign="top">
1050
1821
</entry>
1051
1822
</row>
1052
1823
<row>
1824
+
<entry valign="top"><constant>CURLOPT_PRIVATE</constant></entry>
1825
+
<entry valign="top">
1826
+
Any data that should be associated with this cURL handle. This data
1827
+
can subsequently be retrieved with the
1828
+
<constant>CURLINFO_PRIVATE</constant> option of
1829
+
<function>curl_getinfo</function>. cURL does nothing with this data.
1830
+
When using a cURL multi handle, this private data is typically a
1831
+
unique key to identify a standard cURL handle.
1832
+
</entry>
1833
+
<entry valign="top">
1834
+
Added in cURL 7.10.3.
1835
+
</entry>
1836
+
</row>
1837
+
<row>
1838
+
<entry valign="top"><constant>CURLOPT_PRE_PROXY</constant></entry>
1839
+
<entry valign="top">
1840
+
Set a <type>string</type> holding the host name or dotted numerical
1841
+
IP address to be used as the preproxy that curl connects to before
1842
+
it connects to the HTTP(S) proxy specified in the
1843
+
<constant>CURLOPT_PROXY</constant> option for the upcoming request.
1844
+
The preproxy can only be a SOCKS proxy and it should be prefixed with
1845
+
<literal>[scheme]://</literal> to specify which kind of socks is used.
1846
+
A numerical IPv6 address must be written within [brackets].
1847
+
Setting the preproxy to an empty string explicitly disables the use of a preproxy.
1848
+
To specify port number in this string, append <literal>:[port]</literal>
1849
+
to the end of the host name. The proxy's port number may optionally be
1850
+
specified with the separate option <constant>CURLOPT_PROXYPORT</constant>.
1851
+
Defaults to using port 1080 for proxies if a port is not specified.
1852
+
</entry>
1853
+
<entry valign="top">
1854
+
Available since PHP 7.3.0 and libcurl &gt;= cURL 7.52.0.
1855
+
</entry>
1856
+
</row>
1857
+
<row>
1053
1858
<entry valign="top"><constant>CURLOPT_PROXY</constant></entry>
1054
1859
<entry valign="top">
1055
1860
The HTTP proxy to tunnel requests through.
...
...
@@ -1058,6 +1863,203 @@
1058
1863
</entry>
1059
1864
</row>
1060
1865
<row>
1866
+
<entry valign="top"><constant>CURLOPT_PROXY_SERVICE_NAME</constant></entry>
1867
+
<entry valign="top">
1868
+
The proxy authentication service name.
1869
+
</entry>
1870
+
<entry valign="top">
1871
+
Added in cURL 7.43.0 for HTTP proxies, and in cURL 7.49.0 for SOCKS5 proxies.
1872
+
Available since PHP 7.0.7.
1873
+
</entry>
1874
+
</row>
1875
+
<row>
1876
+
<entry valign="top"><constant>CURLOPT_PROXY_CAINFO</constant></entry>
1877
+
<entry valign="top">
1878
+
The path to proxy Certificate Authority (CA) bundle. Set the path as a
1879
+
<type>string</type> naming a file holding one or more certificates to
1880
+
verify the HTTPS proxy with.
1881
+
This option is for connecting to an HTTPS proxy, not an HTTPS server.
1882
+
Defaults set to the system path where libcurl's cacert bundle is assumed
1883
+
to be stored.
1884
+
</entry>
1885
+
<entry valign="top">
1886
+
Available since PHP 7.3.0 and libcurl &gt;= cURL 7.52.0.
1887
+
</entry>
1888
+
</row>
1889
+
<row>
1890
+
<entry valign="top"><constant>CURLOPT_PROXY_CAINFO_BLOB</constant></entry>
1891
+
<entry valign="top">
1892
+
The name of a PEM file holding one or more certificates to verify the HTTPS proxy with.
1893
+
This option is for connecting to an HTTPS proxy, not an HTTPS server.
1894
+
Defaults set to the system path where libcurl's cacert bundle is assumed
1895
+
to be stored.
1896
+
</entry>
1897
+
<entry valign="top">
1898
+
Available as of PHP 8.2.0 and libcurl &gt;= cURL 7.77.0.
1899
+
</entry>
1900
+
</row>
1901
+
<row>
1902
+
<entry valign="top"><constant>CURLOPT_PROXY_CAPATH</constant></entry>
1903
+
<entry valign="top">
1904
+
The directory holding multiple CA certificates to verify the HTTPS proxy with.
1905
+
</entry>
1906
+
<entry valign="top">
1907
+
Available since PHP 7.3.0 and libcurl &gt;= cURL 7.52.0.
1908
+
</entry>
1909
+
</row>
1910
+
<row>
1911
+
<entry valign="top"><constant>CURLOPT_PROXY_CRLFILE</constant></entry>
1912
+
<entry valign="top">
1913
+
Set the file name with the concatenation of CRL (Certificate Revocation List)
1914
+
in PEM format to use in the certificate validation that occurs during
1915
+
the SSL exchange.
1916
+
</entry>
1917
+
<entry valign="top">
1918
+
Available since PHP 7.3.0 and libcurl &gt;= cURL 7.52.0.
1919
+
</entry>
1920
+
</row>
1921
+
<row>
1922
+
<entry valign="top"><constant>CURLOPT_PROXY_KEYPASSWD</constant></entry>
1923
+
<entry valign="top">
1924
+
Set the string be used as the password required to use the
1925
+
<constant>CURLOPT_PROXY_SSLKEY</constant> private key. You never needed a
1926
+
passphrase to load a certificate but you need one to load your private key.
1927
+
This option is for connecting to an HTTPS proxy, not an HTTPS server.
1928
+
</entry>
1929
+
<entry valign="top">
1930
+
Available since PHP 7.3.0 and libcurl &gt;= cURL 7.52.0.
1931
+
</entry>
1932
+
</row>
1933
+
<row>
1934
+
<entry valign="top"><constant>CURLOPT_PROXY_PINNEDPUBLICKEY</constant></entry>
1935
+
<entry valign="top">
1936
+
Set the pinned public key for HTTPS proxy. The string can be the file name
1937
+
of your pinned public key. The file format expected is "PEM" or "DER".
1938
+
The string can also be any number of base64 encoded sha256 hashes preceded by
1939
+
"sha256//" and separated by ";"
1940
+
</entry>
1941
+
<entry valign="top">
1942
+
Available since PHP 7.3.0 and libcurl &gt;= cURL 7.52.0.
1943
+
</entry>
1944
+
</row>
1945
+
<row>
1946
+
<entry valign="top"><constant>CURLOPT_PROXY_SSLCERT</constant></entry>
1947
+
<entry valign="top">
1948
+
The file name of your client certificate used to connect to the HTTPS proxy.
1949
+
The default format is "P12" on Secure Transport and "PEM" on other engines,
1950
+
and can be changed with <constant>CURLOPT_PROXY_SSLCERTTYPE</constant>.
1951
+
With NSS or Secure Transport, this can also be the nickname of the certificate
1952
+
you wish to authenticate with as it is named in the security database.
1953
+
If you want to use a file from the current directory, please precede it with
1954
+
"./" prefix, in order to avoid confusion with a nickname.
1955
+
</entry>
1956
+
<entry valign="top">
1957
+
Available since PHP 7.3.0 and libcurl &gt;= cURL 7.52.0.
1958
+
</entry>
1959
+
</row>
1960
+
<row>
1961
+
<entry valign="top"><constant>CURLOPT_PROXY_SSLCERTTYPE</constant></entry>
1962
+
<entry valign="top">
1963
+
The format of your client certificate used when connecting to an HTTPS proxy.
1964
+
Supported formats are "PEM" and "DER", except with Secure Transport.
1965
+
OpenSSL (versions 0.9.3 and later) and Secure Transport
1966
+
(on iOS 5 or later, or OS X 10.7 or later) also support "P12" for
1967
+
PKCS#12-encoded files. Defaults to "PEM".
1968
+
</entry>
1969
+
<entry valign="top">
1970
+
Available since PHP 7.3.0 and libcurl &gt;= cURL 7.52.0.
1971
+
</entry>
1972
+
</row>
1973
+
<row>
1974
+
<entry valign="top"><constant>CURLOPT_PROXY_SSL_CIPHER_LIST</constant></entry>
1975
+
<entry valign="top">
1976
+
The list of ciphers to use for the connection to the HTTPS proxy.
1977
+
The list must be syntactically correct, it consists of one or more cipher
1978
+
strings separated by colons. Commas or spaces are also acceptable separators
1979
+
but colons are normally used, !, - and + can be used as operators.
1980
+
</entry>
1981
+
<entry valign="top">
1982
+
Available since PHP 7.3.0 and libcurl &gt;= cURL 7.52.0.
1983
+
</entry>
1984
+
</row>
1985
+
<row>
1986
+
<entry valign="top"><constant>CURLOPT_PROXY_TLS13_CIPHERS</constant></entry>
1987
+
<entry valign="top">
1988
+
The list of cipher suites to use for the TLS 1.3 connection to a proxy.
1989
+
The list must be syntactically correct, it consists of one or more
1990
+
cipher suite strings separated by colons. This option is currently used
1991
+
only when curl is built to use OpenSSL 1.1.1 or later.
1992
+
If you are using a different SSL backend you can try setting
1993
+
TLS 1.3 cipher suites by using the <constant>CURLOPT_PROXY_SSL_CIPHER_LIST</constant> option.
1994
+
</entry>
1995
+
<entry valign="top">
1996
+
Available since PHP 7.3.0 and libcurl &gt;= cURL 7.61.0. Available when built with OpenSSL &gt;= 1.1.1.
1997
+
</entry>
1998
+
</row>
1999
+
<row>
2000
+
<entry valign="top"><constant>CURLOPT_PROXY_SSLKEY</constant></entry>
2001
+
<entry valign="top">
2002
+
The file name of your private key used for connecting to the HTTPS proxy.
2003
+
The default format is "PEM" and can be changed with
2004
+
<constant>CURLOPT_PROXY_SSLKEYTYPE</constant>.
2005
+
(iOS and Mac OS X only) This option is ignored if curl was built against Secure Transport.
2006
+
</entry>
2007
+
<entry valign="top">
2008
+
Available since PHP 7.3.0 and libcurl &gt;= cURL 7.52.0. Available if built TLS enabled.
2009
+
</entry>
2010
+
</row>
2011
+
<row>
2012
+
<entry valign="top"><constant>CURLOPT_PROXY_SSLKEYTYPE</constant></entry>
2013
+
<entry valign="top">
2014
+
The format of your private key. Supported formats are "PEM", "DER" and "ENG".
2015
+
</entry>
2016
+
<entry valign="top">
2017
+
Available since PHP 7.3.0 and libcurl &gt;= cURL 7.52.0.
2018
+
</entry>
2019
+
</row>
2020
+
<row>
2021
+
<entry valign="top"><constant>CURLOPT_PROXY_TLSAUTH_PASSWORD</constant></entry>
2022
+
<entry valign="top">
2023
+
The password to use for the TLS authentication method specified with the
2024
+
<constant>CURLOPT_PROXY_TLSAUTH_TYPE</constant> option. Requires that the
2025
+
<constant>CURLOPT_PROXY_TLSAUTH_USERNAME</constant> option to also be set.
2026
+
</entry>
2027
+
<entry valign="top">
2028
+
Available since PHP 7.3.0 and libcurl &gt;= cURL 7.52.0.
2029
+
</entry>
2030
+
</row>
2031
+
<row>
2032
+
<entry valign="top"><constant>CURLOPT_PROXY_TLSAUTH_TYPE</constant></entry>
2033
+
<entry valign="top">
2034
+
<simpara>
2035
+
The method of the TLS authentication used for the HTTPS connection.
2036
+
Supported method is <literal>"SRP"</literal>.
2037
+
</simpara>
2038
+
<note>
2039
+
<para>
2040
+
Secure Remote Password (SRP) authentication for TLS provides mutual authentication
2041
+
if both sides have a shared secret. To use TLS-SRP, you must also set the
2042
+
<constant>CURLOPT_PROXY_TLSAUTH_USERNAME</constant> and
2043
+
<constant>CURLOPT_PROXY_TLSAUTH_PASSWORD</constant> options.
2044
+
</para>
2045
+
</note>
2046
+
</entry>
2047
+
<entry valign="top">
2048
+
Available since PHP 7.3.0 and libcurl &gt;= cURL 7.52.0.
2049
+
</entry>
2050
+
</row>
2051
+
<row>
2052
+
<entry valign="top"><constant>CURLOPT_PROXY_TLSAUTH_USERNAME</constant></entry>
2053
+
<entry valign="top">
2054
+
The username to use for the HTTPS proxy TLS authentication method specified with the
2055
+
<constant>CURLOPT_PROXY_TLSAUTH_TYPE</constant> option. Requires that the
2056
+
<constant>CURLOPT_PROXY_TLSAUTH_PASSWORD</constant> option to also be set.
2057
+
</entry>
2058
+
<entry valign="top">
2059
+
Available since PHP 7.3.0 and libcurl &gt;= cURL 7.52.0.
2060
+
</entry>
2061
+
</row>
2062
+
<row>
1061
2063
<entry valign="top"><constant>CURLOPT_PROXYUSERPWD</constant></entry>
1062
2064
<entry valign="top">
1063
2065
A username and password formatted as
...
...
@@ -1096,6 +2098,26 @@
1096
2098
</entry>
1097
2099
</row>
1098
2100
<row>
2101
+
<entry valign="top"><constant>CURLOPT_SASL_AUTHZID</constant></entry>
2102
+
<entry valign="top">
2103
+
The authorization identity (authzid) for the transfer. Only applicable to the PLAIN SASL
2104
+
authentication mechanism where it is optional. When not specified, only the authentication identity
2105
+
(authcid) as specified by the username will be sent to the server, along with the password.
2106
+
The server will derive the authzid from the authcid when not provided, which it will then use internally.
2107
+
</entry>
2108
+
<entry valign="top">
2109
+
</entry>
2110
+
</row>
2111
+
<row>
2112
+
<entry valign="top"><constant>CURLOPT_SERVICE_NAME</constant></entry>
2113
+
<entry valign="top">
2114
+
The authentication service name.
2115
+
</entry>
2116
+
<entry valign="top">
2117
+
Added in cURL 7.43.0. Available since PHP 7.0.7.
2118
+
</entry>
2119
+
</row>
2120
+
<row>
1099
2121
<entry valign="top"><constant>CURLOPT_SSH_HOST_PUBLIC_KEY_MD5</constant></entry>
1100
2122
<entry valign="top">
1101
2123
A string containing 32 hexadecimal digits. The string should be the
...
...
@@ -1108,6 +2130,15 @@
1108
2130
</entry>
1109
2131
</row>
1110
2132
<row>
2133
+
<entry valign="top"><constant>CURLOPT_SSH_HOST_PUBLIC_KEY_SHA256</constant></entry>
2134
+
<entry valign="top">
2135
+
Base64-encoded SHA256 hash of the remote host's public key.
2136
+
The transfer will fail if the given hash does not match the hash the remote host provides.
2137
+
</entry>
2138
+
<entry valign="top">
2139
+
</entry>
2140
+
</row>
2141
+
<row>
1111
2142
<entry valign="top"><constant>CURLOPT_SSH_PUBLIC_KEYFILE</constant></entry>
1112
2143
<entry valign="top">
1113
2144
The file name for your public key. If not used, libcurl defaults to
...
...
@@ -1142,6 +2173,17 @@
1142
2173
</entry>
1143
2174
</row>
1144
2175
<row>
2176
+
<entry valign="top"><constant>CURLOPT_SSL_EC_CURVES</constant></entry>
2177
+
<entry valign="top">
2178
+
A colon delimited list of elliptic curve algorithms. For example,
2179
+
<literal>X25519:P-521</literal> is a valid list of two elliptic curves.
2180
+
This option defines the client's key exchange algorithms in the SSL handshake,
2181
+
if the SSL backend cURL is built to use supports it.
2182
+
</entry>
2183
+
<entry valign="top">
2184
+
</entry>
2185
+
</row>
2186
+
<row>
1145
2187
<entry valign="top"><constant>CURLOPT_SSLCERT</constant></entry>
1146
2188
<entry valign="top">
1147
2189
The name of a file containing a PEM formatted certificate.
...
...
@@ -1164,6 +2206,8 @@
1164
2206
The format of the certificate. Supported formats are
1165
2207
<literal>"PEM"</literal> (default), <literal>"DER"</literal>,
1166
2208
and <literal>"ENG"</literal>.
2209
+
As of OpenSSL 0.9.3, <literal>"P12"</literal> (for PKCS#12-encoded files)
2210
+
is also supported.
1167
2211
</entry>
1168
2212
<entry valign="top">
1169
2213
Added in cURL 7.9.3.
...
...
@@ -1222,6 +2266,29 @@
1222
2266
</entry>
1223
2267
</row>
1224
2268
<row>
2269
+
<entry valign="top"><constant>CURLOPT_TLS13_CIPHERS</constant></entry>
2270
+
<entry valign="top">
2271
+
The list of cipher suites to use for the TLS 1.3 connection. The list must be
2272
+
syntactically correct, it consists of one or more cipher suite strings separated by colons.
2273
+
This option is currently used only when curl is built to use OpenSSL 1.1.1 or later.
2274
+
If you are using a different SSL backend you can try setting
2275
+
TLS 1.3 cipher suites by using the <constant>CURLOPT_SSL_CIPHER_LIST</constant> option.
2276
+
</entry>
2277
+
<entry valign="top">
2278
+
Available since PHP 7.3.0 and libcurl &gt;= cURL 7.61.0. Available when built with OpenSSL &gt;= 1.1.1.
2279
+
</entry>
2280
+
</row>
2281
+
<row>
2282
+
<entry valign="top"><constant>CURLOPT_UNIX_SOCKET_PATH</constant></entry>
2283
+
<entry valign="top">
2284
+
Enables the use of Unix domain sockets as connection endpoint and
2285
+
sets the path to the given <type>string</type>.
2286
+
</entry>
2287
+
<entry valign="top">
2288
+
Added in cURL 7.40.0. Available since PHP 7.0.7.
2289
+
</entry>
2290
+
</row>
2291
+
<row>
1225
2292
<entry valign="top"><constant>CURLOPT_URL</constant></entry>
1226
2293
<entry valign="top">
1227
2294
The URL to fetch. This can also be set when initializing a
...
...
@@ -1240,6 +2307,24 @@
1240
2307
</entry>
1241
2308
</row>
1242
2309
<row>
2310
+
<entry valign="top"><constant>CURLOPT_USERNAME</constant></entry>
2311
+
<entry valign="top">
2312
+
The user name to use in authentication.
2313
+
</entry>
2314
+
<entry valign="top">
2315
+
Added in cURL 7.19.1.
2316
+
</entry>
2317
+
</row>
2318
+
<row>
2319
+
<entry valign="top"><constant>CURLOPT_PASSWORD</constant></entry>
2320
+
<entry valign="top">
2321
+
The password to use in authentication.
2322
+
</entry>
2323
+
<entry valign="top">
2324
+
Added in cURL 7.19.1.
2325
+
</entry>
2326
+
</row>
2327
+
<row>
1243
2328
<entry valign="top"><constant>CURLOPT_USERPWD</constant></entry>
1244
2329
<entry valign="top">
1245
2330
A username and password formatted as
...
...
@@ -1249,6 +2334,15 @@
1249
2334
<entry valign="top">
1250
2335
</entry>
1251
2336
</row>
2337
+
<row>
2338
+
<entry valign="top"><constant>CURLOPT_XOAUTH2_BEARER</constant></entry>
2339
+
<entry valign="top">
2340
+
Specifies the OAuth 2.0 access token.
2341
+
</entry>
2342
+
<entry valign="top">
2343
+
Added in cURL 7.33.0. Available since PHP 7.0.7.
2344
+
</entry>
2345
+
</row>
1252
2346
</tbody>
1253
2347
</tgroup>
1254
2348
</informaltable>
...
...
@@ -1267,6 +2361,17 @@
1267
2361
</thead>
1268
2362
<tbody>
1269
2363
<row>
2364
+
<entry valign="top"><constant>CURLOPT_CONNECT_TO</constant></entry>
2365
+
<entry valign="top">
2366
+
Connect to a specific host and port instead of the URL's host and port.
2367
+
Accepts an array of strings with the format
2368
+
<literal>HOST:PORT:CONNECT-TO-HOST:CONNECT-TO-PORT</literal>.
2369
+
</entry>
2370
+
<entry valign="top">
2371
+
Added in cURL 7.49.0. Available since PHP 7.0.7.
2372
+
</entry>
2373
+
</row>
2374
+
<row>
1270
2375
<entry valign="top"><constant>CURLOPT_HTTP200ALIASES</constant></entry>
1271
2376
<entry valign="top">
1272
2377
An array of HTTP 200 responses that will be treated as valid
...
...
@@ -1297,6 +2402,15 @@
1297
2402
</entry>
1298
2403
</row>
1299
2404
<row>
2405
+
<entry valign="top"><constant>CURLOPT_PROXYHEADER</constant></entry>
2406
+
<entry valign="top">
2407
+
An array of custom HTTP headers to pass to proxies.
2408
+
</entry>
2409
+
<entry valign="top">
2410
+
Added in cURL 7.37.0. Available since PHP 7.0.7.
2411
+
</entry>
2412
+
</row>
2413
+
<row>
1300
2414
<entry valign="top"><constant>CURLOPT_QUOTE</constant></entry>
1301
2415
<entry valign="top">
1302
2416
An array of FTP commands to execute on the server prior to the FTP
...
...
@@ -1305,6 +2419,20 @@
1305
2419
<entry valign="top">
1306
2420
</entry>
1307
2421
</row>
2422
+
<row>
2423
+
<entry valign="top"><constant>CURLOPT_RESOLVE</constant></entry>
2424
+
<entry valign="top">
2425
+
Provide a custom address for a specific host and port pair. An array
2426
+
of hostname, port, and IP address strings, each element separated by
2427
+
a colon. In the format:
2428
+
<code>
2429
+
array("example.com:80:127.0.0.1")
2430
+
</code>
2431
+
</entry>
2432
+
<entry valign="top">
2433
+
Added in cURL 7.21.3.
2434
+
</entry>
2435
+
</row>
1308
2436
</tbody>
1309
2437
</tgroup>
1310
2438
</informaltable>
...
...
@@ -1326,7 +2454,7 @@
1326
2454
<entry valign="top"><constant>CURLOPT_FILE</constant></entry>
1327
2455
<entry valign="top">
1328
2456
The file that the transfer should be written to. The default
1329
-
is <literal>STDOUT</literal> (the browser window).
2457
+
is <constant>STDOUT</constant> (the browser window).
1330
2458
</entry>
1331
2459
</row>
1332
2460
<row>
...
...
@@ -1339,7 +2467,7 @@
1339
2467
<entry valign="top"><constant>CURLOPT_STDERR</constant></entry>
1340
2468
<entry valign="top">
1341
2469
An alternative location to output errors to instead of
1342
-
<literal>STDERR</literal>.
2470
+
<constant>STDERR</constant>.
1343
2471
</entry>
1344
2472
</row>
1345
2473
<row>
...
...
@@ -1361,6 +2489,7 @@
1361
2489
<row>
1362
2490
<entry>Option</entry>
1363
2491
<entry>Set <parameter>value</parameter> to</entry>
2492
+
<entry>Notes</entry>
1364
2493
</row>
1365
2494
</thead>
1366
2495
<tbody>
...
...
@@ -1373,6 +2502,7 @@
1373
2502
be written by this callback. Return the number of
1374
2503
bytes written.
1375
2504
</entry>
2505
+
<entry></entry>
1376
2506
</row>
1377
2507
<row>
1378
2508
<entry valign="top"><constant>CURLOPT_PASSWDFUNCTION</constant></entry>
...
...
@@ -1382,6 +2512,7 @@
1382
2512
string containing a password prompt, and the third is the maximum
1383
2513
password length. Return the string containing the password.
1384
2514
</entry>
2515
+
<entry>Removed as of PHP 7.3.0.</entry>
1385
2516
</row>
1386
2517
<row>
1387
2518
<entry valign="top"><constant>CURLOPT_PROGRESSFUNCTION</constant></entry>
...
...
@@ -1406,6 +2537,7 @@
1406
2537
error.
1407
2538
</para>
1408
2539
</entry>
2540
+
<entry></entry>
1409
2541
</row>
1410
2542
<row>
1411
2543
<entry valign="top"><constant>CURLOPT_READFUNCTION</constant></entry>
...
...
@@ -1419,6 +2551,7 @@
1419
2551
typically by reading it from the passed stream resource. It should
1420
2552
return an empty string to signal <literal>EOF</literal>.
1421
2553
</entry>
2554
+
<entry></entry>
1422
2555
</row>
1423
2556
<row>
1424
2557
<entry valign="top"><constant>CURLOPT_WRITEFUNCTION</constant></entry>
...
...
@@ -1429,6 +2562,18 @@
1429
2562
this callback. It must return the exact number of bytes written
1430
2563
or the transfer will be aborted with an error.
1431
2564
</entry>
2565
+
<entry></entry>
2566
+
</row>
2567
+
<row>
2568
+
<entry valign="top"><constant>CURLOPT_XFERINFOFUNCTION</constant></entry>
2569
+
<entry valign="top">
2570
+
A callback accepting two parameters.
2571
+
Has a similar purpose as <constant>CURLOPT_PROGRESSFUNCTION</constant> but is more modern
2572
+
and the preferred option from cURL.
2573
+
</entry>
2574
+
<entry valign="top">
2575
+
Added in 7.32.0. Available as of PHP 8.2.0.
2576
+
</entry>
1432
2577
</row>
1433
2578
</tbody>
1434
2579
</tgroup>
...
...
@@ -1481,66 +2626,62 @@
1481
2626
</row>
1482
2627
</thead>
1483
2628
<tbody>
2629
+
&curl.changelog.handle-param;
1484
2630
<row>
1485
-
<entry>5.6.0</entry>
1486
-
<entry>
1487
-
<constant>CURLOPT_SAFE_UPLOAD</constant> is now &true; by default.
1488
-
</entry>
1489
-
</row>
1490
-
<row>
1491
-
<entry>5.6.0</entry>
1492
-
<entry>
1493
-
Removed <constant>CURLOPT_CLOSEPOLICY</constant> and associated values.
1494
-
</entry>
1495
-
</row>
1496
-
<row>
1497
-
<entry>5.5.0</entry>
2631
+
<entry>7.3.15, 7.4.3</entry>
1498
2632
<entry>
1499
-
Added the cURL resource as the first argument to the
1500
-
<constant>CURLOPT_PROGRESSFUNCTION</constant> callback.
2633
+
Introduced <constant>CURLOPT_HTTP09_ALLOWED</constant>.
1501
2634
</entry>
1502
2635
</row>
1503
2636
<row>
1504
-
<entry>5.5.0</entry>
2637
+
<entry>7.3.0</entry>
1505
2638
<entry>
1506
-
Introduced <constant>CURLOPT_SHARE</constant>.
2639
+
Introduced <constant>CURLOPT_ABSTRACT_UNIX_SOCKET</constant>, <constant>CURLOPT_KEEP_SENDING_ON_ERROR</constant>,
2640
+
<constant>CURLOPT_PRE_PROXY</constant>, <constant>CURLOPT_PROXY_CAINFO</constant>,
2641
+
<constant>CURLOPT_PROXY_CAPATH</constant>, <constant>CURLOPT_PROXY_CRLFILE</constant>,
2642
+
<constant>CURLOPT_PROXY_KEYPASSWD</constant>, <constant>CURLOPT_PROXY_PINNEDPUBLICKEY</constant>,
2643
+
<constant>CURLOPT_PROXY_SSLCERT</constant>, <constant>CURLOPT_PROXY_SSLCERTTYPE</constant>,
2644
+
<constant>CURLOPT_PROXY_SSL_CIPHER_LIST</constant>, <constant>CURLOPT_PROXY_SSLKEY</constant>,
2645
+
<constant>CURLOPT_PROXY_SSLKEYTYPE</constant>, <constant>CURLOPT_PROXY_SSL_OPTIONS</constant>,
2646
+
<constant>CURLOPT_PROXY_SSL_VERIFYHOST</constant>, <constant>CURLOPT_PROXY_SSL_VERIFYPEER</constant>,
2647
+
<constant>CURLOPT_PROXY_SSLVERSION</constant>, <constant>CURLOPT_PROXY_TLSAUTH_PASSWORD</constant>,
2648
+
<constant>CURLOPT_PROXY_TLSAUTH_TYPE</constant>, <constant>CURLOPT_PROXY_TLSAUTH_USERNAME</constant>,
2649
+
<constant>CURLOPT_SOCKS5_AUTH</constant>, <constant>CURLOPT_SUPPRESS_CONNECT_HEADERS</constant>,
2650
+
<constant>CURLOPT_DISALLOW_USERNAME_IN_URL</constant>, <constant>CURLOPT_DNS_SHUFFLE_ADDRESSES</constant>,
2651
+
<constant>CURLOPT_HAPPY_EYEBALLS_TIMEOUT_MS</constant>, <constant>CURLOPT_HAPROXYPROTOCOL</constant>,
2652
+
<constant>CURLOPT_PROXY_TLS13_CIPHERS</constant>, <constant>CURLOPT_SSH_COMPRESSION</constant>,
2653
+
<constant>CURLOPT_TIMEVALUE_LARGE</constant> and <constant>CURLOPT_TLS13_CIPHERS</constant>.
1507
2654
</entry>
1508
2655
</row>
1509
2656
<row>
1510
-
<entry>5.3.0</entry>
2657
+
<entry>7.0.7</entry>
1511
2658
<entry>
1512
-
Introduced <constant>CURLOPT_PROGRESSFUNCTION</constant>.
1513
-
</entry>
1514
-
</row>
1515
-
<row>
1516
-
<entry>5.2.10</entry>
1517
-
<entry>
1518
-
Introduced <constant>CURLOPT_PROTOCOLS</constant>, and
1519
-
<constant>CURLOPT_REDIR_PROTOCOLS</constant>.
1520
-
</entry>
1521
-
</row>
1522
-
<row>
1523
-
<entry>5.1.0</entry>
1524
-
<entry>
1525
-
Introduced <constant>CURLOPT_AUTOREFERER</constant>,
1526
-
<constant>CURLOPT_BINARYTRANSFER</constant>,
1527
-
<constant>CURLOPT_FTPSSLAUTH</constant>,
1528
-
<constant>CURLOPT_PROXYAUTH</constant>, and
1529
-
<constant>CURLOPT_TIMECONDITION</constant>.
1530
-
</entry>
1531
-
</row>
1532
-
<row>
1533
-
<entry>5.0.0</entry>
1534
-
<entry>
1535
-
Introduced <constant>CURLOPT_FTP_USE_EPRT</constant>,
1536
-
<constant>CURLOPT_NOSIGNAL</constant>,
1537
-
<constant>CURLOPT_UNRESTRICTED_AUTH</constant>,
1538
-
<constant>CURLOPT_BUFFERSIZE</constant>,
1539
-
<constant>CURLOPT_HTTPAUTH</constant>,
1540
-
<constant>CURLOPT_PROXYPORT</constant>,
1541
-
<constant>CURLOPT_PROXYTYPE</constant>,
1542
-
<constant>CURLOPT_SSLCERTTYPE</constant>, and
1543
-
<constant>CURLOPT_HTTP200ALIASES</constant>.
2659
+
Introduced <constant>CURL_HTTP_VERSION_2</constant>, <constant>CURL_HTTP_VERSION_2_PRIOR_KNOWLEDGE</constant>,
2660
+
<constant>CURL_HTTP_VERSION_2TLS</constant>, <constant>CURL_REDIR_POST_301</constant>,
2661
+
<constant>CURL_REDIR_POST_302</constant>, <constant>CURL_REDIR_POST_303</constant>,
2662
+
<constant>CURL_REDIR_POST_ALL</constant>, <constant>CURL_VERSION_KERBEROS5</constant>,
2663
+
<constant>CURL_VERSION_PSL</constant>, <constant>CURL_VERSION_UNIX_SOCKETS</constant>,
2664
+
<constant>CURLAUTH_NEGOTIATE</constant>, <constant>CURLAUTH_NTLM_WB</constant>,
2665
+
<constant>CURLFTP_CREATE_DIR</constant>, <constant>CURLFTP_CREATE_DIR_NONE</constant>,
2666
+
<constant>CURLFTP_CREATE_DIR_RETRY</constant>, <constant>CURLHEADER_SEPARATE</constant>,
2667
+
<constant>CURLHEADER_UNIFIED</constant>, <constant>CURLMOPT_CHUNK_LENGTH_PENALTY_SIZE</constant>,
2668
+
<constant>CURLMOPT_CONTENT_LENGTH_PENALTY_SIZE</constant>, <constant>CURLMOPT_MAX_HOST_CONNECTIONS</constant>,
2669
+
<constant>CURLMOPT_MAX_PIPELINE_LENGTH</constant>, <constant>CURLMOPT_MAX_TOTAL_CONNECTIONS</constant>,
2670
+
<constant>CURLOPT_CONNECT_TO</constant>, <constant>CURLOPT_DEFAULT_PROTOCOL</constant>,
2671
+
<constant>CURLOPT_DNS_INTERFACE</constant>, <constant>CURLOPT_DNS_LOCAL_IP4</constant>,
2672
+
<constant>CURLOPT_DNS_LOCAL_IP6</constant>, <constant>CURLOPT_EXPECT_100_TIMEOUT_MS</constant>,
2673
+
<constant>CURLOPT_HEADEROPT</constant>, <constant>CURLOPT_LOGIN_OPTIONS</constant>,
2674
+
<constant>CURLOPT_PATH_AS_IS</constant>, <constant>CURLOPT_PINNEDPUBLICKEY</constant>,
2675
+
<constant>CURLOPT_PIPEWAIT</constant>, <constant>CURLOPT_PROXY_SERVICE_NAME</constant>,
2676
+
<constant>CURLOPT_PROXYHEADER</constant>, <constant>CURLOPT_SASL_IR</constant>,
2677
+
<constant>CURLOPT_SERVICE_NAME</constant>, <constant>CURLOPT_SSL_ENABLE_ALPN</constant>,
2678
+
<constant>CURLOPT_SSL_ENABLE_NPN</constant>, <constant>CURLOPT_SSL_FALSESTART</constant>,
2679
+
<constant>CURLOPT_SSL_VERIFYSTATUS</constant>, <constant>CURLOPT_STREAM_WEIGHT</constant>,
2680
+
<constant>CURLOPT_TCP_FASTOPEN</constant>, <constant>CURLOPT_TFTP_NO_OPTIONS</constant>,
2681
+
<constant>CURLOPT_UNIX_SOCKET_PATH</constant>, <constant>CURLOPT_XOAUTH2_BEARER</constant>,
2682
+
<constant>CURLPROTO_SMB</constant>, <constant>CURLPROTO_SMBS</constant>,
2683
+
<constant>CURLPROXY_HTTP_1_0</constant>, <constant>CURLSSH_AUTH_AGENT</constant> and
2684
+
<constant>CURLSSLOPT_NO_REVOKE</constant>.
1544
2685
</entry>
1545
2686
</row>
1546
2687
</tbody>
...
...
@@ -1574,55 +2715,6 @@ curl_close($ch);
1574
2715
</programlisting>
1575
2716
</example>
1576
2717
</para>
1577
-
<para>
1578
-
<example>
1579
-
<title>Uploading file (deprecated as of PHP 5.5.0)</title>
1580
-
<programlisting role="php">
1581
-
<![CDATA[
1582
-
<?php
1583
-

1584
-
/* http://localhost/upload.php:
1585
-
print_r($_POST);
1586
-
print_r($_FILES);
1587
-
*/
1588
-

1589
-
$ch = curl_init();
1590
-

1591
-
$data = array('name' => 'Foo', 'file' => '@/home/user/test.png');
1592
-

1593
-
curl_setopt($ch, CURLOPT_URL, 'http://localhost/upload.php');
1594
-
curl_setopt($ch, CURLOPT_POST, 1);
1595
-
curl_setopt($ch, CURLOPT_SAFE_UPLOAD, false); // required as of PHP 5.6.0
1596
-
curl_setopt($ch, CURLOPT_POSTFIELDS, $data);
1597
-

1598
-
curl_exec($ch);
1599
-
?>
1600
-
]]>
1601
-
</programlisting>
1602
-
&example.outputs;
1603
-
<screen>
1604
-
<![CDATA[
1605
-
Array
1606
-
(
1607
-
[name] => Foo
1608
-
)
1609
-
Array
1610
-
(
1611
-
[file] => Array
1612
-
(
1613
-
[name] => test.png
1614
-
[type] => image/png
1615
-
[tmp_name] => /tmp/phpcpjNeQ
1616
-
[error] => 0
1617
-
[size] => 279
1618
-
)
1619
-

1620
-
)
1621
-

1622
-
]]>
1623
-
</screen>
1624
-
</example>
1625
-
</para>
1626
2718
</refsect1>
1627
2719
1628
2720
<refsect1 role="notes">
...
...
@@ -1642,12 +2734,13 @@ Array
1642
2734
<para>
1643
2735
<simplelist>
1644
2736
<member><function>curl_setopt_array</function></member>
2737
+
<member><classname>CURLFile</classname></member>
2738
+
<member><classname>CURLStringFile</classname></member>
1645
2739
</simplelist>
1646
2740
</para>
1647
2741
</refsect1>
1648
2742
1649
2743
</refentry>
1650
-

1651
2744
<!-- Keep this comment at the end of the file
1652
2745
Local variables:
1653
2746
mode: sgml
1654
2747