]> granicus.if.org Git - curl/log
curl
9 years agobuild: Fix typo from OpenSSL 1.0.2 version detection fix
Drake Arconis [Sun, 14 Jun 2015 19:52:42 +0000 (15:52 -0400)]
build: Fix typo from OpenSSL 1.0.2 version detection fix

9 years agobuild: Properly detect OpenSSL 1.0.2 when using configure
Drake Arconis [Sun, 14 Jun 2015 17:51:06 +0000 (13:51 -0400)]
build: Properly detect OpenSSL 1.0.2 when using configure

9 years agocurl_multi_info_read.3: fix example formatting
Jay Satiro [Sun, 14 Jun 2015 03:25:07 +0000 (23:25 -0400)]
curl_multi_info_read.3: fix example formatting

9 years agoBINDINGS: there's a new R binding in town!
Daniel Stenberg [Sat, 13 Jun 2015 21:10:23 +0000 (23:10 +0200)]
BINDINGS: there's a new R binding in town!

9 years agoBINDINGS: added the Xojo binding
Daniel Stenberg [Thu, 11 Jun 2015 21:33:49 +0000 (23:33 +0200)]
BINDINGS: added the Xojo binding

9 years agoschannel: Add support for optional client certificates
Joel Depooter [Thu, 11 Jun 2015 19:52:25 +0000 (15:52 -0400)]
schannel: Add support for optional client certificates

Some servers will request a client certificate, but not require one.
This change allows libcurl to connect to such servers when using
schannel as its ssl/tls backend. When a server requests a client
certificate, libcurl will now continue the handshake without one,
rather than terminating the handshake. The server can then decide
if that is acceptable or not. Prior to this change, libcurl would
terminate the handshake, reporting a SEC_I_INCOMPLETE_CREDENTIALS
error.

9 years agocurl_easy_cleanup.3: provide more SEE ALSO
Daniel Stenberg [Thu, 11 Jun 2015 06:32:11 +0000 (08:32 +0200)]
curl_easy_cleanup.3: provide more SEE ALSO

9 years agodebug: remove http2 debug leftovers
Daniel Stenberg [Wed, 10 Jun 2015 21:16:17 +0000 (23:16 +0200)]
debug: remove http2 debug leftovers

9 years agoVERSIONS: now using markdown
Daniel Stenberg [Tue, 9 Jun 2015 22:21:06 +0000 (00:21 +0200)]
VERSIONS: now using markdown

9 years agoRELEASE-PROCEDURE: remove ascii logo at the top of file
Daniel Stenberg [Tue, 9 Jun 2015 22:16:48 +0000 (00:16 +0200)]
RELEASE-PROCEDURE: remove ascii logo at the top of file

9 years agoINTERNALS: absorbed docs/LIBCURL-STRUCTS
Daniel Stenberg [Tue, 9 Jun 2015 22:11:54 +0000 (00:11 +0200)]
INTERNALS: absorbed docs/LIBCURL-STRUCTS

9 years agoINTERNALS: cat lib/README* >> INTERNALS
Daniel Stenberg [Tue, 9 Jun 2015 21:57:22 +0000 (23:57 +0200)]
INTERNALS: cat lib/README* >> INTERNALS

and a conversion to markdown. Removed the lib/README.* files. The idea
being to move toward having INTERNALS as the one and only "book" of
internals documentation.

Added a TOC to top of the document.

9 years agoopenssl: LibreSSL and BoringSSL do not use TLS_client_method
Jay Satiro [Tue, 9 Jun 2015 03:42:11 +0000 (23:42 -0400)]
openssl: LibreSSL and BoringSSL do not use TLS_client_method

Although OpenSSL 1.1.0+ deprecated SSLv23_client_method in favor of
TLS_client_method LibreSSL and BoringSSL didn't and still use
SSLv23_client_method.

Bug: https://github.com/bagder/curl/commit/49a6642#commitcomment-11578009
Reported-by: asavah@users.noreply.github.com
9 years agoRELEASE-NOTES: synced with 20ac3458068
Daniel Stenberg [Mon, 8 Jun 2015 22:33:23 +0000 (00:33 +0200)]
RELEASE-NOTES: synced with 20ac3458068

