curl/src
Dan McNulty 8996300211 schannel: add support for CURLOPT_CAINFO
- Move verify_certificate functionality in schannel.c into a new
  file called schannel_verify.c. Additionally, some structure defintions
  from schannel.c have been moved to schannel.h to allow them to be
  used in schannel_verify.c.

- Make verify_certificate functionality for Schannel available on
  all versions of Windows instead of just Windows CE. verify_certificate
  will be invoked on Windows CE or when the user specifies
  CURLOPT_CAINFO and CURLOPT_SSL_VERIFYPEER.

- In verify_certificate, create a custom certificate chain engine that
  exclusively trusts the certificate store backed by the CURLOPT_CAINFO
  file.

- doc updates of --cacert/CAINFO support for schannel

- Use CERT_NAME_SEARCH_ALL_NAMES_FLAG when invoking CertGetNameString
  when available. This implements a TODO in schannel.c to improve
  handling of multiple SANs in a certificate. In particular, all SANs
  will now be searched instead of just the first name.

- Update tool_operate.c to not search for the curl-ca-bundle.crt file
  when using Schannel to maintain backward compatibility. Previously,
  any curl-ca-bundle.crt file found in that search would have been
  ignored by Schannel. But, with CAINFO support, the file found by
  that search would have been used as the certificate store and
  could cause issues for any users that have curl-ca-bundle.crt in
  the search path.

- Update url.c to not set the build time CURL_CA_BUNDLE if the selected
  SSL backend is Schannel. We allow setting CA location for schannel
  only when explicitly specified by the user via CURLOPT_CAINFO /
  --cacert.

- Add new test cases 3000 and 3001. These test cases check that the first
  and last SAN, respectively, matches the connection hostname. New test
  certificates have been added for these cases. For 3000, the certificate
  prefix is Server-localhost-firstSAN and for 3001, the certificate
  prefix is Server-localhost-secondSAN.

- Remove TODO 15.2 (Add support for custom server certificate
  validation), this commit addresses it.

