1
0
mirror of https://github.com/moparisthebest/curl synced 2024-11-05 09:05:04 -05:00
Commit Graph

1384 Commits

Author SHA1 Message Date
Johannes Schindelin
0fb4125554
Add a man page for curl_global_sslset()
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
2017-08-28 14:56:59 +02:00
Johannes Schindelin
1328f69d53
vtls: introduce curl_global_sslset()
Let's add a compile time safe API to select an SSL backend. This
function needs to be called *before* curl_global_init(), and can be
called only once.

Side note: we do not explicitly test that it is called before
curl_global_init(), but we do verify that it is not called multiple times
(even implicitly).

If SSL is used before the function was called, it will use whatever the
CURL_SSL_BACKEND environment variable says (or default to the first
available SSL backend), and if a subsequent call to
curl_global_sslset() disagrees with the previous choice, it will fail
with CURLSSLSET_TOO_LATE.

The function also accepts an "avail" parameter to point to a (read-only)
NULL-terminated list of available backends. This comes in real handy if
an application wants to let the user choose between whatever SSL backends
the currently available libcurl has to offer: simply call

	curl_global_sslset(-1, NULL, &avail);

which will return CURLSSLSET_UNKNOWN_BACKEND and populate the avail
variable to point to the relevant information to present to the user.