9 years agoCURLOPT_OPENSOCKETFUNCTION: return error at once
Daniel Stenberg [Mon, 8 Jun 2015 22:22:02 +0000 (00:22 +0200)]
CURLOPT_OPENSOCKETFUNCTION: return error at once

When CURL_SOCKET_BAD is returned in the callback, it should be treated
as an error (CURLE_COULDNT_CONNECT) if no other socket is subsequently
created when trying to connect to a server.

Bug: http://curl.haxx.se/mail/lib-2015-06/0047.html

9 years agofopen.c: fix a few compiler warnings
Daniel Stenberg [Mon, 8 Jun 2015 11:47:33 +0000 (13:47 +0200)]
fopen.c: fix a few compiler warnings

9 years agodocs: Spelling fixes
Ville Skyttä [Mon, 8 Jun 2015 11:22:54 +0000 (14:22 +0300)]
docs: Spelling fixes

9 years agodocs: man page indentation and syntax fixes
Ville Skyttä [Mon, 8 Jun 2015 11:14:18 +0000 (14:14 +0300)]
docs: man page indentation and syntax fixes

9 years agohelp: Add --proxy-service-name and --service-name to the --help output
Linus Nielsen [Mon, 8 Jun 2015 08:00:11 +0000 (10:00 +0200)]
help: Add --proxy-service-name and --service-name to the --help output

9 years agoopenssl: Fix verification of server-sent legacy intermediates
Jay Satiro [Sat, 30 May 2015 05:29:48 +0000 (01:29 -0400)]
openssl: Fix verification of server-sent legacy intermediates

- Try building a chain using issuers in the trusted store first to avoid
problems with server-sent legacy intermediates.

Prior to this change server-sent legacy intermediates with missing
legacy issuers would cause verification to fail even if the client's CA
bundle contained a valid replacement for the intermediate and an
alternate chain could be constructed that would verify successfully.

https://rt.openssl.org/Ticket/Display.html?id=3621&user=guest&pass=guest

9 years agoBINDINGS: update several URLs
Daniel Stenberg [Fri, 5 Jun 2015 07:15:40 +0000 (09:15 +0200)]
BINDINGS: update several URLs

Stop linking to the curl.haxx.se anchor pages, they are usually only
themselves pointers to the real page so better point there directly
instead.

9 years agoBINDINGS: the curl-rust binding
Daniel Stenberg [Fri, 5 Jun 2015 06:55:19 +0000 (08:55 +0200)]
BINDINGS: the curl-rust binding

9 years agocurl.h: add CURL_HTTP_VERSION_2
Daniel Stenberg [Fri, 5 Jun 2015 06:26:47 +0000 (08:26 +0200)]
curl.h: add CURL_HTTP_VERSION_2

The protocol is named "HTTP/2" after all. It is an alias for the
existing CURL_HTTP_VERSION_2_0 enum.

9 years agoopenssl: removed error string #ifdef
Daniel Stenberg [Thu, 4 Jun 2015 22:12:56 +0000 (00:12 +0200)]
openssl: removed error string #ifdef

ERR_error_string_n() was introduced in 0.9.6, no need to #ifdef anymore

9 years agoopenssl: removed USERDATA_IN_PWD_CALLBACK kludge
Daniel Stenberg [Thu, 4 Jun 2015 22:11:32 +0000 (00:11 +0200)]
openssl: removed USERDATA_IN_PWD_CALLBACK kludge

Code for OpenSSL 0.9.4 serves no purpose anymore!

9 years agoopenssl: remove SSL_get_session()-using code
Daniel Stenberg [Thu, 4 Jun 2015 22:09:25 +0000 (00:09 +0200)]
openssl: remove SSL_get_session()-using code

It was present for OpenSSL 0.9.5 code but we only support 0.9.7 or
later.