Closes https://github.com/curl/curl/pull/1325
2018-04-18 03:59:47 -04:00
..
macos docs/comments: Update to secure URL versions 2017-08-08 21:41:07 +02:00
.gitignore VC: remove the makefile.vc6 build infra 2017-01-23 14:27:32 +01:00
CMakeLists.txt cmake: Correctly include curl.rc in Windows builds (#2064) 2017-11-10 13:58:10 +03:00
curl.rc *.rc: escape non-ASCII/non-UTF-8 character for clarity 2017-01-19 11:35:48 +00:00
Makefile.am make: fix docs build on OpenBSD 2017-07-10 13:54:02 +02:00
makefile.amiga s/cURL/curl 2016-11-07 10:36:23 +01:00
Makefile.b32 URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
makefile.dj curl: remove tool_writeenv.[ch] 2017-05-06 23:13:08 +02:00
Makefile.inc time-cond: fix reading the file modification time on Windows 2018-02-05 22:02:10 +01:00
Makefile.m32 src/Makefile.m32: fix typo in brotli lib customization 2017-11-06 01:05:52 +00:00
Makefile.netware spelling fixes 2018-02-23 23:29:01 +00:00
Makefile.Watcom s/cURL/curl 2016-11-07 10:36:23 +01:00
mkhelp.pl mkhelp.pl: support reproducible build 2017-10-30 19:27:49 +01:00
slist_wc.c URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
slist_wc.h URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_binmode.c URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_binmode.h URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_bname.c URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_bname.h URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_cb_dbg.c code style: use spaces around pluses 2017-09-11 09:29:50 +02:00
tool_cb_dbg.h curl: fix callback functions to match prototype 2017-03-30 14:59:14 +02:00
tool_cb_hdr.c curl: don't pass semicolons when parsing Content-Disposition 2017-10-09 10:37:27 +02:00
tool_cb_hdr.h curl: fix callback argument inconsistency 2017-03-29 10:05:12 +02:00
tool_cb_prg.c build: fix termios issue on android cross-compile 2018-02-01 08:07:45 +01:00
tool_cb_prg.h curl: progress bar refresh, get width using ioctl() 2018-01-22 08:29:37 +01:00
tool_cb_rea.c URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_cb_rea.h URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_cb_see.c URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_cb_see.h URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_cb_wrt.c tool_cb_wrt: fix variable shadowing warning 2017-07-09 14:38:10 +02:00
tool_cb_wrt.h curl: fix callback argument inconsistency 2017-03-29 10:05:12 +02:00
tool_cfgable.c url: Add option CURLOPT_HAPPY_EYEBALLS_TIMEOUT 2018-02-20 17:51:43 -05:00
tool_cfgable.h CURLOPT_HAPROXYPROTOCOL: support the HAProxy PROXY protocol 2018-03-17 11:50:06 +01:00
tool_convert.c URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_convert.h URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_dirhie.c Fixes for MSDOS etc. 2018-01-24 15:02:53 +01:00
tool_dirhie.h URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_doswin.c schannel: add support for CURLOPT_CAINFO 2018-04-18 03:59:47 -04:00
tool_doswin.h schannel: add support for CURLOPT_CAINFO 2018-04-18 03:59:47 -04:00
tool_easysrc.c code style: use spaces around equals signs 2017-09-11 09:29:50 +02:00
tool_easysrc.h mime: use in curl cli tool instead of form API. 2017-09-02 18:17:33 +01:00
tool_filetime.c time-cond: fix reading the file modification time on Windows 2018-02-05 22:02:10 +01:00
tool_filetime.h time-cond: fix reading the file modification time on Windows 2018-02-05 22:02:10 +01:00
tool_formparse.c all: Refactor malloc+memset to use calloc 2018-04-15 03:00:37 -04:00
tool_formparse.h mime: use in curl cli tool instead of form API. 2017-09-02 18:17:33 +01:00
tool_getparam.c CURLOPT_HAPROXYPROTOCOL: support the HAProxy PROXY protocol 2018-03-17 11:50:06 +01:00
tool_getparam.h curl: detect and bail out early on parameter integer overflows 2017-08-07 09:38:45 +02:00
tool_getpass.c Improve code readbility 2017-03-13 23:11:45 +01:00
tool_getpass.h checksrc: code style: use 'char *name' style 2016-11-24 23:58:22 +01:00
tool_help.c CURLOPT_HAPROXYPROTOCOL: support the HAProxy PROXY protocol 2018-03-17 11:50:06 +01:00
tool_help.h URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_helpers.c curl: detect and bail out early on parameter integer overflows 2017-08-07 09:38:45 +02:00
tool_helpers.h URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_homedir.c tool: fix Windows Unicode build 2017-04-04 23:04:29 +02:00
tool_homedir.h URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_hugehelp.c.cvs tests: checksrc compliance 2016-12-19 02:31:59 -05:00
tool_hugehelp.h URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_libinfo.c strcase: make the tool use curl_str[n]equal instead 2016-10-31 21:51:19 +01:00
tool_libinfo.h URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_main.c tool_main: turn off MinGW CRT's globbing 2017-08-22 09:21:23 +02:00
tool_main.h URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_metalink.c cleanup: misc typos in strings and comments 2018-03-16 11:08:31 +01:00
tool_metalink.h URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_msgs.c curl: support >256 bytes warning messsages 2017-12-12 19:59:29 +01:00
tool_msgs.h URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_operate.c schannel: add support for CURLOPT_CAINFO 2018-04-18 03:59:47 -04:00
tool_operate.h URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_operhlp.c strcasecompare: all case insensitive string compares ignore locale now 2016-10-31 08:46:35 +01:00
tool_operhlp.h URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_panykey.c URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_panykey.h URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_paramhlp.c curl: make str2udouble not return values on error 2017-09-18 10:45:29 +02:00
tool_paramhlp.h curl: detect and bail out early on parameter integer overflows 2017-08-07 09:38:45 +02:00
tool_parsecfg.c code style: use spaces around equals signs 2017-09-11 09:29:50 +02:00
tool_parsecfg.h URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_sdecls.h mime: use in curl cli tool instead of form API. 2017-09-02 18:17:33 +01:00
tool_setopt.c form/mime: field names are not allowed to contain zero-valued bytes. 2017-09-22 01:08:29 +01:00
tool_setopt.h mime: use in curl cli tool instead of form API. 2017-09-02 18:17:33 +01:00
tool_setup.h URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_sleep.c tool_sleep: typecast to avoid macos compiler warning 2017-07-04 10:27:36 +02:00
tool_sleep.h URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_strdup.c code style: use spaces around pluses 2017-09-11 09:29:50 +02:00
tool_strdup.h URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_urlglob.c curl: pass through [] in URLs instead of calling globbing error 2017-11-04 10:23:27 +01:00
tool_urlglob.h checksrc: white space edits to comply to stricter checksrc 2016-11-24 23:58:22 +01:00
tool_util.c tool_util: remove unused tvdiff_secs and remove tool_ prefix 2017-06-03 00:11:59 +02:00
tool_util.h tool_util: remove unused tvdiff_secs and remove tool_ prefix 2017-06-03 00:11:59 +02:00
tool_version.h URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_vms.c code: style updates 2016-04-03 22:38:36 +02:00
tool_vms.h URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_writeout.c curl: check for end of input in writeout backslash handling 2017-03-25 23:48:57 +01:00
tool_writeout.h URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
tool_xattr.c docs/comments: Update to secure URL versions 2017-08-08 21:41:07 +02:00
tool_xattr.h URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00