Just like with the HTTP/2 push functions, we have to add the function
declaration of curl_global_sslset() function to the header file
*multi.h* because VMS and OS/400 require a stable order of functions
declared in include/curl/*.h (where the header files are sorted
alphabetically). This looks a bit funny, but it cannot be helped.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
2017-08-28 14:56:59 +02:00
Daniel Stenberg
4a7673c8ca
CURLOPT_USERPWD.3: see also CURLOPT_PROXYUSERPWD 2017-08-24 10:09:28 +02:00
Daniel Stenberg
582f2a1308
CURLOPT_SSH_COMPRESSION.3: enable with 1L
(leaves other values reserved for the future)
2017-08-17 09:54:07 +02:00
Viktor Szakats
b7b4dc0d49 ssh: add the ability to enable compression (for SCP/SFTP)
The required low-level logic was already available as part of
`libssh2` (via `LIBSSH2_FLAG_COMPRESS` `libssh2_session_flag()`[1]
option.)

This patch adds the new `libcurl` option `CURLOPT_SSH_COMPRESSION`
(boolean) and the new `curl` command-line option `--compressed-ssh`
to request this `libssh2` feature. To have compression enabled, it
is required that the SSH server supports a (zlib) compatible
compression method and that `libssh2` was built with `zlib` support
enabled.

[1] https://www.libssh2.org/libssh2_session_flag.html

Ref: https://github.com/curl/curl/issues/1732
Closes https://github.com/curl/curl/pull/1735
2017-08-17 03:32:00 -04:00
Alessandro Ghedini
a6fdf11771
docs: fix typo funtion -> function
Closes #1770
2017-08-12 14:56:37 +02:00
Alessandro Ghedini
34f24fef4a docs: fix grammar in CURL_SSLVERSION_MAX_DEFAULT description 2017-08-12 13:36:39 +01:00
Alessandro Ghedini
274f9cac96 docs: fix typo stuct -> struct 2017-08-12 13:33:10 +01:00
Daniel Stenberg
a7bbbb7c36
make install: add 8 missing man pages to the installation 2017-08-09 11:31:10 +02:00
Viktor Szakats
13ef623a81
docs/comments: Update to secure URL versions
Closes #1741
2017-08-08 21:41:07 +02:00
Daniel Stenberg
70934885d0 CURLOPT_NETRC.3: fix typo in 7e48aa3861
Reported-by: Viktor Szakats
2017-08-02 15:29:27 +02:00
Daniel Stenberg
7e48aa3861 CURLOPT_NETRC.3: mention the file name on windows
... and CURLOPT_NETRC_FILE(3).
2017-08-02 14:34:26 +02:00
Daniel Stenberg
bbc9c6d144 CURLOPT_POSTFIELDS.3: explain the 100-continue magic better 2017-07-07 12:43:17 +02:00
Daniel Stenberg
a126ca8481 curl_easy_escape.3: mention the (lack of) encoding
Fixes #1612
Reported-by: Jeroen Ooms
2017-07-07 10:47:46 +02:00
Daniel Stenberg
ef2a9f22cc curl_strequal.3: fix typo in SYNOPSIS
Reported-by: Jesse Chisholm

Fixes #1623
2017-06-29 01:16:56 +02:00
Kamil Dudka
8924f58c37 CURLOPT_SOCKS5_AUTH: allowed methods for SOCKS5 proxy auth
If libcurl was built with GSS-API support, it unconditionally advertised
GSS-API authentication while connecting to a SOCKS5 proxy.  This caused
problems in environments with improperly configured Kerberos: a stock
libcurl failed to connect, despite libcurl built without GSS-API
connected fine using username and password.

This commit introduces the CURLOPT_SOCKS5_AUTH option to control the
allowed methods for SOCKS5 authentication at run time.

Note that a new option was preferred over reusing CURLOPT_PROXYAUTH
for compatibility reasons because the set of authentication methods
allowed by default was different for HTTP and SOCKS5 proxies.

Bug: https://curl.haxx.se/mail/lib-2017-01/0005.html
Closes https://github.com/curl/curl/pull/1454
2017-06-28 08:02:58 +02:00
Daniel Stenberg
924cd3e25b CURLINFO_REDIRECT_URL.3: mention the CURLOPT_MAXREDIRS case
... supported since 7.54.1
2017-06-24 00:59:10 +02:00
Daniel Stenberg
9b167fd090 --request-target: instead of --strip-path-slash
... and CURLOPT_REQUEST_TARGET instead of CURLOPT_STRIP_PATH_SLASH.

This option instead provides the full "alternative" target to use in the
request, instead of extracting the path from the URL.

Test 1298 and 1299 updated accordingly.

Idea-by: Evert Pot
Suggestion: https://daniel.haxx.se/blog/2017/06/19/options-with-curl/comment-page-1/#comment-18373

Closes #1593
2017-06-21 23:39:10 +02:00
Daniel Stenberg
b778ae4c5e http: add --strip-path-slash and CURLOPT_STRIP_PATH_SLASH
... to enable sending "OPTIONS *" which wasn't possible previously.

This option currently only works for HTTP.

Added test cases 1298 + 1299 to verify

Fixes #1280
Closes #1462
2017-06-19 16:39:22 +02:00
Daniel Stenberg
3b80d3ca46 getinfo: return sizes as curl_off_t
This change introduces new alternatives for the existing six
curl_easy_getinfo() options that return sizes or speeds as doubles. The
new versions are named like the old ones but with an appended '_T':

CURLINFO_CONTENT_LENGTH_DOWNLOAD_T
CURLINFO_CONTENT_LENGTH_UPLOAD_T
CURLINFO_SIZE_DOWNLOAD_T
CURLINFO_SIZE_UPLOAD_T
CURLINFO_SPEED_DOWNLOAD_T
CURLINFO_SPEED_UPLOAD_T

Closes #1511
2017-06-19 09:27:42 +02:00
Daniel Stenberg
7b3b4722be CURLOPT_PREQUOTE.3: spellfix man page reference 2017-06-18 17:06:51 +02:00
Daniel Stenberg
8bc9cabd7f TODO: implement support for CURLOPT_PREQUOTE with SFTP
... also updated the CURLOPT_PREQUOTE.3 man page to mention the correct
protocol support.

Closes #1514
2017-06-18 00:25:09 +02:00
Daniel Stenberg
5113ad0424 http-proxy: do the HTTP CONNECT process entirely non-blocking
Mentioned as a problem since 2007 (8f87c15bda) and of course it
existed even before that.

Closes #1547
2017-06-14 23:43:52 +02:00
Daniel Stenberg
5fe4f78902 typecheck-gcc.h: separate getinfo slist checks from other pointers
Fixes #1524
2017-06-01 21:06:09 +02:00
Daniel Stenberg
aae4a4788a CURLOPT_SSH_KEY*.3: typos
Reported-by: Gisle Vanem
2017-05-31 13:52:03 +02:00
Daniel Stenberg
399a1a6182 CURLOPT_STREAM_DEPENDS.3: typo 2017-05-31 13:39:56 +02:00
Daniel Stenberg
f072393feb CURLOPT_FNMATCH_FUNCTION.3: also modified example to avoid fcpp issues 2017-05-31 13:36:51 +02:00
Daniel Stenberg
28baf380fa CURLOPT_FNMATCH_DATA.3: modified example to avoid fcpp issues 2017-05-31 13:30:04 +02:00
Daniel Stenberg
4600362a5a opts: more than 100 more examples for man pages... 2017-05-31 11:56:53 +02:00
Daniel Stenberg
a6ad28a75e CURLOPT_PROXY.3: fix test 1140 breakage 2017-05-31 08:45:36 +02:00
Daniel Stenberg
bb1a8c174b opts: more examples added to man pages 2017-05-30 23:35:30 +02:00
Daniel Stenberg
2d5fa35e85 docs: clarify NO_PROXY further
Fixes #1208
2017-05-30 22:43:34 +02:00
Daniel Stenberg
dd97551746 CURLOPT_PROXY.3: describe the environment variables more 2017-05-30 18:05:33 +02:00
Daniel Stenberg
c2227dae53 opts: more examples added in option man pages 2017-05-27 23:11:26 +02:00
Phil Crump
a9de0a9f54 docs/CURLOPT_SSLVERSION.3: Correct define name in example
Closes #1509
2017-05-25 16:28:30 +02:00
eb16305e6a SecureTransport/DarwinSSL: Implement public key pinning
Closes #1400
2017-05-15 22:54:33 +02:00
Daniel Stenberg
1919569633 man pages: fix example syntax errors
follow-up to 5ddad099b4
2017-05-15 13:01:15 +02:00
Daniel Stenberg
5ddad099b4 docs/libcurl/opts: added more examples in man pages 2017-05-15 11:45:19 +02:00
Daniel Stenberg
e366ca2b85 CURLOPT_HTTPPROXYTUNNEL: clarify, add example 2017-05-15 10:11:23 +02:00
Dan Fandrich
d836c9fee4 url.c: add a compile-time check that CURL_MAX_WRITE_SIZE is large enough
Some code (e.g. Curl_fillreadbuffer) assumes that this buffer is not
exceedingly tiny and will break if it is. This same check is already
done at run time in the CURLOPT_BUFFERSIZE option.
2017-05-13 23:21:27 +02:00
Daniel Stenberg
289236b223 opts: fix bad example formatting \n => \\n
...to render properly nroff.
2017-05-06 23:51:29 +02:00
Daniel Stenberg
271c63748a opts: examples added to 8 more libcurl option man pages 2017-05-06 23:38:39 +02:00
Daniel Stenberg
2b7bde4d3f docs/opts: 24 more man pages now have examples 2017-05-05 17:26:08 +02:00
Daniel Stenberg
58a6265a40 docs/opts: 23 more man pages now have examples 2017-05-05 16:30:23 +02:00
Daniel Stenberg
22fdb0954c tests/server: run checksrc by default in debug-builds 2017-05-05 15:51:25 +02:00
Daniel Stenberg
9b47f67929 curl_slist_append.3: clarify a NULL input creates a new list 2017-05-05 13:54:56 +02:00
Daniel Stenberg
4b93382193 CURLINFO_REDIRECT_URL.3: add example 2017-05-04 00:00:13 +02:00
Daniel Stenberg
b065a508c6 CURLINFO_EFFECTIVE_URL.3: add example 2017-05-04 00:00:07 +02:00
Kamil Dudka
e3e8d0204b nss: load libnssckbi.so if no other trust is specified
The module contains a more comprehensive set of trust information than
supported by nss-pem, because libnssckbi.so also includes information
about distrusted certificates.

Reviewed-by: Kai Engert
Closes #1414
2017-04-25 13:24:24 +02:00
Dan Fandrich
f9d1e9a27f libcurl-thread.3: fixed a bad macro that caused test 1140 to fail 2017-04-10 07:42:22 +02:00