9 years agoopenssl: remove dummy callback use from SSL_CTX_set_verify()
Daniel Stenberg [Thu, 4 Jun 2015 22:02:17 +0000 (00:02 +0200)]
openssl: remove dummy callback use from SSL_CTX_set_verify()

The existing callback served no purpose.

9 years agoLIBCURL-STRUCTS: clarify for multiplexing
Daniel Stenberg [Thu, 4 Jun 2015 20:43:36 +0000 (22:43 +0200)]
LIBCURL-STRUCTS: clarify for multiplexing

9 years agocookie: Stop exporting any-domain cookies
Jay Satiro [Thu, 4 Jun 2015 01:48:47 +0000 (21:48 -0400)]
cookie: Stop exporting any-domain cookies

Prior to this change any-domain cookies (cookies without a domain that
are sent to any domain) were exported with domain name "unknown".

Bug: https://github.com/bagder/curl/issues/292

9 years agoRELEASE-PROCEDURE: refreshed 'coming dates'
Daniel Stenberg [Wed, 3 Jun 2015 11:53:26 +0000 (13:53 +0200)]
RELEASE-PROCEDURE: refreshed 'coming dates'

9 years agocurl_setup: Change fopen text macros to use 't' for MSDOS
Jay Satiro [Tue, 2 Jun 2015 18:04:00 +0000 (14:04 -0400)]
curl_setup: Change fopen text macros to use 't' for MSDOS

Bug: https://github.com/bagder/curl/pull/258#issuecomment-107915198
Reported-by: Gisle Vanem
9 years agocurl_multi_timeout.3: added example
Daniel Stenberg [Tue, 2 Jun 2015 10:18:10 +0000 (12:18 +0200)]
curl_multi_timeout.3: added example

9 years agocurl_multi_perform.3: added example
Daniel Stenberg [Tue, 2 Jun 2015 10:13:23 +0000 (12:13 +0200)]
curl_multi_perform.3: added example

9 years agocurl_multi_info_read.3: added example
Daniel Stenberg [Tue, 2 Jun 2015 10:00:37 +0000 (12:00 +0200)]
curl_multi_info_read.3: added example

9 years agochecksrc: detect fopen() for text without the FOPEN_* macros
Daniel Stenberg [Tue, 2 Jun 2015 06:28:10 +0000 (08:28 +0200)]
checksrc: detect fopen() for text without the FOPEN_* macros

Follow-up to e8423f9ce150 with discussionis in
https://github.com/bagder/curl/pull/258

This check scans for fopen() with a mode string without 'b' present, as
it may indicate that an FOPEN_* define should rather be used.

9 years agocurl_getdate.3: update RFC reference
Daniel Stenberg [Mon, 1 Jun 2015 08:18:11 +0000 (10:18 +0200)]
curl_getdate.3: update RFC reference

9 years agocurl_setup: Add macros for FOPEN_READTEXT, FOPEN_WRITETEXT
Jay Satiro [Mon, 1 Jun 2015 07:20:18 +0000 (03:20 -0400)]
curl_setup: Add macros for FOPEN_READTEXT, FOPEN_WRITETEXT

- Change fopen calls to use FOPEN_READTEXT instead of "r" or "rt"
- Change fopen calls to use FOPEN_WRITETEXT instead of "w" or "wt"

This change is to explicitly specify when we need to read/write text.
Unfortunately 't' is not part of POSIX fopen so we can't specify it
directly. Instead we now have FOPEN_READTEXT, FOPEN_WRITETEXT.

Prior to this change we had an issue on Windows if an application that
uses libcurl overrides the default file mode to binary. The default file
mode in Windows is normally text mode (translation mode) and that's what
libcurl expects.

Bug: https://github.com/bagder/curl/pull/258#issuecomment-107093055
Reported-by: Orgad Shaneh
9 years agohttp2-upload.c: use PIPEWAIT for playing HTTP/2 better
Daniel Stenberg [Mon, 1 Jun 2015 06:46:18 +0000 (08:46 +0200)]
http2-upload.c: use PIPEWAIT for playing HTTP/2 better

