]> git.ipfire.org Git - thirdparty/curl.git/log
thirdparty/curl.git
5 years agosocks: make the connect phase non-blocking
Daniel Stenberg [Fri, 14 Feb 2020 15:16:54 +0000 (16:16 +0100)] 
socks: make the connect phase non-blocking

Removes two entries from KNOWN_BUGS.

Closes #4907

5 years agomulti: if Curl_readwrite sets 'comeback' use expire, not loop
Daniel Stenberg [Fri, 14 Feb 2020 15:54:06 +0000 (16:54 +0100)] 
multi: if Curl_readwrite sets 'comeback' use expire, not loop

Otherwise, a very fast single transfer ricks starving out other
concurrent transfers.

Closes #4927

5 years agoftp: convert 'sock_accepted' to a plain boolean
Daniel Stenberg [Fri, 14 Feb 2020 23:00:45 +0000 (00:00 +0100)] 
ftp: convert 'sock_accepted' to a plain boolean

This was an array indexed with sockindex but it was only ever used for
the secondary socket.

Closes #4929

5 years agoCURLINFO_COOKIELIST.3: Fix example
Jay Satiro [Sat, 15 Feb 2020 23:17:31 +0000 (18:17 -0500)] 
CURLINFO_COOKIELIST.3: Fix example

Prior to this change the example would try to import cookies from stdin,
which wasn't what was intended.

Reported-by: 3dyd@users.noreply.github.com
Fixes https://github.com/curl/curl/issues/4930

5 years agoTODO: Paged searches on LDAP server
Daniel Stenberg [Fri, 14 Feb 2020 22:05:38 +0000 (23:05 +0100)] 
TODO: Paged searches on LDAP server

Closes #4452

5 years agoTODO: CURLOPT_SSL_CTX_FUNCTION for LDAPS
Daniel Stenberg [Fri, 14 Feb 2020 22:03:21 +0000 (23:03 +0100)] 
TODO: CURLOPT_SSL_CTX_FUNCTION for LDAPS

Closes #4108

5 years agoazure: disable brotli on the macos debug-builds
Daniel Stenberg [Fri, 14 Feb 2020 13:10:56 +0000 (14:10 +0100)] 
azure: disable brotli on the macos debug-builds

Because of:

brotli/decode.h:204:33: error: variable length array used [-Werror,-Wvla]
    const uint8_t encoded_buffer[BROTLI_ARRAY_PARAM(encoded_size)],

Closes #4925

5 years agotool_home: Fix the copyright year being out of date
Steve Holme [Thu, 13 Feb 2020 00:40:08 +0000 (00:40 +0000)] 
tool_home: Fix the copyright year being out of date

Follow up to 9dc350b6.

5 years agotool_homedir: Change GetEnv() to use libcurl's curl_getenv()
Jay Satiro [Wed, 29 Jan 2020 08:23:55 +0000 (03:23 -0500)] 
tool_homedir: Change GetEnv() to use libcurl's curl_getenv()

- Deduplicate GetEnv() code.

- On Windows change ultimate call to use Windows API
  GetEnvironmentVariable() instead of C runtime getenv().