9 years agohttp2-download: check for CURLPIPE_MULTIPLEX properly
Daniel Stenberg [Mon, 1 Jun 2015 06:45:30 +0000 (08:45 +0200)]
http2-download: check for CURLPIPE_MULTIPLEX properly

Bug: http://curl.haxx.se/mail/lib-2015-06/0001.html
Reported-by: Rafayel Mkrtchyan
9 years agoHTTP-NTLM: fail auth on connection close instead of looping
Isaac Boukris [Sun, 31 May 2015 21:21:15 +0000 (23:21 +0200)]
HTTP-NTLM: fail auth on connection close instead of looping

Bug: https://github.com/bagder/curl/issues/256

9 years ago5.6 Refuse "downgrade" redirects
Daniel Stenberg [Sat, 30 May 2015 22:39:19 +0000 (00:39 +0200)]
5.6 Refuse "downgrade" redirects

9 years agoREADME.pingpong: removed
Daniel Stenberg [Sat, 30 May 2015 22:20:22 +0000 (00:20 +0200)]
README.pingpong: removed

9 years agoROADMAP: remove HTTP/2 multiplexing - its here now
Daniel Stenberg [Sat, 30 May 2015 10:09:22 +0000 (12:09 +0200)]
ROADMAP: remove HTTP/2 multiplexing - its here now

9 years agoHTTP2.md: formatted properly
Daniel Stenberg [Sat, 30 May 2015 10:07:39 +0000 (12:07 +0200)]
HTTP2.md: formatted properly

9 years agoHTTP2: moved docs into docs/ and make it markdown
Daniel Stenberg [Sat, 30 May 2015 09:55:33 +0000 (11:55 +0200)]
HTTP2: moved docs into docs/ and make it markdown

9 years agoREADME.http2: refreshed and added multiplexing info
Daniel Stenberg [Sat, 30 May 2015 09:53:24 +0000 (11:53 +0200)]
README.http2: refreshed and added multiplexing info

9 years agodist: add the http2 examples
Daniel Stenberg [Thu, 28 May 2015 14:04:13 +0000 (16:04 +0200)]
dist: add the http2 examples

9 years agohttp2 examples: clean up some comments
Daniel Stenberg [Thu, 28 May 2015 14:04:00 +0000 (16:04 +0200)]
http2 examples: clean up some comments

9 years agoexamples: added two programs doing multiplexed HTTP/2
Daniel Stenberg [Thu, 28 May 2015 13:58:34 +0000 (15:58 +0200)]
examples: added two programs doing multiplexed HTTP/2

9 years agoscripts: moved contributors.sh and contrithanks.sh into subdir
Daniel Stenberg [Wed, 27 May 2015 14:10:08 +0000 (16:10 +0200)]
scripts: moved contributors.sh and contrithanks.sh into subdir

9 years agoRELEASE-NOTES: synced with c005790ff1c0a
Daniel Stenberg [Wed, 27 May 2015 12:48:59 +0000 (14:48 +0200)]
RELEASE-NOTES: synced with c005790ff1c0a

9 years agoopenssl: typo in comment
Daniel Melani [Wed, 27 May 2015 09:27:03 +0000 (11:27 +0200)]
openssl: typo in comment

9 years agoopenssl: Use TLS_client_method for OpenSSL 1.1.0+
Jay Satiro [Wed, 27 May 2015 05:29:16 +0000 (01:29 -0400)]
openssl: Use TLS_client_method for OpenSSL 1.1.0+

SSLv23_client_method is deprecated starting in OpenSSL 1.1.0. The
equivalent is TLS_client_method.

https://github.com/openssl/openssl/commit/13c9bb3#diff-708d3ae0f2c2973b272b811315381557

9 years agoFAQ: How do I port libcurl to my OS?
Daniel Stenberg [Tue, 26 May 2015 17:13:09 +0000 (19:13 +0200)]
FAQ: How do I port libcurl to my OS?

9 years agoCURLOPT_COOKIELIST.3: Explain Set-Cookie without a domain
Jay Satiro [Mon, 25 May 2015 21:27:53 +0000 (17:27 -0400)]
CURLOPT_COOKIELIST.3: Explain Set-Cookie without a domain

Document that if Set-Cookie is used without a domain then the cookie is
sent for any domain and will not be modified.

Bug: http://curl.haxx.se/mail/lib-2015-05/0137.html
Reported-by: Alexander Dyagilev
9 years agohttp2: Copy data passed in Curl_http2_switched into HTTP/2 connection buffer
Tatsuhiro Tsujikawa [Mon, 25 May 2015 15:10:05 +0000 (00:10 +0900)]
http2: Copy data passed in Curl_http2_switched into HTTP/2 connection buffer

Previously, after seeing upgrade to HTTP/2, we feed data followed by
upgrade response headers directly to nghttp2_session_mem_recv() in
Curl_http2_switched().  But it turns out that passed buffer, mem, is
part of stream->mem, and callbacks called by
nghttp2_session_mem_recv() will write stream specific data into
stream->mem, overwriting input data.  This will corrupt input, and
most likely frame length error is detected by nghttp2 library.  The
fix is first copy the passed data to HTTP/2 connection buffer,
httpc->inbuf, and call nghttp2_session_mem_recv().

9 years agoCURLOPT_COOKIE.3: Explain that the cookies won't be modified
Jay Satiro [Sun, 24 May 2015 23:01:13 +0000 (19:01 -0400)]
CURLOPT_COOKIE.3: Explain that the cookies won't be modified

The CURLOPT_COOKIE doc says it "sets the cookie header explicitly in the
outgoing request(s)." However there seems to be some user confusion
about cookie modification. Document that the cookies set by this option
are not modified by the cookie engine.

Bug: http://curl.haxx.se/mail/lib-2015-05/0115.html
Reported-by: Alexander Dyagilev
9 years agoCURLOPT_COOKIELIST.3: Add example
Jay Satiro [Sun, 24 May 2015 19:39:28 +0000 (15:39 -0400)]
CURLOPT_COOKIELIST.3: Add example

9 years agotestcurl.pl: use rel2abs to make the source directory absolute
Dan Fandrich [Sun, 24 May 2015 10:02:30 +0000 (12:02 +0200)]
testcurl.pl: use rel2abs to make the source directory absolute

This function makes a platform-specific absolute path which uses
backslashes on Windows. This form works when passing it on the
command-line, as well as if the source is on another drive.

9 years agoconncache: fixed memory leak on OOM (torture tests)
Dan Fandrich [Sun, 24 May 2015 09:19:07 +0000 (11:19 +0200)]
conncache: fixed memory leak on OOM (torture tests)

9 years agoperl: remove subdir, not touched in 9 years
Daniel Stenberg [Sat, 23 May 2015 22:54:55 +0000 (00:54 +0200)]
perl: remove subdir, not touched in 9 years

9 years agolog2changes.pl: moved to scripts/
Daniel Stenberg [Sat, 23 May 2015 22:09:23 +0000 (00:09 +0200)]
log2changes.pl: moved to scripts/

9 years agoscripts: add zsh.pl for generating zsh completion
Alessandro Ghedini [Thu, 7 May 2015 14:07:24 +0000 (16:07 +0200)]
scripts: add zsh.pl for generating zsh completion

9 years agotest1510: another flaky test
Dan Fandrich [Sat, 23 May 2015 14:27:49 +0000 (16:27 +0200)]
test1510: another flaky test

9 years agosecurity: fix "Unchecked return value" from sscanf()
Daniel Stenberg [Fri, 22 May 2015 14:52:03 +0000 (16:52 +0200)]
security: fix "Unchecked return value" from sscanf()

By (void) prefixing it and adding a comment. Did some minor related
cleanups.

Coverity CID 1299423.

9 years agosecurity: simplify choose_mech
Daniel Stenberg [Fri, 22 May 2015 14:43:58 +0000 (16:43 +0200)]
security: simplify choose_mech