Prior to this change both libcurl and the tool had their own GetEnv
which over time diverged. Now the tool's GetEnv is a wrapper around
curl_getenv (libcurl API function which is itself a wrapper around
libcurl's GetEnv).

Furthermore this change fixes a bug in that Windows API
GetEnvironmentVariable() is called instead of C runtime getenv() to get
the environment variable since some changes aren't always visible to the
latter.

Reported-by: Christoph M. Becker
Fixes https://github.com/curl/curl/issues/4774
Closes https://github.com/curl/curl/pull/4863

5 years agostrerror.h: Copyright year out of date
Daniel Stenberg [Wed, 12 Feb 2020 22:07:04 +0000 (23:07 +0100)] 
strerror.h: Copyright year out of date

Follow-up to 1c4fa67e8a8fcf6

5 years agostrerror: Increase STRERROR_LEN 128 -> 256
Jay Satiro [Wed, 12 Feb 2020 21:48:16 +0000 (16:48 -0500)] 
strerror: Increase STRERROR_LEN 128 -> 256

STRERROR_LEN is the constant used throughout the library to set the size
of the buffer on the stack that the curl strerror functions write to.

Prior to this change some extended length Windows error messages could
be truncated.

Closes https://github.com/curl/curl/pull/4920

5 years agomulti: fix outdated comment
Jay Satiro [Sun, 9 Feb 2020 08:15:13 +0000 (03:15 -0500)] 
multi: fix outdated comment

- Do not say that conn->data is "cleared" by multi_done().

If the connection is in use then multi_done assigns another easy handle
still using the connection to conn->data, therefore in that case it is
not cleared.

Closes https://github.com/curl/curl/pull/4901

5 years agoeasy: remove dead code
Jay Satiro [Sun, 9 Feb 2020 07:41:33 +0000 (02:41 -0500)] 
easy: remove dead code

multi is already assigned to data->multi by curl_multi_add_handle.

Closes https://github.com/curl/curl/pull/4900

5 years agocreate-dirs.d: mention the mode
Daniel Stenberg [Wed, 12 Feb 2020 21:30:45 +0000 (22:30 +0100)] 
create-dirs.d: mention the mode

Reported-by: Dan Jacobson
Fixes #4766
Closes #4916

5 years agoCURLOPT_ALTSVC_CTRL.3: fix the DEFAULT wording
Daniel Stenberg [Tue, 11 Feb 2020 14:42:25 +0000 (15:42 +0100)] 
CURLOPT_ALTSVC_CTRL.3: fix the DEFAULT wording

Assisted-by: Jay Satiro
Reported-by: Craig Andrews
Fixes #4909
Closes #4910

5 years agoRELEASE-NOTES: synced
Daniel Stenberg [Mon, 10 Feb 2020 07:49:27 +0000 (08:49 +0100)] 
RELEASE-NOTES: synced

5 years agosmtp: Simplify the MAIL command and avoid a duplication of send strings
Steve Holme [Sun, 9 Feb 2020 15:50:57 +0000 (15:50 +0000)] 
smtp: Simplify the MAIL command and avoid a duplication of send strings

This avoids the duplication of strings when the optional AUTH and SIZE
parameters are required. It also assists with the modifications that
are part of #4892.

Closes #4903

5 years agoaltsvc: keep a copy of the file name to survive handle reset
Daniel Stenberg [Sun, 9 Feb 2020 14:28:03 +0000 (15:28 +0100)] 
altsvc: keep a copy of the file name to survive handle reset

The alt-svc cache survives a call to curl_easy_reset fine, but the file
name to use for saving the cache was cleared. Now the alt-svc cache has
a copy of the file name to survive handle resets.

Added test 1908 to verify.

Reported-by: Craig Andrews
Fixes #4898
Closes #4902

5 years agourl: Include the failure reason when curl_win32_idn_to_ascii() fails
Steve Holme [Sun, 9 Feb 2020 04:37:52 +0000 (04:37 +0000)] 
url: Include the failure reason when curl_win32_idn_to_ascii() fails

Provide the failure reason in the failf() info just as we do for the
libidn2 version of code.

Closes #4899

5 years agoasyn-thread: remove dead code
Jay Satiro [Sun, 9 Feb 2020 07:25:44 +0000 (02:25 -0500)] 
asyn-thread: remove dead code

5 years agogithub: Instructions to post "uname -a" on Unix systems in issues
Emil Engler [Sat, 8 Feb 2020 10:23:54 +0000 (11:23 +0100)] 
github: Instructions to post "uname -a" on Unix systems in issues

Closes #4896

5 years agoconfigure.ac: fix comments about --with-quiche
Cristian Greco [Sat, 8 Feb 2020 14:28:33 +0000 (14:28 +0000)] 
configure.ac: fix comments about --with-quiche

A simple s/nghttp3/quiche in some comments of --with-quiche.
Looks like a copy-paste error from --with-nghttp3.

Closes #4897

5 years agochecksrc.bat: Fix not being able to run script from the main curl directory
Steve Holme [Fri, 7 Feb 2020 16:51:09 +0000 (16:51 +0000)] 
checksrc.bat: Fix not being able to run script from the main curl directory

If the script was ran from the main curl directory rather then the
projects directory then the script would simply exit without error:

C:\url> projects\checksrc.bat

The user would either need to change to the projects directory,
explicitly specify the current working directory, or perform a
oneline hacky workaround:

C:\url> cd projects
C:\url\projects> checksrc.bat

C:\url> checksrc.bat %cd%

C:\url> pushd projects & checksrc.bat & popd

Closes #4894

5 years agodigest: Do not quote algorithm in HTTP authorisation
Pierre-Yves Bigourdan [Thu, 6 Feb 2020 15:43:06 +0000 (15:43 +0000)] 
digest: Do not quote algorithm in HTTP authorisation

RFC 7616 section 3.4 (The Authorization Header Field) states that "For
historical reasons, a sender MUST NOT generate the quoted string syntax
for the following parameters: algorithm, qop, and nc". This removes the
quoting for the algorithm parameter.

Reviewed-by: Steve Holme
Closes #4890

5 years agoftp: remove the duplicated user/password struct fields
Daniel Stenberg [Thu, 6 Feb 2020 14:59:18 +0000 (15:59 +0100)] 
ftp: remove the duplicated user/password struct fields

Closes #4887

5 years agoftp: remove superfluous checking for crlf in user or pwd
Daniel Stenberg [Thu, 6 Feb 2020 10:36:53 +0000 (11:36 +0100)] 
ftp: remove superfluous checking for crlf in user or pwd

... as this is already done much earlier in the URL parser.

Also add test case 894 that verifies that pop3 with an encodedd CR in
the user name is rejected.

Closes #4887

5 years agontlm_wb: Use Curl_socketpair() for greater portability
Steve Holme [Wed, 5 Feb 2020 16:08:56 +0000 (16:08 +0000)] 
ntlm_wb: Use Curl_socketpair() for greater portability

Reported-by: Daniel Stenberg
Closes #4886

5 years agocontributors: Also include people who contributed to curl-www
Frank Gevaerts [Wed, 5 Feb 2020 10:45:47 +0000 (11:45 +0100)] 
contributors: Also include people who contributed to curl-www

Closes #4884

5 years agocontrithanks: Use the most recent tag by default
Frank Gevaerts [Wed, 5 Feb 2020 10:34:07 +0000 (11:34 +0100)] 
contrithanks: Use the most recent tag by default

(similar to 5296abe)

Closes #4883

5 years agoscripts: use last set tag if none given
Daniel Stenberg [Wed, 5 Feb 2020 06:48:18 +0000 (07:48 +0100)] 
scripts: use last set tag if none given

Makes 'delta' and 'contributors.sh' easier to use.

Make the delta script invoke contrithanks to get current number of
contributors instead of counting THANKS, for accuracy.

Closes #4881

5 years agoftp: shrink temp buffers used for PORT
Daniel Stenberg [Tue, 4 Feb 2020 22:27:39 +0000 (23:27 +0100)] 
ftp: shrink temp buffers used for PORT

These two stack based buffers only need to be 46 + 66 bytes instead of
256 + 1024.

Closes #4880

5 years agocurl: error on --alt-svc use w/o support
Daniel Stenberg [Tue, 4 Feb 2020 16:32:55 +0000 (17:32 +0100)] 
curl: error on --alt-svc use w/o support

Make the tool check for alt-svc support at run-time and return error
accordingly if not present when the option is used.

Reported-by: Harry Sintonen
Closes #4878

5 years agodocs/HTTP3: add --enable-alt-svc to curl's configure
Daniel Stenberg [Tue, 4 Feb 2020 23:25:12 +0000 (00:25 +0100)] 
docs/HTTP3: add --enable-alt-svc to curl's configure

5 years agoRELEASE-PROCEDURE: feature win is closed post-release a few days
Daniel Stenberg [Tue, 4 Feb 2020 15:29:28 +0000 (16:29 +0100)] 
RELEASE-PROCEDURE: feature win is closed post-release a few days

We've tried to uphold this already but let's make it official by
publicly stating this is the way we do it.

Closes #4877

5 years agoaltsvc: set h3 version at a common single spot
Daniel Stenberg [Tue, 4 Feb 2020 14:12:44 +0000 (15:12 +0100)] 
altsvc: set h3 version at a common single spot

... and move the #ifdefs out of the functions. Addresses the fact they
were different before this change.

Reported-by: Harry Sintonen
Closes #4876

5 years agoaltsvc: improved header parser
Harry Sintonen [Tue, 4 Feb 2020 04:21:58 +0000 (06:21 +0200)] 
altsvc: improved header parser

- Fixed the flag parsing to apply to specific alternative entry only, as
per RFC. The earlier code would also get totally confused by
multiprotocol header, parsing flags from the wrong part of the header.

- Fixed the parser terminating on unknown protocols, instead of skipping
them.

- Fixed a busyloop when protocol-id was present without an equal sign.

Closes #4875

5 years agongtcp2: fixed to only use AF_INET6 when ENABLE_IPV6
Harry Sintonen [Mon, 3 Feb 2020 22:58:38 +0000 (00:58 +0200)] 
ngtcp2: fixed to only use AF_INET6 when ENABLE_IPV6

5 years agodocs/HTTP3: update the OpenSSL branch to use for ngtcp2
Daniel Stenberg [Tue, 4 Feb 2020 14:05:57 +0000 (15:05 +0100)] 
docs/HTTP3: update the OpenSSL branch to use for ngtcp2

Reported-by: James Fuller
5 years agontlm: Pass the Curl_easy structure to the private winbind functions
Steve Holme [Wed, 8 May 2019 08:36:51 +0000 (09:36 +0100)] 
ntlm: Pass the Curl_easy structure to the private winbind functions

...rather than the full conndata structure.

5 years agoRELEASE-NOTES: synced
Daniel Stenberg [Tue, 4 Feb 2020 09:33:38 +0000 (10:33 +0100)] 
RELEASE-NOTES: synced

5 years agotool_operhlp: Copyright year out of date, should be 2020
Daniel Stenberg [Tue, 4 Feb 2020 07:29:41 +0000 (08:29 +0100)] 
tool_operhlp: Copyright year out of date, should be 2020

Follow-up from 2bc373740a3

5 years agocurl: avoid using strlen for testing if a string is empty
Orgad Shaneh [Mon, 3 Feb 2020 09:42:46 +0000 (11:42 +0200)] 
curl: avoid using strlen for testing if a string is empty

Closes #4873

5 years agontlm: Ensure the HTTP header data is not stored in the challenge/response
Steve Holme [Wed, 8 May 2019 23:30:09 +0000 (00:30 +0100)] 
ntlm: Ensure the HTTP header data is not stored in the challenge/response

5 years agoopenssl: remove redundant assignment
Marcel Raad [Sun, 2 Feb 2020 12:35:54 +0000 (13:35 +0100)] 
openssl: remove redundant assignment

Fixes a scan-build failure on Bionic.

Closes https://github.com/curl/curl/pull/4872

5 years agotravis: update non-OpenSSL Linux jobs to Bionic
Marcel Raad [Sun, 2 Feb 2020 08:56:21 +0000 (09:56 +0100)] 
travis: update non-OpenSSL Linux jobs to Bionic

For the OpenSSL builds, test 323 [TLS-SRP to non-TLS-SRP server] is
failing with "curl returned 52, when expecting 35".

Closes https://github.com/curl/curl/pull/4872

5 years agocirrus: Add some missing semicolons
Dan Fandrich [Mon, 3 Feb 2020 11:27:30 +0000 (12:27 +0100)] 
cirrus: Add some missing semicolons

Newlines aren't preserved in this section so they're needed to separate
commands. The exports luckily worked anyway as a single long line, but
erroneously exported a variable called "export"
[skip ci]

5 years agocleanup: fix typos and wording in docs and comments
Pedro Monreal [Sun, 2 Feb 2020 08:49:28 +0000 (09:49 +0100)] 
cleanup: fix typos and wording in docs and comments

Closes #4869
Reviewed-by: Emil Engler and Daniel Gustafsson
5 years agontlm: Move the winbind data into the NTLM data structure
Steve Holme [Tue, 7 May 2019 22:36:52 +0000 (23:36 +0100)] 
ntlm: Move the winbind data into the NTLM data structure

To assist with adding winbind support to the SASL NTLM authentication,
move the winbind specific data out of conndata into ntlmdata.

5 years agoquiche: Copyright year out of date
Daniel Stenberg [Thu, 30 Jan 2020 18:13:01 +0000 (19:13 +0100)] 
quiche: Copyright year out of date

Follow-up to 7fc63d72333a

5 years agoaltsvc: use h3-25
Daniel Stenberg [Thu, 30 Jan 2020 15:02:27 +0000 (16:02 +0100)] 
altsvc: use h3-25

Closes #4868

5 years agoquiche: update to draft-25
Alessandro Ghedini [Thu, 30 Jan 2020 13:06:31 +0000 (13:06 +0000)] 
quiche: update to draft-25

Closes #4867

5 years agongtcp2: update to git master and its draft-25 support
Daniel Stenberg [Wed, 29 Jan 2020 14:56:16 +0000 (15:56 +0100)] 
ngtcp2: update to git master and its draft-25 support

Closes #4865

5 years agocookie: check __Secure- and __Host- case sensitively
Daniel Stenberg [Wed, 29 Jan 2020 08:57:50 +0000 (09:57 +0100)] 
cookie: check __Secure- and __Host- case sensitively

While most keywords in cookies are case insensitive, these prefixes are
specified explicitly to get checked "with a case-sensitive match".

(From the 6265bis document in progress)

Ref: https://tools.ietf.org/html/draft-ietf-httpbis-rfc6265bis-04
Closes #4864

5 years agoKNOWN_BUGS: Multiple methods in a single WWW-Authenticate: header
Daniel Stenberg [Wed, 29 Jan 2020 06:57:42 +0000 (07:57 +0100)] 
KNOWN_BUGS: Multiple methods in a single WWW-Authenticate: header

5 years agooauth2-bearer.d: works for HTTP too
Daniel Stenberg [Tue, 28 Jan 2020 21:27:15 +0000 (22:27 +0100)] 
oauth2-bearer.d: works for HTTP too

Reported-by: Mischa Salle
Bug: https://curl.haxx.se/mail/lib-2020-01/0070.html
Closes #4862

5 years agomulti_done: if multiplexed, make conn->data point to another transfer
Daniel Stenberg [Mon, 27 Jan 2020 21:50:33 +0000 (22:50 +0100)] 
multi_done: if multiplexed, make conn->data point to another transfer

... since the current transfer is being killed. Setting to NULL is
wrong, leaving it pointing to 'data' is wrong since that handle might be
about to get freed.

Fixes #4845
Closes #4858
Reported-by: dmitrmax on github
5 years agolocation.d: the method change is from POST to GET only
Daniel Stenberg [Tue, 28 Jan 2020 09:41:10 +0000 (10:41 +0100)] 
location.d: the method change is from POST to GET only

Not from generic non-GET to GET.

Reported-by: Andrius Merkys
Ref: #4859
Closes #4861

5 years agourlapi: guess scheme correct even with credentials given
Daniel Stenberg [Mon, 27 Jan 2020 16:28:40 +0000 (17:28 +0100)] 
urlapi: guess scheme correct even with credentials given

In the "scheme-less" parsing case, we need to strip off credentials
first before we guess scheme based on the host name!

Assisted-by: Jay Satiro
Fixes #4856
Closes #4857

5 years agoglobal_init: move the IPv6 works status bool to multi handle
Daniel Stenberg [Sun, 26 Jan 2020 16:51:01 +0000 (17:51 +0100)] 
global_init: move the IPv6 works status bool to multi handle

Previously it was stored in a global state which contributed to
curl_global_init's thread unsafety. This boolean is now instead figured
out in curl_multi_init() and stored in the multi handle. Less effective,
but thread safe.

Closes #4851

5 years agoREADME: mention that the docs is in docs/
Jay Satiro [Mon, 27 Jan 2020 08:15:26 +0000 (09:15 +0100)] 
README: mention that the docs is in docs/

Reported-by: Austin Green
Fixes #4830
Closes #4853

5 years agocurl.h: define CURL_WIN32 on windows
Daniel Stenberg [Mon, 27 Jan 2020 10:37:33 +0000 (11:37 +0100)] 
curl.h: define CURL_WIN32 on windows

... so that the subsequent logic below can use a single known define to know
when built on Windows (as we don't define WIN32 anymore).

Follow-up to 1adebe7886ddf20b

Reported-by: crazydef on github
Assisted-by: Marcel Raad
Fixes #4854
Closes #4855

5 years agoRELEASE-NOTES: synced
Daniel Stenberg [Mon, 27 Jan 2020 08:44:33 +0000 (09:44 +0100)] 
RELEASE-NOTES: synced

5 years agourldata: do string enums without #ifdefs for build scripts
Jon Rumsey [Mon, 27 Jan 2020 08:23:43 +0000 (09:23 +0100)] 
urldata: do string enums without #ifdefs for build scripts

... and check for inconsistencies for OS400 at build time with the new
chkstrings tool.

Closes #4822

5 years agocurl: make the -# spaceship bar not wrap the line
Daniel Stenberg [Sat, 25 Jan 2020 15:46:41 +0000 (16:46 +0100)] 
curl: make the -# spaceship bar not wrap the line

The fixed-point math made us lose precision and thus a too high index
value could be used for outputting the hashtags which could overwrite
the newline.

The fix increases the precision in the sine table (*100) and the
associated position math.

Reported-by: Andrew Potter
Fixes #4849
Closes #4850

5 years agoglobal_init: assume the EINTR bit by default
Daniel Stenberg [Thu, 23 Jan 2020 12:39:27 +0000 (13:39 +0100)] 
global_init: assume the EINTR bit by default

- Removed from global_init since it isn't thread-safe. The symbol will
  still remain to not break compiles, it just won't have any effect going
  forward.

- make the internals NOT loop on EINTR (the opposite from previously).
  It only risks returning from the select/poll/wait functions early, and that
  should be risk-free.

Closes #4840

5 years agoconn: do not reuse connection if SOCKS proxy credentials differ
Peter Piekarski [Mon, 20 Jan 2020 17:02:09 +0000 (18:02 +0100)] 
conn: do not reuse connection if SOCKS proxy credentials differ

Closes #4835

5 years agollist: removed unused Curl_llist_move()
Daniel Stenberg [Thu, 23 Jan 2020 08:15:39 +0000 (09:15 +0100)] 
llist: removed unused Curl_llist_move()

(and the corresponding unit test)

Closes #4842

5 years agoconncache: removed unused Curl_conncache_bundle_size()
Daniel Stenberg [Thu, 23 Jan 2020 08:03:29 +0000 (09:03 +0100)] 
conncache: removed unused Curl_conncache_bundle_size()

5 years agostrcase: turn Curl_raw_tolower into static
Daniel Stenberg [Thu, 23 Jan 2020 08:01:25 +0000 (09:01 +0100)] 
strcase: turn Curl_raw_tolower into static

Only ever used from within this file.

5 years agosingleuse.pl: support new API functions, fix curl_dbg_ handling
Daniel Stenberg [Thu, 23 Jan 2020 07:59:22 +0000 (08:59 +0100)] 
singleuse.pl: support new API functions, fix curl_dbg_ handling

5 years agowolfssh: make it init properly via Curl_ssh_init()
Daniel Stenberg [Thu, 23 Jan 2020 19:05:22 +0000 (20:05 +0100)] 
wolfssh: make it init properly via Curl_ssh_init()

Closes #4846

5 years agoform.d: fix two minor typos
Aron Rotteveel [Thu, 23 Jan 2020 08:24:30 +0000 (09:24 +0100)] 
form.d: fix two minor typos

Closes #4843

5 years agoopenssl: make CURLINFO_CERTINFO not truncate x509v3 fields
Daniel Stenberg [Wed, 22 Jan 2020 09:29:44 +0000 (10:29 +0100)] 
openssl: make CURLINFO_CERTINFO not truncate x509v3 fields

Avoid "reparsing" the content and instead deliver more exactly what is
provided in the certificate and avoid truncating the data after 512
bytes as done previously. This no longer removes embedded newlines.

Fixes #4837
Reported-by: bnfp on github
Closes #4841

5 years agoCURLOPT_PROXY_SSL_OPTIONS.3: Sync with CURLOPT_SSL_OPTIONS.3
Jay Satiro [Thu, 23 Jan 2020 07:51:52 +0000 (02:51 -0500)] 
CURLOPT_PROXY_SSL_OPTIONS.3: Sync with CURLOPT_SSL_OPTIONS.3

- Copy CURLOPT_SSL_OPTIONS.3 description to CURLOPT_PROXY_SSL_OPTIONS.3.

Prior to this change CURLSSLOPT_NO_PARTIALCHAIN was missing from the
CURLOPT_PROXY_SSL_OPTIONS description.

5 years agomk-ca-bundle: add support for CKA_NSS_SERVER_DISTRUST_AFTER
Daniel Stenberg [Mon, 20 Jan 2020 21:23:44 +0000 (22:23 +0100)] 
mk-ca-bundle: add support for CKA_NSS_SERVER_DISTRUST_AFTER

For now, no cert in the bundle actually sets a date there...

Co-Authored-by: Jay Satiro
Reported-by: Christian Heimes
Fixes #4834
Closes #4836

5 years agoRELEASE-NOTES: synced
Daniel Stenberg [Tue, 21 Jan 2020 14:15:31 +0000 (15:15 +0100)] 
RELEASE-NOTES: synced

5 years agosmtp: Allow RCPT TO command to fail for some recipients
Pavel Volgarev [Tue, 14 Jan 2020 22:22:38 +0000 (17:22 -0500)] 
smtp: Allow RCPT TO command to fail for some recipients

Introduces CURLOPT_MAIL_RCPT_ALLLOWFAILS.

Verified with the new tests 3002-3007

Closes #4816

5 years agocopyright: fix year ranges
Daniel Stenberg [Tue, 21 Jan 2020 09:34:44 +0000 (10:34 +0100)] 
copyright: fix year ranges

follow-up from dea17b519d (one of these days I'll learn to check before
I push)

5 years agohttp: move "oauth_bearer" from connectdata to Curl_easy
nao [Tue, 21 Jan 2020 09:30:37 +0000 (10:30 +0100)] 
http: move "oauth_bearer" from connectdata to Curl_easy

Fixes the bug where oauth_bearer gets deallocated when we re-use a
connection.

Closes #4824

5 years agocurl: Let -D merge headers in one file again
Emil Engler [Tue, 21 Jan 2020 08:23:21 +0000 (09:23 +0100)] 
curl: Let -D merge headers in one file again

Closes #4762
Fixes #4753

5 years agodata.d: remove "Multiple files can also be specified"
Daniel Stenberg [Tue, 21 Jan 2020 07:39:47 +0000 (08:39 +0100)] 
data.d: remove "Multiple files can also be specified"

It is superfluous and could even be misleading.

Bug: https://curl.haxx.se/mail/archive-2020-01/0016.html
Reported-by: Mike Norton
Closes #4832

5 years agoCMake: support specifying the target Windows version
Marcel Raad [Tue, 14 Jan 2020 19:28:20 +0000 (20:28 +0100)] 
CMake: support specifying the target Windows version

Previously, it was only possible to set it to Windows Vista or XP by
setting the option `ENABLE_INET_PTON` to `ON` resp. `OFF`.
Use a new cache variable `CURL_TARGET_WINDOWS_VERSION` to be able to
explicitly set the target Windows version. `ENABLE_INET_PTON` is
ignored in this case.

Ref: https://github.com/curl/curl/pull/1639#issuecomment-313039352
Ref: https://github.com/curl/curl/pull/4607#issuecomment-557541456
Closes https://github.com/curl/curl/pull/4815

5 years agohttp.h: Copyright year out of date, should be 2020
Daniel Stenberg [Mon, 20 Jan 2020 07:37:21 +0000 (08:37 +0100)] 
http.h: Copyright year out of date, should be 2020

Follow-up to 7ff9222ced8c

5 years agoHTTP: increase EXPECT_100_THRESHOLD to 1Mb
加藤郁之 [Tue, 14 Jan 2020 14:34:56 +0000 (23:34 +0900)] 
HTTP: increase EXPECT_100_THRESHOLD to 1Mb

Mentioned: https://curl.haxx.se/mail/lib-2020-01/0050.html

Closes #4814

5 years agoROADMAP: thread-safe `curl_global_init()`
Daniel Stenberg [Fri, 17 Jan 2020 11:58:35 +0000 (12:58 +0100)] 
ROADMAP: thread-safe `curl_global_init()`

I'd like to see this happen.

5 years agoRELEASE-NOTES: synced
Daniel Stenberg [Fri, 17 Jan 2020 07:08:36 +0000 (08:08 +0100)] 
RELEASE-NOTES: synced

5 years agowolfssl: use the wc-prefixed symbol alternatives
Daniel Stenberg [Thu, 16 Jan 2020 14:59:56 +0000 (15:59 +0100)] 
wolfssl: use the wc-prefixed symbol alternatives

The symbols without wc_ prefix are not always provided.

Ref: https://github.com/wolfSSL/wolfssl/issues/2744

Closes #4827

5 years agopolarssl: removed
Daniel Stenberg [Thu, 16 Jan 2020 07:17:04 +0000 (08:17 +0100)] 
polarssl: removed

As detailed in DEPRECATE.md, the polarssl support is now removed after
having been disabled for 6 months and nobody has missed it.

The threadlock files used by mbedtls are renamed to an 'mbedtls' prefix
instead of the former 'polarssl' and the common functions that
previously were shared between mbedtls and polarssl and contained the
name 'polarssl' have now all been renamed to instead say 'mbedtls'.

Closes #4825

5 years agolibssh2: fix variable type
Marcel Raad [Wed, 15 Jan 2020 19:28:01 +0000 (20:28 +0100)] 
libssh2: fix variable type

This led to a conversion warning on 64-bit MinGW, which has 32-bit
`long` but 64-bit `size_t`.

Closes https://github.com/curl/curl/pull/4823

5 years agocurl:progressbarinit: ignore column width from terminals < 20
Daniel Stenberg [Tue, 14 Jan 2020 21:18:12 +0000 (22:18 +0100)] 
curl:progressbarinit: ignore column width from terminals < 20

To avoid division by zero - or other issues.

Reported-by: Daniel Marjamäki
Closes #4818

5 years agowolfssh: set the password correctly for PASSWORD auth
Daniel Stenberg [Wed, 15 Jan 2020 13:23:03 +0000 (14:23 +0100)] 
wolfssh: set the password correctly for PASSWORD auth

5 years agowolfssh: remove fprintf() calls (and uses of __func__)
Daniel Stenberg [Wed, 15 Jan 2020 13:00:37 +0000 (14:00 +0100)] 
wolfssh: remove fprintf() calls (and uses of __func__)

5 years agoCMake: use check_symbol_exists also for inet_pton
Marcel Raad [Sat, 11 Jan 2020 10:20:38 +0000 (11:20 +0100)] 
CMake: use check_symbol_exists also for inet_pton

It doesn't make much sense to only check if the function can be linked
when it's not declared in any header and that is treated as an error.
With the correct target Windows version set, the function is declared
in ws2tcpip.h and the comment above the modified block is invalid.

Also, move the definition of `_WIN32_WINNT` up to before all symbol
availability checks so that we don't have to care which ones must be
done after it.

Tested with Visual Studio 2019 and current MinGW-w64.

Closes https://github.com/curl/curl/pull/4808

5 years agoschannel_verify: Fix alt names manual verify for UNICODE builds
Jay Satiro [Mon, 13 Jan 2020 23:25:12 +0000 (18:25 -0500)] 
schannel_verify: Fix alt names manual verify for UNICODE builds

Follow-up to 29e40a6 from two days ago, which added that feature for
Windows 7 and earlier. The bug only occurred in same.

Ref: https://github.com/curl/curl/pull/4761

5 years agoHTTP-COOKIES.md: describe the cookie file format
Daniel Stenberg [Fri, 10 Jan 2020 21:53:05 +0000 (22:53 +0100)] 
HTTP-COOKIES.md: describe the cookie file format

... and refer to that file from from CURLOPT_COOKIEFILE.3 and
CURLOPT_COOKIELIST.3

Assisted-by: Jay Satiro
Reported-by: bsammon on github
Fixes #4805
Closes #4806

5 years agoCMake: Add support for CMAKE_LTO option.
Tobias Hieta [Thu, 9 Jan 2020 11:10:55 +0000 (12:10 +0100)] 
CMake: Add support for CMAKE_LTO option.

This enables Link Time Optimization. LTO is a proven technique for
optimizing across compilation units.

Closes #4799

5 years agoRELEASE-NOTES: synced
Daniel Stenberg [Mon, 13 Jan 2020 15:02:01 +0000 (16:02 +0100)] 
RELEASE-NOTES: synced

5 years agoConnectionExists: respect the max_concurrent_streams limits
Daniel Stenberg [Sun, 5 Jan 2020 09:34:19 +0000 (10:34 +0100)] 
ConnectionExists: respect the max_concurrent_streams limits

A regression made the code use 'multiplexed' as a boolean instead of the
counter it is intended to be. This made curl try to "over-populate"
connections with new streams.

This regression came with 41fcdf71a1, shipped in curl 7.65.0.

Also, respect the CURLMOPT_MAX_CONCURRENT_STREAMS value in the same
check.

Reported-by: Kunal Ekawde
Fixes #4779
Closes #4784

5 years agocurl: make #0 not output the full URL
Daniel Stenberg [Mon, 13 Jan 2020 11:30:37 +0000 (12:30 +0100)] 
curl: make #0 not output the full URL

It was not intended nor documented!

Added test 1176 to verify.

Reported-by: vshmuk on hackerone
Closes #4812

5 years agowolfSSH: new SSH backend
Daniel Stenberg [Sun, 5 Jan 2020 09:51:39 +0000 (10:51 +0100)] 
wolfSSH: new SSH backend

Adds support for SFTP (not SCP) using WolfSSH.

Closes #4231