Coverity CID 1299424 identified dead code because of checks that could
never equal true (if the mechanism's name was NULL).

Simplified the function by removing a level of pointers and removing the
loop and array that weren't used.

9 years agoRTSP: catch attempted unsupported requests better
Daniel Stenberg [Fri, 22 May 2015 14:32:42 +0000 (16:32 +0200)]
RTSP: catch attempted unsupported requests better

Replace use of assert with code that properly catches bad input at
run-time even in non-debug builds.

This flaw was sort of detected by Coverity CID 1299425 which claimed the
"case RTSPREQ_NONE" was dead code.

9 years agoshare_init: fix OOM crash
Daniel Stenberg [Fri, 22 May 2015 14:26:14 +0000 (16:26 +0200)]
share_init: fix OOM crash

A failed calloc() would lead to NULL pointer use.

Coverity CID 1299427.

9 years agoparse_proxy: switch off tunneling if non-HTTP proxy
Daniel Stenberg [Fri, 22 May 2015 07:06:44 +0000 (09:06 +0200)]
parse_proxy: switch off tunneling if non-HTTP proxy

non-HTTP proxy implies not using CURLOPT_HTTPPROXYTUNNEL

Bug: http://curl.haxx.se/mail/lib-2015-05/0056.html
Reported-by: Sean Boudreau
9 years agocurl: fix potential NULL dereference
Daniel Stenberg [Fri, 22 May 2015 14:18:36 +0000 (16:18 +0200)]
curl: fix potential NULL dereference

Coverity CID 1299428: Dereference after null check (FORWARD_NULL)

9 years agohttp2: on_frame_recv: return early on stream 0
Daniel Stenberg [Fri, 22 May 2015 13:17:16 +0000 (15:17 +0200)]
http2: on_frame_recv: return early on stream 0

Coverity CID 1299426 warned about possible NULL dereference otherwise,
but that would only ever happen if we get invalid HTTP/2 data with
frames for stream 0. Avoid this risk by returning early when stream 0 is
used.

9 years agohttp: removed self assignment
Daniel Stenberg [Fri, 22 May 2015 07:57:16 +0000 (09:57 +0200)]
http: removed self assignment

Follow-up fix from b0143a2a33f0

Detected by coverity. CID 1299429

9 years agohttp2: Make HTTP Upgrade work
Tatsuhiro Tsujikawa [Thu, 21 May 2015 16:21:59 +0000 (01:21 +0900)]
http2: Make HTTP Upgrade work

This commit just add implicitly opened stream 1 to streams hash.

9 years agostrerror: Change SEC_E_ILLEGAL_MESSAGE description
Jay Satiro [Fri, 22 May 2015 06:30:38 +0000 (02:30 -0400)]
strerror: Change SEC_E_ILLEGAL_MESSAGE description

Prior to this change the description for SEC_E_ILLEGAL_MESSAGE was OS
and language specific, and invariably translated to something not very
helpful like: "The message received was unexpected or badly formatted."

Bug: https://github.com/bagder/curl/issues/267
Reported-by: Michael Osipov
9 years agotelnet: Fix read-callback change for Windows builds
Jay Satiro [Fri, 22 May 2015 03:26:32 +0000 (23:26 -0400)]
telnet: Fix read-callback change for Windows builds

Refer to b0143a2 for more information on the read-callback change.

9 years agoCURLOPT_HTTPPROXYTUNNEL.3: only works with a HTTP proxy!
Daniel Stenberg [Thu, 21 May 2015 12:17:17 +0000 (14:17 +0200)]
CURLOPT_HTTPPROXYTUNNEL.3: only works with a HTTP proxy!

9 years agotestcurl.pl: allow source to be in an arbitrary directory
Dan Fandrich [Thu, 21 May 2015 07:10:31 +0000 (09:10 +0200)]
testcurl.pl: allow source to be in an arbitrary directory

This way, the build directory can be located on an entirely different
filesystem from the source code (e.g. a tmpfs).

9 years agoread_callback: move to SessionHandle from connectdata
Daniel Stenberg [Wed, 20 May 2015 12:33:04 +0000 (14:33 +0200)]
read_callback: move to SessionHandle from connectdata

With many easy handles using the same connection for multiplexing, it is
important we store and keep the transfer-oriented stuff in the
SessionHandle so that callbacks and callback data work fine even when
many easy handles share the same physical connection.

9 years agohttp2: show stream IDs in decimal
Daniel Stenberg [Wed, 20 May 2015 12:27:08 +0000 (14:27 +0200)]
http2: show stream IDs in decimal

It makes them easier to match output from the nghttpd test server.

9 years agohttp2: Faster http2 upload
Tatsuhiro Tsujikawa [Wed, 20 May 2015 14:11:43 +0000 (23:11 +0900)]
http2: Faster http2 upload

Previously, when we send all given buffer in data_source_callback, we
return NGHTTP2_ERR_DEFERRED, and nghttp2 library removes this stream
temporarily for writing.  This itself is good.  If this is the sole
stream in the session, nghttp2_session_want_write() returns zero,
which means that libcurl does not check writeability of the underlying
socket.  This leads to very slow upload, because it seems curl only
upload 16k something per 1 second.  To fix this, if we still have data
to send, call nghttp2_session_resume_data after nghttp2_session_send.
This makes nghttp2_session_want_write() returns nonzero (if connection
window still opens), and as a result, socket writeability is checked,
and upload speed becomes normal.

9 years agogtls: don't fail on non-fatal alerts during handshake
Dmitry Eremin-Solenikov [Wed, 20 May 2015 19:50:55 +0000 (22:50 +0300)]
gtls: don't fail on non-fatal alerts during handshake

Stop curl from failing when non-fatal alert is received during
handshake.  This e.g. fixes lots of problems when working with https
sites through proxies.

9 years agocurl_easy_unescape.3: update RFC reference
Daniel Stenberg [Wed, 20 May 2015 06:21:27 +0000 (08:21 +0200)]
curl_easy_unescape.3: update RFC reference

Reported-by: bsammon
Bug: https://github.com/bagder/curl/issues/282

9 years agoCURLOPT_POSTFIELDS.3: Mention curl_easy_escape
Jay Satiro [Wed, 20 May 2015 05:48:31 +0000 (01:48 -0400)]
CURLOPT_POSTFIELDS.3: Mention curl_easy_escape

.. also correct some variable naming in curl_easy_escape.3

Bug: https://github.com/bagder/curl/issues/281
Reported-by: bsammon@users.noreply.github.com
9 years agoopenssl: Use SSL_CTX_set_msg_callback and SSL_CTX_set_msg_callback_arg
Brian Prodoehl [Tue, 19 May 2015 15:10:28 +0000 (11:10 -0400)]
openssl: Use SSL_CTX_set_msg_callback and SSL_CTX_set_msg_callback_arg

BoringSSL removed support for direct callers of SSL_CTX_callback_ctrl
and SSL_CTX_ctrl, so move to a way that should work on BoringSSL and
OpenSSL.

re #275

9 years agocurl.1: fix missing space in section --data
Jay Satiro [Tue, 19 May 2015 19:43:11 +0000 (15:43 -0400)]
curl.1: fix missing space in section --data

9 years agotransfer: remove erroneous and misleading comment
Daniel Stenberg [Tue, 19 May 2015 11:58:13 +0000 (13:58 +0200)]
transfer: remove erroneous and misleading comment

9 years agohttp: silence compile-time warnings without USE_NGHTTP2
Kamil Dudka [Tue, 19 May 2015 10:51:40 +0000 (12:51 +0200)]
http: silence compile-time warnings without USE_NGHTTP2

Error: CLANG_WARNING:
lib/http.c:173:16: warning: Value stored to 'http' during its initialization is never read

Error: COMPILER_WARNING:
lib/http.c: scope_hint: In function ‘http_disconnect’
lib/http.c:173:16: warning: unused variable ‘http’ [-Wunused-variable]

9 years agotransfer: Replace __func__ instances with function name
Jay Satiro [Tue, 19 May 2015 06:23:55 +0000 (02:23 -0400)]
transfer: Replace __func__ instances with function name

.. also make __func__ replacement in multi.

Prior to this change debug builds would fail to build if the compiler
was building pre-c99 and didn't support __func__.

9 years agobuild: bump version in default nghttp2 paths
Viktor Szakats [Mon, 18 May 2015 23:42:29 +0000 (01:42 +0200)]
build: bump version in default nghttp2 paths

9 years agoINTERNALS: we require nghttp2 1.0.0+ now
Daniel Stenberg [Tue, 19 May 2015 05:41:01 +0000 (07:41 +0200)]
INTERNALS: we require nghttp2 1.0.0+ now

9 years agohttp: Add some include guards for the new HTTP/2 stuff
Jay Satiro [Tue, 19 May 2015 00:53:58 +0000 (20:53 -0400)]
http: Add some include guards for the new HTTP/2 stuff

9 years agohttp2: store upload state per stream
Daniel Stenberg [Mon, 18 May 2015 12:01:38 +0000 (14:01 +0200)]
http2: store upload state per stream

Use a curl_off_t for upload left

9 years agohttp2: fix build when NOT h2-enabled
Daniel Stenberg [Mon, 18 May 2015 12:09:32 +0000 (14:09 +0200)]
http2: fix build when NOT h2-enabled

9 years agohttp2: switch to use Curl_hash_destroy()
Daniel Stenberg [Mon, 18 May 2015 09:41:16 +0000 (11:41 +0200)]
http2: switch to use Curl_hash_destroy()

as after 4883f7019d3, the *_clean() function only flushes the hash.

9 years agocurlver: restore LIBCURL_VERSION_NUM defined as a full number
Daniel Stenberg [Mon, 18 May 2015 09:28:44 +0000 (11:28 +0200)]
curlver: restore LIBCURL_VERSION_NUM defined as a full number

As it breaks configure, curl-config and test 1023 if not.

9 years agohostip: fix unintended destruction of hash table
Anthony Avina [Sat, 2 May 2015 18:49:55 +0000 (13:49 -0500)]
hostip: fix unintended destruction of hash table

.. and added unit1602 for hash.c

9 years agocurlver: introducing new version number (checking) macros
Daniel Stenberg [Thu, 14 May 2015 21:33:27 +0000 (23:33 +0200)]
curlver: introducing new version number (checking) macros

9 years agoruntests.pl: use 'h2c' now, no -14 anymore
Daniel Stenberg [Mon, 18 May 2015 08:10:55 +0000 (10:10 +0200)]
runtests.pl: use 'h2c' now, no -14 anymore

9 years agohttp2: Ignore if we have stream ID not in hash in on_stream_close
Tatsuhiro Tsujikawa [Sat, 16 May 2015 09:13:10 +0000 (18:13 +0900)]
http2: Ignore if we have stream ID not in hash in on_stream_close

We could get stream ID not in the hash in on_stream_close.  For
example, if we decided to reject stream (e.g., PUSH_PROMISE), then we
don't create stream and store it in hash with its stream ID.

9 years agoRequire nghttp2 v1.0.0
Tatsuhiro Tsujikawa [Sat, 16 May 2015 09:03:47 +0000 (18:03 +0900)]
Require nghttp2 v1.0.0

This commit requires nghttp2 v1.0.0 to compile, and migrate to v1.0.0,
and utilize recent version of nghttp2 to simplify the code,

First we use nghttp2_option_set_no_recv_client_magic function to
detect nghttp2 v1.0.0.  That function only exists since v1.0.0.

Since nghttp2 v0.7.5, nghttp2 ensures header field ordering, and
validates received header field.  If it found error, RST_STREAM with
PROTOCOL_ERROR is issued.  Since we require v1.0.0, we can utilize
this feature to simplify libcurl code.  This commit does this.

Migration from 0.7 series are done based on nghttp2 migration
document.  For libcurl, we removed the code sending first 24 bytes
client magic.  It is now done by nghttp2 library.
on_invalid_frame_recv callback signature changed, and is updated
accordingly.