gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[gnurl] 149/151: Merge remote-tracking branch 'upstream/master'


From: gnunet
Subject: [gnurl] 149/151: Merge remote-tracking branch 'upstream/master'
Date: Fri, 20 Dec 2019 14:27:38 +0100

This is an automated email from the git hooks/post-receive script.

ng0 pushed a commit to branch master
in repository gnurl.

commit aad5bf997d388e2280af94e540b738364f50b70c
Merge: 70745a841 0caf1423e
Author: ng0 <address@hidden>
AuthorDate: Fri Dec 20 13:19:40 2019 +0000

    Merge remote-tracking branch 'upstream/master'

 .azure-pipelines.yml                            | 166 +++++
 .cirrus.yml                                     |  20 +-
 .mailmap                                        |   4 +
 .travis.yml                                     |  45 +-
 CMake/FindBearSSL.cmake                         |   9 +
 CMake/FindNSS.cmake                             |  15 +
 CMakeLists.txt                                  | 155 ++++-
 Makefile.am                                     |   9 +
 README.md                                       |   1 -
 RELEASE-NOTES                                   | 436 +++++-------
 configure.ac                                    | 126 +++-
 docs/ALTSVC.md                                  |   2 +-
 docs/CURL-DISABLE.md                            | 110 +++
 docs/ESNI.md                                    |   2 +-
 docs/FAQ                                        |   6 +-
 docs/HISTORY.md                                 |   9 +
 docs/HTTP-COOKIES.md                            |   2 +-
 docs/HTTP3.md                                   |   2 +-
 docs/INSTALL.md                                 |  58 +-
 docs/KNOWN_BUGS                                 |  18 +-
 docs/LICENSE-MIXING.md                          |   5 +
 docs/MANUAL.md                                  |   2 +-
 docs/Makefile.am                                |   1 +
 docs/PARALLEL-TRANSFERS.md                      |   2 +-
 docs/TODO                                       |  20 +-
 docs/cmdline-opts/Makefile.inc                  |   5 +-
 docs/cmdline-opts/alt-svc.d                     |   2 +-
 docs/cmdline-opts/etag-compare.d                |  18 +
 docs/cmdline-opts/etag-save.d                   |  16 +
 docs/cmdline-opts/http3.d                       |   2 +-
 docs/cmdline-opts/parallel-immediate.d          |   9 +
 docs/cmdline-opts/tlspassword.d                 |   2 +
 docs/cmdline-opts/tlsuser.d                     |   2 +
 docs/examples/Makefile.inc                      |   2 +-
 docs/examples/anyauthput.c                      |   2 +-
 docs/examples/chkspeed.c                        |   2 +-
 docs/examples/crawler.c                         |   2 +-
 docs/examples/curlgtk.c                         |   2 +-
 docs/examples/curlx.c                           |   2 +-
 docs/examples/fileupload.c                      |   2 +-
 docs/examples/fopen.c                           |   2 +-
 docs/examples/ftpupload.c                       |   2 +-
 docs/examples/href_extractor.c                  |   2 +-
 docs/examples/http-post.c                       |   2 +-
 docs/examples/https.c                           |   2 +-
 docs/examples/imap-list.c                       |   2 +-
 docs/examples/imap-lsub.c                       |   2 +-
 docs/examples/imap-noop.c                       |   2 +-
 docs/examples/imap-store.c                      |   2 +-
 docs/examples/multi-poll.c                      |  76 +++
 docs/examples/pop3-dele.c                       |   2 +-
 docs/examples/pop3-list.c                       |   2 +-
 docs/examples/pop3-noop.c                       |   2 +-
 docs/examples/pop3-retr.c                       |   2 +-
 docs/examples/pop3-ssl.c                        |   2 +-
 docs/examples/pop3-stat.c                       |   2 +-
 docs/examples/pop3-uidl.c                       |   2 +-
 docs/examples/rtsp.c                            |   2 +-
 docs/examples/sessioninfo.c                     |   2 +-
 docs/examples/smtp-expn.c                       |   2 +-
 docs/examples/smtp-ssl.c                        |   2 +-
 docs/examples/smtp-tls.c                        |   2 +-
 docs/examples/smtp-vrfy.c                       |   2 +-
 docs/examples/usercertinmem.c                   |   2 +-
 docs/libcurl/Makefile.inc                       | 163 ++---
 docs/libcurl/curl_multi_wakeup.3                |  86 +++
 docs/libcurl/gnurl_global_sslset.3              |   3 +-
 docs/libcurl/gnurl_multi_poll.3                 |  11 +-
 docs/libcurl/gnurl_multi_wait.3                 |   5 +-
 docs/libcurl/libgnurl-errors.3                  |  14 +-
 docs/libcurl/libgnurl-multi.3                   |   2 +-
 docs/libcurl/opts/GNURLOPT_OPENSOCKETFUNCTION.3 |  11 +-
 docs/libcurl/opts/GNURLOPT_PROGRESSFUNCTION.3   |   7 +-
 docs/libcurl/opts/GNURLOPT_SSL_OPTIONS.3        |  38 +-
 docs/libcurl/opts/GNURLOPT_TLSAUTH_PASSWORD.3   |   4 +-
 docs/libcurl/opts/GNURLOPT_TLSAUTH_TYPE.3       |   8 +-
 docs/libcurl/opts/GNURLOPT_TLSAUTH_USERNAME.3   |   4 +-
 docs/libcurl/opts/GNURLOPT_VERBOSE.3            |   3 +-
 docs/libcurl/opts/GNURLOPT_XFERINFOFUNCTION.3   |   7 +-
 docs/libcurl/symbols-in-versions                |  17 +-
 include/gnurl/curl.h                            |  13 +-
 include/gnurl/curlver.h                         |   6 +-
 include/gnurl/multi.h                           |  10 +
 include/gnurl/system.h                          |  27 +-
 lib/CMakeLists.txt                              |   1 -
 lib/Makefile.inc                                |  11 +-
 lib/Makefile.m32                                |   4 +-
 lib/altsvc.c                                    |  10 +-
 lib/asyn-thread.c                               |  14 +-
 lib/checksrc.pl                                 |  13 +-
 lib/config-dos.h                                |   2 +-
 lib/config-mac.h                                |   2 +-
 lib/config-plan9.h                              |   1 -
 lib/config-symbian.h                            |   3 -
 lib/config-tpf.h                                |   4 -
 lib/config-vxworks.h                            |   3 -
 lib/config-win32.h                              |   6 +-
 lib/config-win32ce.h                            |   2 +-
 lib/conncache.c                                 |  31 +-
 lib/conncache.h                                 |  24 +-
 lib/cookie.c                                    |   3 +-
 lib/curl_base64.h                               |   2 +-
 lib/curl_config.h.cmake                         |   9 +-
 lib/curl_des.c                                  |   2 +-
 lib/curl_des.h                                  |   2 +-
 lib/curl_fnmatch.h                              |   2 +-
 lib/curl_gethostname.h                          |   2 +-
 lib/curl_ldap.h                                 |   2 +-
 lib/curl_memrchr.h                              |   2 +-
 lib/curl_multibyte.c                            |   2 +-
 lib/curl_multibyte.h                            |  13 +-
 lib/curl_ntlm_core.h                            |   4 +-
 lib/curl_ntlm_wb.c                              |  17 +-
 lib/curl_rtmp.h                                 |   2 +-
 lib/curl_setup.h                                |  25 +-
 lib/curl_setup_once.h                           |  27 +-
 lib/curl_sha256.h                               |   2 +-
 lib/curl_sspi.c                                 |   2 +-
 lib/curl_sspi.h                                 |   2 +-
 lib/curl_threads.c                              |   2 +-
 lib/curl_threads.h                              |   2 +-
 lib/dict.h                                      |   2 +-
 lib/doh.c                                       | 196 +++---
 lib/doh.h                                       |   6 +-
 lib/dotdot.c                                    |   2 +-
 lib/dotdot.h                                    |   2 +-
 lib/easy.c                                      |  23 +-
 lib/easyif.h                                    |   2 +-
 lib/file.h                                      |   2 +-
 lib/ftp.c                                       |   4 +-
 lib/ftplistparser.h                             |   2 +-
 lib/getinfo.h                                   |   2 +-
 lib/gopher.h                                    |   2 +-
 lib/hostcheck.h                                 |   2 +-
 lib/hostip.c                                    |   4 +
 lib/hostip4.c                                   |  12 +-
 lib/hostsyn.c                                   |   2 +-
 lib/http.c                                      |   9 +-
 lib/http.h                                      |   5 +
 lib/http2.c                                     |   7 +-
 lib/http2.h                                     |   2 +-
 lib/http_ntlm.c                                 |   9 +-
 lib/http_proxy.c                                |   5 +-
 lib/imap.h                                      |   2 +-
 lib/inet_ntop.c                                 |   2 +-
 lib/inet_ntop.h                                 |   2 +-
 lib/inet_pton.c                                 |   2 +-
 lib/inet_pton.h                                 |   2 +-
 lib/krb5.c                                      |   2 +-
 lib/ldap.c                                      |   2 +-
 lib/llist.h                                     |   2 +-
 lib/memdebug.h                                  |   2 +-
 lib/mprintf.c                                   |   4 +-
 lib/multi.c                                     | 151 +++-
 lib/multihandle.h                               |  10 +
 lib/nonblock.c                                  |   2 +-
 lib/nonblock.h                                  |   2 +-
 lib/parsedate.c                                 |  24 +
 lib/parsedate.h                                 |   8 +-
 lib/pop3.h                                      |   2 +-
 lib/progress.c                                  |  18 +-
 lib/quic.h                                      |   4 +
 lib/rtsp.h                                      |   2 +-
 lib/select.c                                    |   2 +-
 lib/select.h                                    |   2 +-
 lib/sendf.c                                     |   4 +-
 lib/setopt.c                                    |   4 +-
 lib/sha256.c                                    |   2 +-
 lib/slist.c                                     |   2 +-
 lib/slist.h                                     |   2 +-
 lib/smtp.h                                      |   2 +-
 lib/sockaddr.h                                  |   2 +-
 lib/socks.h                                     |   2 +-
 lib/strdup.c                                    |   2 +-
 lib/strerror.c                                  | 573 +++++++---------
 lib/strerror.h                                  |   3 +
 lib/strtok.c                                    |   2 +-
 lib/strtok.h                                    |   2 +-
 lib/strtoofft.c                                 |   2 +-
 lib/telnet.c                                    |   4 +-
 lib/telnet.h                                    |   2 +-
 lib/tftp.h                                      |   2 +-
 lib/transfer.c                                  |   9 +-
 lib/url.c                                       |  30 +-
 lib/urldata.h                                   |  23 +-
 lib/vauth/cram.c                                |   2 +-
 lib/vauth/digest.h                              |   2 +-
 lib/version.c                                   |   2 +-
 lib/vquic/ngtcp2.c                              | 307 +++++++--
 lib/vquic/ngtcp2.h                              |   5 +-
 lib/vquic/quiche.c                              |  28 +-
 lib/vssh/libssh.c                               |  10 +-
 lib/vssh/libssh2.c                              | 128 ++--
 lib/{ => vssh}/ssh.h                            |   0
 lib/vtls/bearssl.c                              | 874 ++++++++++++++++++++++++
 lib/{gopher.h => vtls/bearssl.h}                |  17 +-
 lib/vtls/gskit.h                                |   2 +-
 lib/vtls/mbedtls.h                              |   2 +-
 lib/vtls/nss.c                                  |   2 +-
 lib/vtls/openssl.c                              | 143 +++-
 lib/vtls/polarssl.h                             |   2 +-
 lib/vtls/polarssl_threadlock.c                  |   2 +-
 lib/vtls/polarssl_threadlock.h                  |   2 +-
 lib/vtls/schannel.c                             |   4 -
 lib/vtls/schannel_verify.c                      |  23 +-
 lib/vtls/vtls.c                                 |   7 +-
 lib/vtls/vtls.h                                 |   1 +
 packages/OS400/curl.inc.in                      |   8 +-
 packages/vms/config_h.com                       |  22 -
 packages/vms/generate_config_vms_h_curl.com     |   4 +-
 scripts/contributors.sh                         |   4 +-
 src/slist_wc.c                                  |   2 +-
 src/slist_wc.h                                  |   2 +-
 src/tool_binmode.c                              |   2 +-
 src/tool_binmode.h                              |   2 +-
 src/tool_bname.c                                |   2 +-
 src/tool_bname.h                                |   2 +-
 src/tool_cb_dbg.h                               |   2 +-
 src/tool_cb_hdr.c                               |  54 ++
 src/tool_cb_hdr.h                               |   3 +-
 src/tool_cb_prg.c                               |  11 +-
 src/tool_cb_rea.c                               |  28 +-
 src/tool_cb_rea.h                               |  10 +-
 src/tool_cb_see.c                               |   2 +-
 src/tool_cb_see.h                               |   2 +-
 src/tool_cfgable.c                              |   2 +
 src/tool_cfgable.h                              |   3 +
 src/tool_convert.h                              |   2 +-
 src/tool_dirhie.h                               |   2 +-
 src/tool_doswin.c                               |  31 +-
 src/tool_doswin.h                               |   2 +-
 src/tool_easysrc.c                              |   4 +-
 src/tool_getparam.c                             |  16 +-
 src/tool_help.c                                 |   6 +
 src/tool_helpers.h                              |   2 +-
 src/tool_homedir.c                              |   2 +-
 src/tool_homedir.h                              |   2 +-
 src/tool_hugehelp.h                             |   2 +-
 src/tool_libinfo.c                              |   2 +-
 src/tool_libinfo.h                              |   2 +-
 src/tool_main.c                                 |   6 +-
 src/tool_metalink.c                             |   2 +-
 src/tool_msgs.c                                 |  21 +-
 src/tool_msgs.h                                 |   4 +-
 src/tool_operate.c                              | 132 +++-
 src/tool_operate.h                              |   2 +
 src/tool_operhlp.c                              |  11 +-
 src/tool_panykey.c                              |   2 +-
 src/tool_panykey.h                              |   2 +-
 src/tool_paramhlp.c                             |   2 +-
 src/tool_parsecfg.h                             |   2 +-
 src/tool_progress.c                             |   8 +
 src/tool_sdecls.h                               |   2 +-
 src/tool_setopt.c                               |   7 +-
 src/tool_setopt.h                               |   2 +-
 src/tool_setup.h                                |   2 +-
 src/tool_sleep.c                                |   2 +-
 src/tool_sleep.h                                |   2 +-
 src/tool_strdup.h                               |   2 +-
 src/tool_urlglob.h                              |   2 +-
 src/tool_util.c                                 |   2 +-
 src/tool_util.h                                 |   2 +-
 src/tool_version.h                              |   2 +-
 src/tool_vms.c                                  |   2 +-
 src/tool_vms.h                                  |   2 +-
 src/tool_writeout.h                             |   2 +-
 src/tool_xattr.h                                |   2 +-
 tests/Makefile.am                               |   3 +-
 tests/data/DISABLED                             |   2 +
 tests/data/Makefile.inc                         |  11 +-
 tests/data/test1135                             |   1 +
 tests/data/test1173                             |  26 +
 tests/data/test1175                             |  25 +
 tests/data/test1538                             |   6 +-
 tests/data/test1554                             |   6 +
 tests/data/test1558                             |   6 +-
 tests/data/test1560                             |   1 +
 tests/data/test1564                             |  31 +
 tests/data/test1565                             |  41 ++
 tests/data/test1650                             |   2 +-
 tests/data/test1655                             |   1 +
 tests/data/test2100                             | Bin 1642 -> 1639 bytes
 tests/data/test339                              |  63 ++
 tests/data/test341                              |  57 ++
 tests/data/test342                              |  58 ++
 tests/data/test343                              |  61 ++
 tests/data/test490                              |  68 ++
 tests/data/test491                              |  64 ++
 tests/data/test492                              |  89 +++
 tests/disable-scan.pl                           |  37 +
 tests/error-codes.pl                            |  80 +++
 tests/ftpserver.pl                              |  10 +-
 tests/httpserver.pl                             |   8 +-
 tests/libtest/CMakeLists.txt                    |   4 -
 tests/libtest/Makefile.am                       |   2 +-
 tests/libtest/Makefile.inc                      |  10 +-
 tests/libtest/lib1557.c                         |   6 +-
 tests/libtest/lib1559.c                         |  12 +-
 tests/libtest/lib1564.c                         | 142 ++++
 tests/libtest/lib1565.c                         | 204 ++++++
 tests/libtest/lib1591.c                         |  21 +-
 tests/libtest/test.h                            | 108 ++-
 tests/runtests.1                                |  16 +-
 tests/runtests.pl                               |  74 +-
 tests/server/CMakeLists.txt                     |   2 +-
 tests/server/Makefile.am                        |   2 +-
 tests/server/resolve.c                          |   6 +-
 tests/server/util.c                             |   3 +-
 tests/sshhelp.pm                                |  21 +-
 tests/sshserver.pl                              |   3 +
 tests/unit/Makefile.am                          |   2 +-
 tests/unit/curlcheck.h                          |   4 +-
 tests/unit/unit1607.c                           |  30 +-
 tests/unit/unit1609.c                           |  29 +-
 tests/unit/unit1620.c                           |   2 +
 tests/unit/unit1650.c                           |   4 +-
 tests/unit/unit1655.c                           | 130 +++-
 317 files changed, 5334 insertions(+), 1634 deletions(-)

diff --cc CMakeLists.txt
index c476facad,cb78921e1..5419b525b
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@@ -294,9 -296,11 +295,11 @@@ if(WIN32
      CMAKE_USE_WINSSL OFF)
  endif()
  option(CMAKE_USE_MBEDTLS "Enable mbedTLS for SSL/TLS" OFF)
+ option(CMAKE_USE_BEARSSL "Enable BearSSL for SSL/TLS" OFF)
+ option(CMAKE_USE_NSS "Enable NSS for SSL/TLS" OFF)
  
 -set(openssl_default ON)
 +set(openssl_default OFF)
- if(WIN32 OR CMAKE_USE_SECTRANSP OR CMAKE_USE_WINSSL OR CMAKE_USE_MBEDTLS)
+ if(WIN32 OR CMAKE_USE_SECTRANSP OR CMAKE_USE_WINSSL OR CMAKE_USE_MBEDTLS OR 
CMAKE_USE_NSS)
    set(openssl_default OFF)
  endif()
  option(CMAKE_USE_OPENSSL "Use OpenSSL code. Experimental" ${openssl_default})
@@@ -381,29 -384,143 +386,167 @@@ if(CMAKE_USE_MBEDTLS
    include_directories(${MBEDTLS_INCLUDE_DIRS})
  endif()
  
 +if(CMAKE_USE_GNUTLS)
 +  find_package(GnuTLS REQUIRED)
 +  set(SSL_ENABLED ON)
 +  list(APPEND GNURL_LIBS ${GNUTLS_LIBRARIES})
 +  include_directories(${GNUTLS_INCLUDE_DIR})
 +  set(USE_GNUTLS ON)
 +  find_package(GCrypt)
 +  find_package(Nettle)
 +  if(NETTLE_FOUND)
 +    check_library_exists_concat("nettle" nettle_MD5Init USE_GNUTLS_NETTLE)
 +    list(APPEND GNURL_LIBS ${NETTLE_LIBRARIES})
 +    include_directories(${NETTLE_INCLUDE_DIR})
 +    # set(USE_GNUTLS_NETTLE ON)
 +  else()
 +    check_library_exists_concat("gcrypt" gcry_control USE_GNUTLS_GCRYPT)
 +    list(APPEND GNURL_LIBS ${GCRYPT_LIBRARIES})
 +    include_directories(${GCRYPT_INCLUDE_DIRS})
 +    set(USE_GNUTLS_NETTLE OFF)
 +  endif()
 +endif()
 +
+ if(CMAKE_USE_BEARSSL)
+   find_package(BearSSL REQUIRED)
+   set(SSL_ENABLED ON)
+   set(USE_BEARSSL ON)
+   list(APPEND CURL_LIBS ${BEARSSL_LIBRARY})
+   include_directories(${BEARSSL_INCLUDE_DIRS})
+ endif()
+ 
+ if(CMAKE_USE_NSS)
+   find_package(NSS REQUIRED)
+   include_directories(${NSS_INCLUDE_DIRS})
+   list(APPEND CURL_LIBS ${NSS_LIBRARIES})
+   set(SSL_ENABLED ON)
+   set(USE_NSS ON)
+   cmake_push_check_state()
+   set(CMAKE_REQUIRED_INCLUDES ${NSS_INCLUDE_DIRS})
+   set(CMAKE_REQUIRED_LIBRARIES ${NSS_LIBRARIES})
+   check_symbol_exists(PK11_CreateManagedGenericObject "pk11pub.h" 
HAVE_PK11_CREATEMANAGEDGENERICOBJECT)
+   cmake_pop_check_state()
+ endif()
+ 
+ option(USE_NGHTTP2 "Use Nghttp2 library" OFF)
+ if(USE_NGHTTP2)
+   find_package(NGHTTP2 REQUIRED)
+   include_directories(${NGHTTP2_INCLUDE_DIRS})
+   list(APPEND CURL_LIBS ${NGHTTP2_LIBRARIES})
+ endif()
+ 
+ if(NOT CURL_DISABLE_LDAP)
+   if(WIN32)
+     option(USE_WIN32_LDAP "Use Windows LDAP implementation" ON)
+     if(USE_WIN32_LDAP)
+       check_library_exists_concat("wldap32" cldap_open HAVE_WLDAP32)
+       if(NOT HAVE_WLDAP32)
+         set(USE_WIN32_LDAP OFF)
+       endif()
+     endif()
+   endif()
+ 
+   option(CMAKE_USE_OPENLDAP "Use OpenLDAP code." OFF)
+   mark_as_advanced(CMAKE_USE_OPENLDAP)
+   set(CMAKE_LDAP_LIB "ldap" CACHE STRING "Name or full path to ldap library")
+   set(CMAKE_LBER_LIB "lber" CACHE STRING "Name or full path to lber library")
+ 
+   if(CMAKE_USE_OPENLDAP AND USE_WIN32_LDAP)
+     message(FATAL_ERROR "Cannot use USE_WIN32_LDAP and CMAKE_USE_OPENLDAP at 
the same time")
+   endif()
+ 
+   # Now that we know, we're not using windows LDAP...
+   if(USE_WIN32_LDAP)
+     check_include_file_concat("winldap.h" HAVE_WINLDAP_H)
+     check_include_file_concat("winber.h"  HAVE_WINBER_H)
 -  else()
++else()
+     # Check for LDAP
+     set(CMAKE_REQUIRED_LIBRARIES ${OPENSSL_LIBRARIES})
+     check_library_exists_concat(${CMAKE_LDAP_LIB} ldap_init HAVE_LIBLDAP)
+     check_library_exists_concat(${CMAKE_LBER_LIB} ber_init HAVE_LIBLBER)
+ 
+     set(CMAKE_REQUIRED_INCLUDES_BAK ${CMAKE_REQUIRED_INCLUDES})
+     set(CMAKE_LDAP_INCLUDE_DIR "" CACHE STRING "Path to LDAP include 
directory")
+     if(CMAKE_LDAP_INCLUDE_DIR)
+       list(APPEND CMAKE_REQUIRED_INCLUDES ${CMAKE_LDAP_INCLUDE_DIR})
+     endif()
+     check_include_file_concat("ldap.h"           HAVE_LDAP_H)
+     check_include_file_concat("lber.h"           HAVE_LBER_H)
+ 
+     if(NOT HAVE_LDAP_H)
+       message(STATUS "LDAP_H not found CURL_DISABLE_LDAP set ON")
+       set(CURL_DISABLE_LDAP ON CACHE BOOL "" FORCE)
+       set(CMAKE_REQUIRED_INCLUDES ${CMAKE_REQUIRED_INCLUDES_BAK}) #LDAP 
includes won't be used
+     elseif(NOT HAVE_LIBLDAP)
+       message(STATUS "LDAP library '${CMAKE_LDAP_LIB}' not found 
CURL_DISABLE_LDAP set ON")
+       set(CURL_DISABLE_LDAP ON CACHE BOOL "" FORCE)
+       set(CMAKE_REQUIRED_INCLUDES ${CMAKE_REQUIRED_INCLUDES_BAK}) #LDAP 
includes won't be used
+     else()
+       if(CMAKE_USE_OPENLDAP)
+         set(USE_OPENLDAP ON)
+       endif()
+       if(CMAKE_LDAP_INCLUDE_DIR)
+         include_directories(${CMAKE_LDAP_INCLUDE_DIR})
+       endif()
+       set(NEED_LBER_H ON)
+       set(_HEADER_LIST)
+       if(HAVE_WINDOWS_H)
+         list(APPEND _HEADER_LIST "windows.h")
+       endif()
+       if(HAVE_SYS_TYPES_H)
+         list(APPEND _HEADER_LIST "sys/types.h")
+       endif()
+       list(APPEND _HEADER_LIST "ldap.h")
+ 
+       set(_SRC_STRING "")
+       foreach(_HEADER ${_HEADER_LIST})
+         set(_INCLUDE_STRING "${_INCLUDE_STRING}#include <${_HEADER}>\n")
+       endforeach()
+ 
+       set(_SRC_STRING
+         "
+         ${_INCLUDE_STRING}
+         int main(int argc, char ** argv)
+         {
+           BerValue *bvp = NULL;
+           BerElement *bep = ber_init(bvp);
+           ber_free(bep, 1);
+           return 0;
+         }"
+       )
+       set(CMAKE_REQUIRED_DEFINITIONS "${CMAKE_REQUIRED_DEFINITIONS} 
-DLDAP_DEPRECATED=1")
+       list(APPEND CMAKE_REQUIRED_LIBRARIES ${CMAKE_LDAP_LIB})
+       if(HAVE_LIBLBER)
+         list(APPEND CMAKE_REQUIRED_LIBRARIES ${CMAKE_LBER_LIB})
+       endif()
+       check_c_source_compiles("${_SRC_STRING}" NOT_NEED_LBER_H)
+       unset(CMAKE_REQUIRED_LIBRARIES)
+ 
+       if(NOT_NEED_LBER_H)
+         set(NEED_LBER_H OFF)
+       else()
+         set(CURL_TEST_DEFINES "${CURL_TEST_DEFINES} -DNEED_LBER_H")
+       endif()
+     endif()
+   endif()
+ endif()
+ 
+ # No ldap, no ldaps.
+ if(CURL_DISABLE_LDAP)
+   if(NOT CURL_DISABLE_LDAPS)
+     message(STATUS "LDAP needs to be enabled to support LDAPS")
+     set(CURL_DISABLE_LDAPS ON CACHE BOOL "" FORCE)
+   endif()
+ endif()
+ 
+ if(NOT CURL_DISABLE_LDAPS)
+   check_include_file_concat("ldap_ssl.h" HAVE_LDAP_SSL_H)
+   check_include_file_concat("ldapssl.h"  HAVE_LDAPSSL_H)
+ endif()
+ 
++
 +option(USE_NGHTTP2 "Use Nghttp2 library" OFF)
 +
  # Check for idn
  check_library_exists_concat("idn2" idn2_lookup_ul HAVE_LIBIDN2)
  
@@@ -1072,7 -1228,7 +1217,7 @@@ _add_if("Kerberos"      NOT CURL_DISABL
                          (HAVE_GSSAPI OR USE_WINDOWS_SSPI))
  # NTLM support requires crypto function adaptions from various SSL libs
  # TODO alternative SSL libs tests for SSP1, GNUTLS, NSS
- if(NOT CURL_DISABLE_CRYPTO_AUTH AND (USE_OPENSSL OR USE_WINDOWS_SSPI OR 
USE_SECTRANSP OR USE_MBEDTLS OR USE_GNUTLS))
 -if(NOT CURL_DISABLE_CRYPTO_AUTH AND (USE_OPENSSL OR USE_WINDOWS_SSPI OR 
USE_SECTRANSP OR USE_MBEDTLS OR USE_NSS))
++if(NOT CURL_DISABLE_CRYPTO_AUTH AND (USE_OPENSSL OR USE_WINDOWS_SSPI OR 
USE_SECTRANSP OR USE_MBEDTLS OR USE_NSS OR USE_GNUTLS))
    _add_if("NTLM"        1)
    # TODO missing option (autoconf: --enable-ntlm-wb)
    _add_if("NTLM_WB"     NOT CURL_DISABLE_HTTP AND NTLM_WB_ENABLED)
diff --cc Makefile.am
index 50994764c,1e9ecd8c4..0a4785cff
--- a/Makefile.am
+++ b/Makefile.am
@@@ -27,6 -24,136 +27,15 @@@ AUTOMAKE_OPTIONS = foreig
  
  ACLOCAL_AMFLAGS = -I m4
  
+ CMAKE_DIST = CMakeLists.txt CMake/CMakeConfigurableFile.in      \
+  CMake/CurlTests.c CMake/FindGSS.cmake CMake/OtherTests.cmake   \
+  CMake/Platforms/WindowsCache.cmake CMake/Utilities.cmake       \
+  CMake/Macros.cmake              \
+  CMake/CurlSymbolHiding.cmake CMake/FindCARES.cmake             \
+  CMake/FindLibSSH2.cmake CMake/FindNGHTTP2.cmake                \
+  CMake/FindMbedTLS.cmake CMake/FindBearSSL.cmake                \
+  CMake/cmake_uninstall.cmake.in CMake/curl-config.cmake.in
+ 
 -VC6_LIBTMPL = projects/Windows/VC6/lib/libcurl.tmpl
 -VC6_LIBDSP = projects/Windows/VC6/lib/libcurl.dsp.dist
 -VC6_LIBDSP_DEPS = $(VC6_LIBTMPL) Makefile.am lib/Makefile.inc
 -VC6_SRCTMPL = projects/Windows/VC6/src/curl.tmpl
 -VC6_SRCDSP = projects/Windows/VC6/src/curl.dsp.dist
 -VC6_SRCDSP_DEPS = $(VC6_SRCTMPL) Makefile.am src/Makefile.inc
 -
 -VC7_LIBTMPL = projects/Windows/VC7/lib/libcurl.tmpl
 -VC7_LIBVCPROJ = projects/Windows/VC7/lib/libcurl.vcproj.dist
 -VC7_LIBVCPROJ_DEPS = $(VC7_LIBTMPL) Makefile.am lib/Makefile.inc
 -VC7_SRCTMPL = projects/Windows/VC7/src/curl.tmpl
 -VC7_SRCVCPROJ = projects/Windows/VC7/src/curl.vcproj.dist
 -VC7_SRCVCPROJ_DEPS = $(VC7_SRCTMPL) Makefile.am src/Makefile.inc
 -
 -VC71_LIBTMPL = projects/Windows/VC7.1/lib/libcurl.tmpl
 -VC71_LIBVCPROJ = projects/Windows/VC7.1/lib/libcurl.vcproj.dist
 -VC71_LIBVCPROJ_DEPS = $(VC71_LIBTMPL) Makefile.am lib/Makefile.inc
 -VC71_SRCTMPL = projects/Windows/VC7.1/src/curl.tmpl
 -VC71_SRCVCPROJ = projects/Windows/VC7.1/src/curl.vcproj.dist
 -VC71_SRCVCPROJ_DEPS = $(VC71_SRCTMPL) Makefile.am src/Makefile.inc
 -
 -VC8_LIBTMPL = projects/Windows/VC8/lib/libcurl.tmpl
 -VC8_LIBVCPROJ = projects/Windows/VC8/lib/libcurl.vcproj.dist
 -VC8_LIBVCPROJ_DEPS = $(VC8_LIBTMPL) Makefile.am lib/Makefile.inc
 -VC8_SRCTMPL = projects/Windows/VC8/src/curl.tmpl
 -VC8_SRCVCPROJ = projects/Windows/VC8/src/curl.vcproj.dist
 -VC8_SRCVCPROJ_DEPS = $(VC8_SRCTMPL) Makefile.am src/Makefile.inc
 -
 -VC9_LIBTMPL = projects/Windows/VC9/lib/libcurl.tmpl
 -VC9_LIBVCPROJ = projects/Windows/VC9/lib/libcurl.vcproj.dist
 -VC9_LIBVCPROJ_DEPS = $(VC9_LIBTMPL) Makefile.am lib/Makefile.inc
 -VC9_SRCTMPL = projects/Windows/VC9/src/curl.tmpl
 -VC9_SRCVCPROJ = projects/Windows/VC9/src/curl.vcproj.dist
 -VC9_SRCVCPROJ_DEPS = $(VC9_SRCTMPL) Makefile.am src/Makefile.inc
 -
 -VC10_LIBTMPL = projects/Windows/VC10/lib/libcurl.tmpl
 -VC10_LIBVCXPROJ = projects/Windows/VC10/lib/libcurl.vcxproj.dist
 -VC10_LIBVCXPROJ_DEPS = $(VC10_LIBTMPL) Makefile.am lib/Makefile.inc
 -VC10_SRCTMPL = projects/Windows/VC10/src/curl.tmpl
 -VC10_SRCVCXPROJ = projects/Windows/VC10/src/curl.vcxproj.dist
 -VC10_SRCVCXPROJ_DEPS = $(VC10_SRCTMPL) Makefile.am src/Makefile.inc
 -
 -VC11_LIBTMPL = projects/Windows/VC11/lib/libcurl.tmpl
 -VC11_LIBVCXPROJ = projects/Windows/VC11/lib/libcurl.vcxproj.dist
 -VC11_LIBVCXPROJ_DEPS = $(VC11_LIBTMPL) Makefile.am lib/Makefile.inc
 -VC11_SRCTMPL = projects/Windows/VC11/src/curl.tmpl
 -VC11_SRCVCXPROJ = projects/Windows/VC11/src/curl.vcxproj.dist
 -VC11_SRCVCXPROJ_DEPS = $(VC11_SRCTMPL) Makefile.am src/Makefile.inc
 -
 -VC12_LIBTMPL = projects/Windows/VC12/lib/libcurl.tmpl
 -VC12_LIBVCXPROJ = projects/Windows/VC12/lib/libcurl.vcxproj.dist
 -VC12_LIBVCXPROJ_DEPS = $(VC12_LIBTMPL) Makefile.am lib/Makefile.inc
 -VC12_SRCTMPL = projects/Windows/VC12/src/curl.tmpl
 -VC12_SRCVCXPROJ = projects/Windows/VC12/src/curl.vcxproj.dist
 -VC12_SRCVCXPROJ_DEPS = $(VC12_SRCTMPL) Makefile.am src/Makefile.inc
 -
 -VC14_LIBTMPL = projects/Windows/VC14/lib/libcurl.tmpl
 -VC14_LIBVCXPROJ = projects/Windows/VC14/lib/libcurl.vcxproj.dist
 -VC14_LIBVCXPROJ_DEPS = $(VC14_LIBTMPL) Makefile.am lib/Makefile.inc
 -VC14_SRCTMPL = projects/Windows/VC14/src/curl.tmpl
 -VC14_SRCVCXPROJ = projects/Windows/VC14/src/curl.vcxproj.dist
 -VC14_SRCVCXPROJ_DEPS = $(VC14_SRCTMPL) Makefile.am src/Makefile.inc
 -
 -VC15_LIBTMPL = projects/Windows/VC15/lib/libcurl.tmpl
 -VC15_LIBVCXPROJ = projects/Windows/VC15/lib/libcurl.vcxproj.dist
 -VC15_LIBVCXPROJ_DEPS = $(VC15_LIBTMPL) Makefile.am lib/Makefile.inc
 -VC15_SRCTMPL = projects/Windows/VC15/src/curl.tmpl
 -VC15_SRCVCXPROJ = projects/Windows/VC15/src/curl.vcxproj.dist
 -VC15_SRCVCXPROJ_DEPS = $(VC15_SRCTMPL) Makefile.am src/Makefile.inc
 -
 -VC_DIST = projects/README                           \
 - projects/build-openssl.bat                         \
 - projects/build-wolfssl.bat                         \
 - projects/checksrc.bat                              \
 - projects/Windows/VC6/curl-all.dsw                  \
 - projects/Windows/VC6/lib/libcurl.dsw               \
 - projects/Windows/VC6/src/curl.dsw                  \
 - projects/Windows/VC7/curl-all.sln                  \
 - projects/Windows/VC7/lib/libcurl.sln               \
 - projects/Windows/VC7/src/curl.sln                  \
 - projects/Windows/VC7.1/curl-all.sln                \
 - projects/Windows/VC7.1/lib/libcurl.sln             \
 - projects/Windows/VC7.1/src/curl.sln                \
 - projects/Windows/VC8/curl-all.sln                  \
 - projects/Windows/VC8/lib/libcurl.sln               \
 - projects/Windows/VC8/src/curl.sln                  \
 - projects/Windows/VC9/curl-all.sln                  \
 - projects/Windows/VC9/lib/libcurl.sln               \
 - projects/Windows/VC9/src/curl.sln                  \
 - projects/Windows/VC10/curl-all.sln                 \
 - projects/Windows/VC10/lib/libcurl.sln              \
 - projects/Windows/VC10/lib/libcurl.vcxproj.filters  \
 - projects/Windows/VC10/src/curl.sln                 \
 - projects/Windows/VC10/src/curl.vcxproj.filters     \
 - projects/Windows/VC11/curl-all.sln                 \
 - projects/Windows/VC11/lib/libcurl.sln              \
 - projects/Windows/VC11/lib/libcurl.vcxproj.filters  \
 - projects/Windows/VC11/src/curl.sln                 \
 - projects/Windows/VC11/src/curl.vcxproj.filters     \
 - projects/Windows/VC12/curl-all.sln                 \
 - projects/Windows/VC12/lib/libcurl.sln              \
 - projects/Windows/VC12/lib/libcurl.vcxproj.filters  \
 - projects/Windows/VC12/src/curl.sln                 \
 - projects/Windows/VC12/src/curl.vcxproj.filters     \
 - projects/Windows/VC14/curl-all.sln                 \
 - projects/Windows/VC14/lib/libcurl.sln              \
 - projects/Windows/VC14/lib/libcurl.vcxproj.filters  \
 - projects/Windows/VC14/src/curl.sln                 \
 - projects/Windows/VC14/src/curl.vcxproj.filters     \
 - projects/Windows/VC15/curl-all.sln                 \
 - projects/Windows/VC15/lib/libcurl.sln              \
 - projects/Windows/VC15/lib/libcurl.vcxproj.filters  \
 - projects/Windows/VC15/src/curl.sln                 \
 - projects/Windows/VC15/src/curl.vcxproj.filters     \
 - projects/generate.bat                              \
 - projects/wolfssl_options.h                         \
 - projects/wolfssl_override.props
 -
 -WINBUILD_DIST = winbuild/BUILD.WINDOWS.txt winbuild/gen_resp_file.bat \
 - winbuild/MakefileBuild.vc winbuild/Makefile.vc
 -
  PLAN9_DIST = plan9/include/mkfile \
   plan9/include/mkfile             \
   plan9/mkfile.proto               \
diff --cc docs/libcurl/gnurl_global_sslset.3
index c9f5a4027,000000000..a631d1893
mode 100644,000000..100644
--- a/docs/libcurl/gnurl_global_sslset.3
+++ b/docs/libcurl/gnurl_global_sslset.3
@@@ -1,101 -1,0 +1,102 @@@
 +.\" **************************************************************************
 +.\" *                                  _   _ ____  _
 +.\" *  Project                     ___| | | |  _ \| |
 +.\" *                             / __| | | | |_) | |
 +.\" *                            | (__| |_| |  _ <| |___
 +.\" *                             \___|\___/|_| \_\_____|
 +.\" *
 +.\" * Copyright (C) 1998 - 2018, Daniel Stenberg, <address@hidden>, et al.
 +.\" *
 +.\" * This software is licensed as described in the file COPYING, which
 +.\" * you should have received as part of this distribution. The terms
 +.\" * are also available at https://curl.haxx.se/docs/copyright.html.
 +.\" *
 +.\" * You may opt to use, copy, modify, merge, publish, distribute and/or sell
 +.\" * copies of the Software, and permit persons to whom the Software is
 +.\" * furnished to do so, under the terms of the COPYING file.
 +.\" *
 +.\" * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF 
ANY
 +.\" * KIND, either express or implied.
 +.\" *
 +.\" **************************************************************************
 +.TH gnurl_global_sslset 3 "15 July 2017" "libcurl 7.56" "libgnurl Manual"
 +.SH NAME
 +curl_global_sslset - Select SSL backend to use with libcurl
 +.SH SYNOPSIS
 +.B #include <gnurl/curl.h>
 +.nf
 +
 +typedef struct {
 +  curl_sslbackend id;
 +  const char *name;
 +} curl_ssl_backend;
 +
 +typedef enum {
 +  CURLSSLBACKEND_NONE = 0,
 +  CURLSSLBACKEND_OPENSSL = 1,
 +  CURLSSLBACKEND_GNUTLS = 2,
 +  CURLSSLBACKEND_NSS = 3,
 +  CURLSSLBACKEND_GSKIT = 5,
 +  CURLSSLBACKEND_POLARSSL = 6,
 +  CURLSSLBACKEND_WOLFSSL = 7,
 +  CURLSSLBACKEND_SCHANNEL = 8,
 +  CURLSSLBACKEND_DARWINSSL = 9,
 +  CURLSSLBACKEND_AXTLS = 10, /* deprecated */
 +  CURLSSLBACKEND_MBEDTLS = 11,
-   CURLSSLBACKEND_MESALINK = 12
++  CURLSSLBACKEND_MESALINK = 12,
++  CURLSSLBACKEND_BEARSSL = 13
 +} curl_sslbackend;
 +
 +.B "CURLsslset curl_global_sslset(curl_sslbackend " id,
 +.B "                              const char *" name,
 +.B "                              curl_ssl_backend ***" avail ");"
 +.fi
 +.SH DESCRIPTION
 +This function configures at runtime which SSL backend to use with
 +libcurl. This function can only be used to select an SSL backend once, and it
 +must be called \fBbefore\fP \fIcurl_global_init(3)\fP.
 +
 +The backend can be identified by the \fIid\fP
 +(e.g. \fBCURLSSLBACKEND_OPENSSL\fP). The backend can also be specified via the
 +\fIname\fP parameter for a case insensitive match (passing -1 as \fIid\fP). If
 +both \fIid\fP and \fIname\fP are specified, the \fIname\fP will be ignored.
 +
 +If neither \fIid\fP nor \fPname\fP are specified, the function will fail with
 +CURLSSLSET_UNKNOWN_BACKEND and set the \fIavail\fP pointer to the
 +NULL-terminated list of available backends. The available backends are those
 +that this particular build of libcurl supports.
 +
 +Since libcurl 7.60.0, the \fIavail\fP pointer will always be set to the list
 +of alternatives if non-NULL.
 +
 +Upon success, the function returns CURLSSLSET_OK.
 +
 +If the specified SSL backend is not available, the function returns
 +CURLSSLSET_UNKNOWN_BACKEND and sets the \fIavail\fP pointer to a
 +NULL-terminated list of available SSL backends. In this case, you may call the
 +function again to try to select a different backend.
 +
 +The SSL backend can be set only once. If it has already been set, a subsequent
 +attempt to change it will result in a \fBCURLSSLSET_TOO_LATE\fP.
 +
 +\fBThis function is not thread safe.\fP You must not call it when any other
 +thread in the program (i.e. a thread sharing the same memory) is running.
 +This doesn't just mean no other thread that is using libcurl.
 +
 +.SH AVAILABILITY
 +This function was added in libcurl 7.56.0. Before this version, there was no
 +support for choosing SSL backends at runtime.
 +.SH RETURN VALUE
 +If this function returns CURLSSLSET_OK, the backend was successfully selected.
 +
 +If the chosen backend is unknown (or support for the chosen backend has not
 +been compiled into libcurl), the function returns 
\fICURLSSLSET_UNKNOWN_BACKEND\fP.
 +
 +If the backend had been configured previously, or if \fIcurl_global_init(3)\fP
 +has already been called, the function returns \fICURLSSLSET_TOO_LATE\fP.
 +
 +If this libcurl was built completely without SSL support, with no backends at
 +all, this function returns \fICURLSSLSET_NO_BACKENDS\fP.
 +.SH "SEE ALSO"
 +.BR curl_global_init "(3), "
 +.BR libcurl "(3) "
diff --cc docs/libcurl/gnurl_multi_poll.3
index d532dd6b2,000000000..adab68d5e
mode 100644,000000..100644
--- a/docs/libcurl/gnurl_multi_poll.3
+++ b/docs/libcurl/gnurl_multi_poll.3
@@@ -1,110 -1,0 +1,117 @@@
 +.\" **************************************************************************
 +.\" *                                  _   _ ____  _
 +.\" *  Project                     ___| | | |  _ \| |
 +.\" *                             / __| | | | |_) | |
 +.\" *                            | (__| |_| |  _ <| |___
 +.\" *                             \___|\___/|_| \_\_____|
 +.\" *
 +.\" * Copyright (C) 1998 - 2019, Daniel Stenberg, <address@hidden>, et al.
 +.\" *
 +.\" * This software is licensed as described in the file COPYING, which
 +.\" * you should have received as part of this distribution. The terms
 +.\" * are also available at https://curl.haxx.se/docs/copyright.html.
 +.\" *
 +.\" * You may opt to use, copy, modify, merge, publish, distribute and/or sell
 +.\" * copies of the Software, and permit persons to whom the Software is
 +.\" * furnished to do so, under the terms of the COPYING file.
 +.\" *
 +.\" * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF 
ANY
 +.\" * KIND, either express or implied.
 +.\" *
 +.\" **************************************************************************
 +.TH gnurl_multi_poll 3 "29 Jul 2019" "libcurl 7.66.0" "libgnurl Manual"
 +.SH NAME
 +curl_multi_poll - polls on all easy handles in a multi handle
 +.SH SYNOPSIS
 +.nf
 +#include <gnurl/curl.h>
 +
 +CURLMcode curl_multi_poll(CURLM *multi_handle,
 +                          struct curl_waitfd extra_fds[],
 +                          unsigned int extra_nfds,
 +                          int timeout_ms,
 +                          int *numfds);
 +.ad
 +.SH DESCRIPTION
 +\fIcurl_multi_poll(3)\fP polls all file descriptors used by the curl easy
 +handles contained in the given multi handle set.  It will block until activity
 +is detected on at least one of the handles or \fItimeout_ms\fP has passed.
 +Alternatively, if the multi handle has a pending internal timeout that has a
 +shorter expiry time than \fItimeout_ms\fP, that shorter time will be used
 +instead to make sure timeout accuracy is reasonably kept.
 +
 +The calling application may pass additional curl_waitfd structures which are
 +similar to \fIpoll(2)\fP's pollfd structure to be waited on in the same call.
 +
 +On completion, if \fInumfds\fP is non-NULL, it will be populated with the
 +total number of file descriptors on which interesting events occurred. This
 +number can include both libcurl internal descriptors as well as descriptors
 +provided in \fIextra_fds\fP.
 +
++The \fIcurl_multi_wakeup(3)\fP function can be used from another thread to
++wake up this function and return faster. This is one of the details
++that makes this function different than \fIcurl_multi_wait(3)\fP which cannot
++be woken up this way.
++
 +If no extra file descriptors are provided and libcurl has no file descriptor
 +to offer to wait for, this function will instead wait during \fItimeout_ms\fP
 +milliseconds (or shorter if an internal timer indicates so). This is the
- detail that makes this function different than \fIcurl_multi_wait(3)\fP.
++other detail that makes this function different than
++\fIcurl_multi_wait(3)\fP.
 +
 +This function is encouraged to be used instead of select(3) when using the
 +multi interface to allow applications to easier circumvent the common problem
 +with 1024 maximum file descriptors.
 +.SH curl_waitfd
 +.nf
 +struct curl_waitfd {
 +  curl_socket_t fd;
 +  short events;
 +  short revents;
 +};
 +.fi
 +.IP CURL_WAIT_POLLIN
 +Bit flag to curl_waitfd.events indicating the socket should poll on read
 +events such as new data received.
 +.IP CURL_WAIT_POLLPRI
 +Bit flag to curl_waitfd.events indicating the socket should poll on high
 +priority read events such as out of band data.
 +.IP CURL_WAIT_POLLOUT
 +Bit flag to curl_waitfd.events indicating the socket should poll on write
 +events such as the socket being clear to write without blocking.
 +.SH EXAMPLE
 +.nf
 +CURL *easy_handle;
 +CURLM *multi_handle;
 +
 +/* add the individual easy handle */
 +curl_multi_add_handle(multi_handle, easy_handle);
 +
 +do {
 +  CURLMcode mc;
 +  int numfds;
 +
 +  mc = curl_multi_perform(multi_handle, &still_running);
 +
 +  if(mc == CURLM_OK) {
 +    /* wait for activity or timeout */
 +    mc = curl_multi_poll(multi_handle, NULL, 0, 1000, &numfds);
 +  }
 +
 +  if(mc != CURLM_OK) {
 +    fprintf(stderr, "curl_multi failed, code %d.\\n", mc);
 +    break;
 +  }
 +
 +} while(still_running);
 +
 +curl_multi_remove_handle(multi_handle, easy_handle);
 +.fi
 +.SH RETURN VALUE
 +CURLMcode type, general libcurl multi interface error code. See
 +\fIlibcurl-errors(3)\fP
 +.SH AVAILABILITY
 +This function was added in libcurl 7.66.0.
 +.SH "SEE ALSO"
- .BR curl_multi_fdset "(3), " curl_multi_perform "(3), " curl_multi_wait "(3)"
++.BR curl_multi_fdset "(3), " curl_multi_perform "(3), "
++.BR curl_multi_wait "(3), " curl_multi_wakeup "(3)"
diff --cc docs/libcurl/gnurl_multi_wait.3
index 34d7c0411,000000000..21c0842b4
mode 100644,000000..100644
--- a/docs/libcurl/gnurl_multi_wait.3
+++ b/docs/libcurl/gnurl_multi_wait.3
@@@ -1,122 -1,0 +1,123 @@@
 +.\" **************************************************************************
 +.\" *                                  _   _ ____  _
 +.\" *  Project                     ___| | | |  _ \| |
 +.\" *                             / __| | | | |_) | |
 +.\" *                            | (__| |_| |  _ <| |___
 +.\" *                             \___|\___/|_| \_\_____|
 +.\" *
 +.\" * Copyright (C) 1998 - 2019, Daniel Stenberg, <address@hidden>, et al.
 +.\" *
 +.\" * This software is licensed as described in the file COPYING, which
 +.\" * you should have received as part of this distribution. The terms
 +.\" * are also available at https://curl.haxx.se/docs/copyright.html.
 +.\" *
 +.\" * You may opt to use, copy, modify, merge, publish, distribute and/or sell
 +.\" * copies of the Software, and permit persons to whom the Software is
 +.\" * furnished to do so, under the terms of the COPYING file.
 +.\" *
 +.\" * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF 
ANY
 +.\" * KIND, either express or implied.
 +.\" *
 +.\" **************************************************************************
 +.TH gnurl_multi_wait 3 "12 Jul 2012" "libcurl 7.28.0" "libgnurl Manual"
 +.SH NAME
 +curl_multi_wait - polls on all easy handles in a multi handle
 +.SH SYNOPSIS
 +.nf
 +#include <gnurl/curl.h>
 +
 +CURLMcode curl_multi_wait(CURLM *multi_handle,
 +                          struct curl_waitfd extra_fds[],
 +                          unsigned int extra_nfds,
 +                          int timeout_ms,
 +                          int *numfds);
 +.ad
 +.SH DESCRIPTION
 +\fIcurl_multi_wait(3)\fP polls all file descriptors used by the curl easy
 +handles contained in the given multi handle set.  It will block until activity
 +is detected on at least one of the handles or \fItimeout_ms\fP has passed.
 +Alternatively, if the multi handle has a pending internal timeout that has a
 +shorter expiry time than \fItimeout_ms\fP, that shorter time will be used
 +instead to make sure timeout accuracy is reasonably kept.
 +
 +The calling application may pass additional curl_waitfd structures which are
 +similar to \fIpoll(2)\fP's pollfd structure to be waited on in the same call.
 +
 +On completion, if \fInumfds\fP is non-NULL, it will be populated with the
 +total number of file descriptors on which interesting events occurred. This
 +number can include both libcurl internal descriptors as well as descriptors
 +provided in \fIextra_fds\fP.
 +
 +If no extra file descriptors are provided and libcurl has no file descriptor
- to offer to wait for, this function will return immediately.
++to offer to wait for, this function will return immediately. (Try
++\fIcurl_multi_poll(3)\fP instead if you rather avoid this behavior.)
 +
 +This function is encouraged to be used instead of select(3) when using the
 +multi interface to allow applications to easier circumvent the common problem
 +with 1024 maximum file descriptors.
 +.SH curl_waitfd
 +.nf
 +struct curl_waitfd {
 +  curl_socket_t fd;
 +  short events;
 +  short revents;
 +};
 +.fi
 +.IP CURL_WAIT_POLLIN
 +Bit flag to curl_waitfd.events indicating the socket should poll on read
 +events such as new data received.
 +.IP CURL_WAIT_POLLPRI
 +Bit flag to curl_waitfd.events indicating the socket should poll on high
 +priority read events such as out of band data.
 +.IP CURL_WAIT_POLLOUT
 +Bit flag to curl_waitfd.events indicating the socket should poll on write
 +events such as the socket being clear to write without blocking.
 +.SH EXAMPLE
 +.nf
 +CURL *easy_handle;
 +CURLM *multi_handle;
 +
 +/* add the individual easy handle */
 +curl_multi_add_handle(multi_handle, easy_handle);
 +
 +do {
 +  CURLMcode mc;
 +  int numfds;
 +
 +  mc = curl_multi_perform(multi_handle, &still_running);
 +
 +  if(mc == CURLM_OK ) {
 +    /* wait for activity, timeout or "nothing" */
 +    mc = curl_multi_wait(multi_handle, NULL, 0, 1000, &numfds);
 +  }
 +
 +  if(mc != CURLM_OK) {
 +    fprintf(stderr, "curl_multi failed, code %d.\\n", mc);
 +    break;
 +  }
 +
 +  /* 'numfds' being zero means either a timeout or no file descriptors to
 +     wait for. Try timeout on first occurrence, then assume no file
 +     descriptors and no file descriptors to wait for means wait for 100
 +     milliseconds. */
 +
 +  if(!numfds) {
 +    repeats++; /* count number of repeated zero numfds */
 +    if(repeats > 1) {
 +      WAITMS(100); /* sleep 100 milliseconds */
 +    }
 +  }
 +  else
 +    repeats = 0;
 +
 +} while(still_running);
 +
 +curl_multi_remove_handle(multi_handle, easy_handle);
 +.fi
 +.SH RETURN VALUE
 +CURLMcode type, general libcurl multi interface error code. See
 +\fIlibcurl-errors(3)\fP
 +.SH AVAILABILITY
 +This function was added in libcurl 7.28.0.
 +.SH "SEE ALSO"
- .BR curl_multi_fdset "(3), " curl_multi_perform "(3)"
++.BR curl_multi_fdset "(3), " curl_multi_perform "(3)", curl_multi_poll "(3) ",
diff --cc docs/libcurl/opts/GNURLOPT_OPENSOCKETFUNCTION.3
index 64da37724,000000000..1197f8170
mode 100644,000000..100644
--- a/docs/libcurl/opts/GNURLOPT_OPENSOCKETFUNCTION.3
+++ b/docs/libcurl/opts/GNURLOPT_OPENSOCKETFUNCTION.3
@@@ -1,128 -1,0 +1,125 @@@
 +.\" **************************************************************************
 +.\" *                                  _   _ ____  _
 +.\" *  Project                     ___| | | |  _ \| |
 +.\" *                             / __| | | | |_) | |
 +.\" *                            | (__| |_| |  _ <| |___
 +.\" *                             \___|\___/|_| \_\_____|
 +.\" *
- .\" * Copyright (C) 1998 - 2017, Daniel Stenberg, <address@hidden>, et al.
++.\" * Copyright (C) 1998 - 2019, Daniel Stenberg, <address@hidden>, et al.
 +.\" *
 +.\" * This software is licensed as described in the file COPYING, which
 +.\" * you should have received as part of this distribution. The terms
 +.\" * are also available at https://curl.haxx.se/docs/copyright.html.
 +.\" *
 +.\" * You may opt to use, copy, modify, merge, publish, distribute and/or sell
 +.\" * copies of the Software, and permit persons to whom the Software is
 +.\" * furnished to do so, under the terms of the COPYING file.
 +.\" *
 +.\" * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF 
ANY
 +.\" * KIND, either express or implied.
 +.\" *
 +.\" **************************************************************************
 +.\"
 +.TH GNURLOPT_OPENSOCKETFUNCTION 3 "16 Jun 2014" "libcurl 7.37.0" 
"curl_easy_setopt options"
 +.SH NAME
 +CURLOPT_OPENSOCKETFUNCTION \- set callback for opening sockets
 +.SH SYNOPSIS
 +.nf
 +#include <gnurl/curl.h>
 +
 +typedef enum  {
 +  CURLSOCKTYPE_IPCXN,  /* socket created for a specific IP connection */
-   CURLSOCKTYPE_ACCEPT, /* socket created by accept() call */
-   CURLSOCKTYPE_LAST    /* never use */
 +} curlsocktype;
 +
 +struct curl_sockaddr {
 +  int family;
 +  int socktype;
 +  int protocol;
 +  unsigned int addrlen;
 +  struct sockaddr addr;
 +};
 +
 +curl_socket_t opensocket_callback(void *clientp,
 +                                  curlsocktype purpose,
 +                                  struct curl_sockaddr *address);
 +
 +CURLcode curl_easy_setopt(CURL *handle, CURLOPT_OPENSOCKETFUNCTION, 
opensocket_callback);
 +.SH DESCRIPTION
 +Pass a pointer to your callback function, which should match the prototype
 +shown above.
 +
 +This callback function gets called by libcurl instead of the \fIsocket(2)\fP
 +call. The callback's \fIpurpose\fP argument identifies the exact purpose for
- this particular socket: \fICURLSOCKTYPE_IPCXN\fP is for IP based connections
- and \fICURLSOCKTYPE_ACCEPT\fP is for sockets created after accept() - such as
- when doing active FTP. Future versions of libcurl may support more
- purposes.
++this particular socket. \fICURLSOCKTYPE_IPCXN\fP is for IP based connections
++and is the only purpose currently used in libcurl. Future versions of libcurl
++may support more purposes.
 +
 +The \fIclientp\fP pointer contains whatever user-defined value set using the
 +\fICURLOPT_OPENSOCKETDATA(3)\fP function.
 +
 +The callback gets the resolved peer address as the \fIaddress\fP argument and
 +is allowed to modify the address or refuse to connect completely. The callback
 +function should return the newly created socket or \fICURL_SOCKET_BAD\fP in
 +case no connection could be established or another error was detected. Any
 +additional \fIsetsockopt(2)\fP calls can of course be done on the socket at
 +the user's discretion.  A \fICURL_SOCKET_BAD\fP return value from the callback
 +function will signal an unrecoverable error to libcurl and it will return
 +\fICURLE_COULDNT_CONNECT\fP from the function that triggered this callback.
 +This return code can be used for IP address blacklisting.
 +
 +If you want to pass in a socket with an already established connection, pass
 +the socket back with this callback and then use
 +\fICURLOPT_SOCKOPTFUNCTION(3)\fP to signal that it already is connected.
 +.SH DEFAULT
 +The default behavior is the equivalent of this:
 +.nf
 +   return socket(addr->family, addr->socktype, addr->protocol);
 +.fi
 +.SH PROTOCOLS
 +All
 +.SH EXAMPLE
 +.nf
 +/* make libcurl use the already established socket 'sockfd' */
 +
 +static curl_socket_t opensocket(void *clientp,
 +                                curlsocktype purpose,
 +                                struct curl_sockaddr *address)
 +{
 +  curl_socket_t sockfd;
 +  sockfd = *(curl_socket_t *)clientp;
 +  /* the actual externally set socket is passed in via the OPENSOCKETDATA
 +     option */
 +  return sockfd;
 +}
 +
 +static int sockopt_callback(void *clientp, curl_socket_t curlfd,
 +                            curlsocktype purpose)
 +{
 +  /* This return code was added in libcurl 7.21.5 */
 +  return CURL_SOCKOPT_ALREADY_CONNECTED;
 +}
 +
 +curl = curl_easy_init();
 +if(curl) {
 +  /* libcurl will internally think that you connect to the host
 +   * and port that you specify in the URL option. */
 +  curl_easy_setopt(curl, CURLOPT_URL, "http://99.99.99.99:9999";);
 +  /* call this function to get a socket */
 +  curl_easy_setopt(curl, CURLOPT_OPENSOCKETFUNCTION, opensocket);
 +  curl_easy_setopt(curl, CURLOPT_OPENSOCKETDATA, &sockfd);
 +
 +  /* call this function to set options for the socket */
 +  curl_easy_setopt(curl, CURLOPT_SOCKOPTFUNCTION, sockopt_callback);
 +
 +  res = curl_easy_perform(curl);
 +
 +  curl_easy_cleanup(curl);
 +}
 +.fi
 +.SH AVAILABILITY
 +Added in 7.17.1.
 +.SH RETURN VALUE
 +Returns CURLE_OK if the option is supported, and CURLE_UNKNOWN_OPTION if not.
 +.SH "SEE ALSO"
 +.BR CURLOPT_OPENSOCKETDATA "(3), " CURLOPT_SOCKOPTFUNCTION "(3), "
 +.BR CURLOPT_CLOSESOCKETFUNCTION "(3), "
diff --cc docs/libcurl/opts/GNURLOPT_PROGRESSFUNCTION.3
index 46fbdc7f1,000000000..47ca33b27
mode 100644,000000..100644
--- a/docs/libcurl/opts/GNURLOPT_PROGRESSFUNCTION.3
+++ b/docs/libcurl/opts/GNURLOPT_PROGRESSFUNCTION.3
@@@ -1,84 -1,0 +1,87 @@@
 +.\" **************************************************************************
 +.\" *                                  _   _ ____  _
 +.\" *  Project                     ___| | | |  _ \| |
 +.\" *                             / __| | | | |_) | |
 +.\" *                            | (__| |_| |  _ <| |___
 +.\" *                             \___|\___/|_| \_\_____|
 +.\" *
 +.\" * Copyright (C) 1998 - 2014, Daniel Stenberg, <address@hidden>, et al.
 +.\" *
 +.\" * This software is licensed as described in the file COPYING, which
 +.\" * you should have received as part of this distribution. The terms
 +.\" * are also available at https://curl.haxx.se/docs/copyright.html.
 +.\" *
 +.\" * You may opt to use, copy, modify, merge, publish, distribute and/or sell
 +.\" * copies of the Software, and permit persons to whom the Software is
 +.\" * furnished to do so, under the terms of the COPYING file.
 +.\" *
 +.\" * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF 
ANY
 +.\" * KIND, either express or implied.
 +.\" *
 +.\" **************************************************************************
 +.\"
 +.TH GNURLOPT_PROGRESSFUNCTION 3 "17 Jun 2014" "libcurl 7.37.0" 
"curl_easy_setopt options"
 +.SH NAME
 +CURLOPT_PROGRESSFUNCTION \- callback to progress meter function
 +.SH SYNOPSIS
 +#include <gnurl/curl.h>
 +
 +int progress_callback(void *clientp,
 +                      double dltotal,
 +                      double dlnow,
 +                      double ultotal,
 +                      double ulnow);
 +
 +CURLcode curl_easy_setopt(CURL *handle, CURLOPT_PROGRESSFUNCTION, 
progress_callback);
 +.SH DESCRIPTION
 +Pass a pointer to your callback function, which should match the prototype
 +shown above.
 +
 +We encourage users to use the newer \fICURLOPT_XFERINFOFUNCTION(3)\fP instead,
 +if you can.
 +
 +This function gets called by libcurl instead of its internal equivalent with a
 +frequent interval. While data is being transferred it will be called very
 +frequently, and during slow periods like when nothing is being transferred it
 +can slow down to about one call per second.
 +
 +\fIclientp\fP is the pointer set with \fICURLOPT_PROGRESSDATA(3)\fP, it is not
 +used by libcurl but is only passed along from the application to the callback.
 +
 +The callback gets told how much data libcurl will transfer and has
 +transferred, in number of bytes. \fIdltotal\fP is the total number of bytes
 +libcurl expects to download in this transfer. \fIdlnow\fP is the number of
 +bytes downloaded so far. \fIultotal\fP is the total number of bytes libcurl
 +expects to upload in this transfer. \fIulnow\fP is the number of bytes
 +uploaded so far.
 +
 +Unknown/unused argument values passed to the callback will be set to zero
 +(like if you only download data, the upload size will remain 0). Many times
 +the callback will be called one or more times first, before it knows the data
 +sizes so a program must be made to handle that.
 +
- Returning a non-zero value from this callback will cause libcurl to abort the
- transfer and return \fICURLE_ABORTED_BY_CALLBACK\fP.
++If your callback function returns CURL_PROGRESSFUNC_CONTINUE it will cause
++libcurl to continue executing the default progress function.
++
++Returning any other non-zero value from this callback will cause libcurl to
++abort the transfer and return \fICURLE_ABORTED_BY_CALLBACK\fP.
 +
 +If you transfer data with the multi interface, this function will not be
 +called during periods of idleness unless you call the appropriate libcurl
 +function that performs transfers.
 +
 +\fICURLOPT_NOPROGRESS(3)\fP must be set to 0 to make this function actually
 +get called.
 +.SH DEFAULT
 +By default, libcurl has an internal progress meter. That's rarely wanted by
 +users.
 +.SH PROTOCOLS
 +All
 +.SH EXAMPLE
 +https://curl.haxx.se/libcurl/c/progressfunc.html
 +.SH AVAILABILITY
 +Always
 +.SH RETURN VALUE
 +Returns CURLE_OK.
 +.SH "SEE ALSO"
 +.BR CURLOPT_VERBOSE "(3), " CURLOPT_NOPROGRESS "(3), "
diff --cc docs/libcurl/opts/GNURLOPT_SSL_OPTIONS.3
index f3fc74ab3,000000000..bf7fee028
mode 100644,000000..100644
--- a/docs/libcurl/opts/GNURLOPT_SSL_OPTIONS.3
+++ b/docs/libcurl/opts/GNURLOPT_SSL_OPTIONS.3
@@@ -1,69 -1,0 +1,73 @@@
 +.\" **************************************************************************
 +.\" *                                  _   _ ____  _
 +.\" *  Project                     ___| | | |  _ \| |
 +.\" *                             / __| | | | |_) | |
 +.\" *                            | (__| |_| |  _ <| |___
 +.\" *                             \___|\___/|_| \_\_____|
 +.\" *
 +.\" * Copyright (C) 1998 - 2019, Daniel Stenberg, <address@hidden>, et al.
 +.\" *
 +.\" * This software is licensed as described in the file COPYING, which
 +.\" * you should have received as part of this distribution. The terms
 +.\" * are also available at https://curl.haxx.se/docs/copyright.html.
 +.\" *
 +.\" * You may opt to use, copy, modify, merge, publish, distribute and/or sell
 +.\" * copies of the Software, and permit persons to whom the Software is
 +.\" * furnished to do so, under the terms of the COPYING file.
 +.\" *
 +.\" * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF 
ANY
 +.\" * KIND, either express or implied.
 +.\" *
 +.\" **************************************************************************
 +.\"
 +.TH GNURLOPT_SSL_OPTIONS 3 "19 Jun 2014" "libcurl 7.37.0" "curl_easy_setopt 
options"
 +.SH NAME
 +CURLOPT_SSL_OPTIONS \- set SSL behavior options
 +.SH SYNOPSIS
 +#include <gnurl/curl.h>
 +
 +CURLcode curl_easy_setopt(CURL *handle, CURLOPT_SSL_OPTIONS, long bitmask);
 +.SH DESCRIPTION
- Pass a long with a bitmask to tell libcurl about specific SSL behaviors.
- 
- \fICURLSSLOPT_ALLOW_BEAST\fP tells libcurl to not attempt to use any
- workarounds for a security flaw in the SSL3 and TLS1.0 protocols.  If this
- option isn't used or this bit is set to 0, the SSL layer libcurl uses may use 
a
- work-around for this flaw although it might cause interoperability problems
- with some (older) SSL implementations. WARNING: avoiding this work-around
- lessens the security, and by setting this option to 1 you ask for exactly 
that.
- This option is only supported for DarwinSSL, NSS and OpenSSL.
- 
- Added in 7.44.0:
- 
- \fICURLSSLOPT_NO_REVOKE\fP tells libcurl to disable certificate revocation
- checks for those SSL backends where such behavior is present. This option is
- only supported for Schannel (the native Windows SSL library), with an
- exception in the case of Windows' Untrusted Publishers blacklist which it
- seems can't be bypassed.
++Pass a long with a bitmask to tell libcurl about specific SSL
++behaviors. Available bits:
++.IP CURLSSLOPT_ALLOW_BEAST
++Tells libcurl to not attempt to use any workarounds for a security flaw in the
++SSL3 and TLS1.0 protocols.  If this option isn't used or this bit is set to 0,
++the SSL layer libcurl uses may use a work-around for this flaw although it
++might cause interoperability problems with some (older) SSL
++implementations. WARNING: avoiding this work-around lessens the security, and
++by setting this option to 1 you ask for exactly that.  This option is only
++supported for DarwinSSL, NSS and OpenSSL.
++.IP CURLSSLOPT_NO_REVOKE
++Tells libcurl to disable certificate revocation checks for those SSL backends
++where such behavior is present. This option is only supported for Schannel
++(the native Windows SSL library), with an exception in the case of Windows'
++Untrusted Publishers blacklist which it seems can't be bypassed. (Added in
++7.44.0)
++.IP CURLSSLOPT_NO_PARTIALCHAIN
++Tells libcurl to not accept "partial" certificate chains, which it otherwise
++does by default. This option is only supported for OpenSSL and will fail the
++certificate verification if the chain ends with an intermediate certificate
++and not with a root cert. (Added in 7.68.0)
 +.SH DEFAULT
 +0
 +.SH PROTOCOLS
 +All TLS-based protocols
 +.SH EXAMPLE
 +.nf
 +CURL *curl = curl_easy_init();
 +if(curl) {
 +  curl_easy_setopt(curl, CURLOPT_URL, "https://example.com/";);
 +  /* weaken TLS only for use with silly servers */
 +  curl_easy_setopt(curl, CURLOPT_SSL_OPTIONS, CURLSSLOPT_ALLOW_BEAST |
 +                   CURLSSLOPT_NO_REVOKE);
 +  ret = curl_easy_perform(curl);
 +  curl_easy_cleanup(curl);
 +}
 +.fi
 +.SH AVAILABILITY
 +Added in 7.25.0
 +.SH RETURN VALUE
 +Returns CURLE_OK if the option is supported, and CURLE_UNKNOWN_OPTION if not.
 +.SH "SEE ALSO"
 +.BR CURLOPT_SSLVERSION "(3), " CURLOPT_SSL_CIPHER_LIST "(3), "
diff --cc docs/libcurl/opts/GNURLOPT_TLSAUTH_PASSWORD.3
index be67bdbdb,000000000..7fe983e2e
mode 100644,000000..100644
--- a/docs/libcurl/opts/GNURLOPT_TLSAUTH_PASSWORD.3
+++ b/docs/libcurl/opts/GNURLOPT_TLSAUTH_PASSWORD.3
@@@ -1,60 -1,0 +1,62 @@@
 +.\" **************************************************************************
 +.\" *                                  _   _ ____  _
 +.\" *  Project                     ___| | | |  _ \| |
 +.\" *                             / __| | | | |_) | |
 +.\" *                            | (__| |_| |  _ <| |___
 +.\" *                             \___|\___/|_| \_\_____|
 +.\" *
- .\" * Copyright (C) 1998 - 2017, Daniel Stenberg, <address@hidden>, et al.
++.\" * Copyright (C) 1998 - 2019, Daniel Stenberg, <address@hidden>, et al.
 +.\" *
 +.\" * This software is licensed as described in the file COPYING, which
 +.\" * you should have received as part of this distribution. The terms
 +.\" * are also available at https://curl.haxx.se/docs/copyright.html.
 +.\" *
 +.\" * You may opt to use, copy, modify, merge, publish, distribute and/or sell
 +.\" * copies of the Software, and permit persons to whom the Software is
 +.\" * furnished to do so, under the terms of the COPYING file.
 +.\" *
 +.\" * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF 
ANY
 +.\" * KIND, either express or implied.
 +.\" *
 +.\" **************************************************************************
 +.\"
 +.TH GNURLOPT_TLSAUTH_PASSWORD 3 "19 Jun 2014" "libcurl 7.37.0" 
"curl_easy_setopt options"
 +.SH NAME
 +CURLOPT_TLSAUTH_PASSWORD \- password to use for TLS authentication
 +.SH SYNOPSIS
 +#include <gnurl/curl.h>
 +
 +CURLcode curl_easy_setopt(CURL *handle, CURLOPT_TLSAUTH_PASSWORD, char *pwd);
 +.SH DESCRIPTION
 +Pass a char * as parameter, which should point to the zero terminated password
 +to use for the TLS authentication method specified with the
 +\fICURLOPT_TLSAUTH_TYPE(3)\fP option. Requires that the
 +\fICURLOPT_TLSAUTH_USERNAME(3)\fP option also be set.
 +
 +The application does not have to keep the string around after setting this
 +option.
++
++This feature relies in TLS SRP which doesn't work with TLS 1.3.
 +.SH DEFAULT
 +NULL
 +.SH PROTOCOLS
 +All TLS-based protocols
 +.SH EXAMPLE
 +.nf
 +CURL *curl = curl_easy_init();
 +if(curl) {
 +  curl_easy_setopt(curl, CURLOPT_URL, "https://example.com/";);
 +  curl_easy_setopt(curl, CURLOPT_TLSAUTH_TYPE, "SRP");
 +  curl_easy_setopt(curl, CURLOPT_TLSAUTH_USERNAME, "user");
 +  curl_easy_setopt(curl, CURLOPT_TLSAUTH_PASSWORD, "secret");
 +  ret = curl_easy_perform(curl);
 +  curl_easy_cleanup(curl);
 +}
 +.fi
 +.SH AVAILABILITY
 +Added in 7.21.4
 +.SH RETURN VALUE
 +Returns CURLE_OK if the option is supported, CURLE_UNKNOWN_OPTION if not, or
 +CURLE_OUT_OF_MEMORY if there was insufficient heap space.
 +.SH "SEE ALSO"
 +.BR CURLOPT_TLSAUTH_TYPE "(3), " CURLOPT_TLSAUTH_USERNAME "(3), "
diff --cc docs/libcurl/opts/GNURLOPT_TLSAUTH_TYPE.3
index 15e697d31,000000000..f480f341e
mode 100644,000000..100644
--- a/docs/libcurl/opts/GNURLOPT_TLSAUTH_TYPE.3
+++ b/docs/libcurl/opts/GNURLOPT_TLSAUTH_TYPE.3
@@@ -1,65 -1,0 +1,67 @@@
 +.\" **************************************************************************
 +.\" *                                  _   _ ____  _
 +.\" *  Project                     ___| | | |  _ \| |
 +.\" *                             / __| | | | |_) | |
 +.\" *                            | (__| |_| |  _ <| |___
 +.\" *                             \___|\___/|_| \_\_____|
 +.\" *
- .\" * Copyright (C) 1998 - 2017, Daniel Stenberg, <address@hidden>, et al.
++.\" * Copyright (C) 1998 - 2019, Daniel Stenberg, <address@hidden>, et al.
 +.\" *
 +.\" * This software is licensed as described in the file COPYING, which
 +.\" * you should have received as part of this distribution. The terms
 +.\" * are also available at https://curl.haxx.se/docs/copyright.html.
 +.\" *
 +.\" * You may opt to use, copy, modify, merge, publish, distribute and/or sell
 +.\" * copies of the Software, and permit persons to whom the Software is
 +.\" * furnished to do so, under the terms of the COPYING file.
 +.\" *
 +.\" * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF 
ANY
 +.\" * KIND, either express or implied.
 +.\" *
 +.\" **************************************************************************
 +.\"
 +.TH GNURLOPT_TLSAUTH_TYPE 3 "19 Jun 2014" "libcurl 7.37.0" "curl_easy_setopt 
options"
 +.SH NAME
 +CURLOPT_TLSAUTH_TYPE \- set TLS authentication methods
 +.SH SYNOPSIS
 +#include <gnurl/curl.h>
 +
 +CURLcode curl_easy_setopt(CURL *handle, CURLOPT_TLSAUTH_TYPE, char *type);
 +.SH DESCRIPTION
- Pass a pointer to a zero terminated string as parameter. The string
- should be the method of the TLS authentication. Supported method is "SRP".
++Pass a pointer to a zero terminated string as parameter. The string should be
++the method of the TLS authentication. Supported method is "SRP".
 +
 +.IP SRP
 +TLS-SRP authentication. Secure Remote Password authentication for TLS is
 +defined in RFC5054 and provides mutual authentication if both sides have a
 +shared secret. To use TLS-SRP, you must also set the
 +\fICURLOPT_TLSAUTH_USERNAME(3)\fP and \fICURLOPT_TLSAUTH_PASSWORD(3)\fP
 +options.
 +
 +The application does not have to keep the string around after setting this
 +option.
++
++TLS SRP doesn't work with TLS 1.3.
 +.SH DEFAULT
 +blank
 +.SH PROTOCOLS
 +All TLS-based protocols
 +.SH EXAMPLE
 +.nf
 +CURL *curl = curl_easy_init();
 +if(curl) {
 +  curl_easy_setopt(curl, CURLOPT_URL, "https://example.com/";);
 +  curl_easy_setopt(curl, CURLOPT_TLSAUTH_TYPE, "SRP");
 +  curl_easy_setopt(curl, CURLOPT_TLSAUTH_USERNAME, "user");
 +  curl_easy_setopt(curl, CURLOPT_TLSAUTH_PASSWORD, "secret");
 +  ret = curl_easy_perform(curl);
 +  curl_easy_cleanup(curl);
 +}
 +.fi
 +.SH AVAILABILITY
 +You need to build libcurl with GnuTLS or OpenSSL with TLS-SRP support for this
 +to work. Added in 7.21.4
 +.SH RETURN VALUE
 +Returns CURLE_OK if the option is supported, and CURLE_UNKNOWN_OPTION if not.
 +.SH "SEE ALSO"
 +.BR CURLOPT_TLSAUTH_USERNAME "(3), " CURLOPT_TLSAUTH_PASSWORD "(3), "
diff --cc docs/libcurl/opts/GNURLOPT_TLSAUTH_USERNAME.3
index e7c4fe8a3,000000000..807ba9abb
mode 100644,000000..100644
--- a/docs/libcurl/opts/GNURLOPT_TLSAUTH_USERNAME.3
+++ b/docs/libcurl/opts/GNURLOPT_TLSAUTH_USERNAME.3
@@@ -1,60 -1,0 +1,62 @@@
 +.\" **************************************************************************
 +.\" *                                  _   _ ____  _
 +.\" *  Project                     ___| | | |  _ \| |
 +.\" *                             / __| | | | |_) | |
 +.\" *                            | (__| |_| |  _ <| |___
 +.\" *                             \___|\___/|_| \_\_____|
 +.\" *
- .\" * Copyright (C) 1998 - 2017, Daniel Stenberg, <address@hidden>, et al.
++.\" * Copyright (C) 1998 - 2019, Daniel Stenberg, <address@hidden>, et al.
 +.\" *
 +.\" * This software is licensed as described in the file COPYING, which
 +.\" * you should have received as part of this distribution. The terms
 +.\" * are also available at https://curl.haxx.se/docs/copyright.html.
 +.\" *
 +.\" * You may opt to use, copy, modify, merge, publish, distribute and/or sell
 +.\" * copies of the Software, and permit persons to whom the Software is
 +.\" * furnished to do so, under the terms of the COPYING file.
 +.\" *
 +.\" * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF 
ANY
 +.\" * KIND, either express or implied.
 +.\" *
 +.\" **************************************************************************
 +.\"
 +.TH GNURLOPT_TLSAUTH_USERNAME 3 "19 Jun 2014" "libcurl 7.37.0" 
"curl_easy_setopt options"
 +.SH NAME
 +CURLOPT_TLSAUTH_USERNAME \- user name to use for TLS authentication
 +.SH SYNOPSIS
 +#include <gnurl/curl.h>
 +
 +CURLcode curl_easy_setopt(CURL *handle, CURLOPT_TLSAUTH_USERNAME, char *user);
 +.SH DESCRIPTION
 +Pass a char * as parameter, which should point to the zero terminated username
 +to use for the TLS authentication method specified with the
 +\fICURLOPT_TLSAUTH_TYPE(3)\fP option. Requires that the
 +\fICURLOPT_TLSAUTH_PASSWORD(3)\fP option also be set.
 +
 +The application does not have to keep the string around after setting this
 +option.
++
++This feature relies in TLS SRP which doesn't work with TLS 1.3.
 +.SH DEFAULT
 +NULL
 +.SH PROTOCOLS
 +All TLS-based protocols
 +.SH EXAMPLE
 +.nf
 +CURL *curl = curl_easy_init();
 +if(curl) {
 +  curl_easy_setopt(curl, CURLOPT_URL, "https://example.com/";);
 +  curl_easy_setopt(curl, CURLOPT_TLSAUTH_TYPE, "SRP");
 +  curl_easy_setopt(curl, CURLOPT_TLSAUTH_USERNAME, "user");
 +  curl_easy_setopt(curl, CURLOPT_TLSAUTH_PASSWORD, "secret");
 +  ret = curl_easy_perform(curl);
 +  curl_easy_cleanup(curl);
 +}
 +.fi
 +.SH AVAILABILITY
 +Added in 7.21.4
 +.SH RETURN VALUE
 +Returns CURLE_OK if the option is supported, CURLE_UNKNOWN_OPTION if not, or
 +CURLE_OUT_OF_MEMORY if there was insufficient heap space.
 +.SH "SEE ALSO"
 +.BR CURLOPT_TLSAUTH_TYPE "(3), " CURLOPT_TLSAUTH_PASSWORD "(3), "
diff --cc docs/libcurl/opts/GNURLOPT_VERBOSE.3
index 79a002c44,000000000..c2d6523c4
mode 100644,000000..100644
--- a/docs/libcurl/opts/GNURLOPT_VERBOSE.3
+++ b/docs/libcurl/opts/GNURLOPT_VERBOSE.3
@@@ -1,63 -1,0 +1,64 @@@
 +.\" **************************************************************************
 +.\" *                                  _   _ ____  _
 +.\" *  Project                     ___| | | |  _ \| |
 +.\" *                             / __| | | | |_) | |
 +.\" *                            | (__| |_| |  _ <| |___
 +.\" *                             \___|\___/|_| \_\_____|
 +.\" *
- .\" * Copyright (C) 1998 - 2014, Daniel Stenberg, <address@hidden>, et al.
++.\" * Copyright (C) 1998 - 2019, Daniel Stenberg, <address@hidden>, et al.
 +.\" *
 +.\" * This software is licensed as described in the file COPYING, which
 +.\" * you should have received as part of this distribution. The terms
 +.\" * are also available at https://curl.haxx.se/docs/copyright.html.
 +.\" *
 +.\" * You may opt to use, copy, modify, merge, publish, distribute and/or sell
 +.\" * copies of the Software, and permit persons to whom the Software is
 +.\" * furnished to do so, under the terms of the COPYING file.
 +.\" *
 +.\" * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF 
ANY
 +.\" * KIND, either express or implied.
 +.\" *
 +.\" **************************************************************************
 +.\"
 +.TH GNURLOPT_VERBOSE 3 "16 Jun 2014" "libcurl 7.37.0" "curl_easy_setopt 
options"
 +.SH NAME
 +CURLOPT_VERBOSE \- set verbose mode on/off
 +.SH SYNOPSIS
 +#include <gnurl/curl.h>
 +
 +CURLcode curl_easy_setopt(CURL *handle, CURLOPT_VERBOSE, long onoff);
 +.SH DESCRIPTION
 +Set the \fIonoff\fP parameter to 1 to make the library display a lot of
 +verbose information about its operations on this \fIhandle\fP. Very useful for
 +libcurl and/or protocol debugging and understanding. The verbose information
 +will be sent to stderr, or the stream set with \fICURLOPT_STDERR(3)\fP.
 +
 +You hardly ever want this set in production use, you will almost always want
 +this when you debug/report problems.
 +
 +To also get all the protocol data sent and received, consider using the
 +\fICURLOPT_DEBUGFUNCTION(3)\fP.
 +.SH DEFAULT
 +0, meaning disabled.
 +.SH PROTOCOLS
 +All
 +.SH EXAMPLE
 +.nf
 +CURL *curl = curl_easy_init();
 +if(curl) {
 +  curl_easy_setopt(curl, CURLOPT_URL, "http://example.com";);
 +
 +  /* ask libcurl to show us the verbose output */
 +  curl_easy_setopt(curl, CURLOPT_VERBOSE, 1L);
 +
 +  /* Perform the request */
 +  curl_easy_perform(curl);
 +}
 +.fi
 +.SH AVAILABILITY
 +Always
 +.SH RETURN VALUE
 +Returns CURLE_OK
 +.SH "SEE ALSO"
 +.BR CURLOPT_STDERR "(3), " CURLOPT_DEBUGFUNCTION "(3), "
++.BR CURLOPT_ERRORBUFFER "(3), "
diff --cc docs/libcurl/opts/GNURLOPT_XFERINFOFUNCTION.3
index 60cf2d9fa,000000000..02f471535
mode 100644,000000..100644
--- a/docs/libcurl/opts/GNURLOPT_XFERINFOFUNCTION.3
+++ b/docs/libcurl/opts/GNURLOPT_XFERINFOFUNCTION.3
@@@ -1,81 -1,0 +1,84 @@@
 +.\" **************************************************************************
 +.\" *                                  _   _ ____  _
 +.\" *  Project                     ___| | | |  _ \| |
 +.\" *                             / __| | | | |_) | |
 +.\" *                            | (__| |_| |  _ <| |___
 +.\" *                             \___|\___/|_| \_\_____|
 +.\" *
 +.\" * Copyright (C) 1998 - 2014, Daniel Stenberg, <address@hidden>, et al.
 +.\" *
 +.\" * This software is licensed as described in the file COPYING, which
 +.\" * you should have received as part of this distribution. The terms
 +.\" * are also available at https://curl.haxx.se/docs/copyright.html.
 +.\" *
 +.\" * You may opt to use, copy, modify, merge, publish, distribute and/or sell
 +.\" * copies of the Software, and permit persons to whom the Software is
 +.\" * furnished to do so, under the terms of the COPYING file.
 +.\" *
 +.\" * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF 
ANY
 +.\" * KIND, either express or implied.
 +.\" *
 +.\" **************************************************************************
 +.\"
 +.TH GNURLOPT_XFERINFOFUNCTION 3 "17 Jun 2014" "libcurl 7.37.0" 
"curl_easy_setopt options"
 +.SH NAME
 +CURLOPT_XFERINFOFUNCTION \- callback to progress meter function
 +.SH SYNOPSIS
 +#include <gnurl/curl.h>
 +
 +int progress_callback(void *clientp,
 +                      curl_off_t dltotal,
 +                      curl_off_t dlnow,
 +                      curl_off_t ultotal,
 +                      curl_off_t ulnow);
 +
 +CURLcode curl_easy_setopt(CURL *handle, CURLOPT_XFERINFOFUNCTION, 
progress_callback);
 +.SH DESCRIPTION
 +Pass a pointer to your callback function, which should match the prototype
 +shown above.
 +
 +This function gets called by libcurl instead of its internal equivalent with a
 +frequent interval. While data is being transferred it will be called very
 +frequently, and during slow periods like when nothing is being transferred it
 +can slow down to about one call per second.
 +
 +\fIclientp\fP is the pointer set with \fICURLOPT_XFERINFODATA(3)\fP, it is not
 +used by libcurl but is only passed along from the application to the callback.
 +
 +The callback gets told how much data libcurl will transfer and has
 +transferred, in number of bytes. \fIdltotal\fP is the total number of bytes
 +libcurl expects to download in this transfer. \fIdlnow\fP is the number of
 +bytes downloaded so far. \fIultotal\fP is the total number of bytes libcurl
 +expects to upload in this transfer. \fIulnow\fP is the number of bytes
 +uploaded so far.
 +
 +Unknown/unused argument values passed to the callback will be set to zero
 +(like if you only download data, the upload size will remain 0). Many times
 +the callback will be called one or more times first, before it knows the data
 +sizes so a program must be made to handle that.
 +
- Returning a non-zero value from this callback will cause libcurl to abort the
- transfer and return \fICURLE_ABORTED_BY_CALLBACK\fP.
++If your callback function returns CURL_PROGRESSFUNC_CONTINUE it will cause
++libcurl to continue executing the default progress function.
++
++Returning any other non-zero value from this callback will cause libcurl to
++abort the transfer and return \fICURLE_ABORTED_BY_CALLBACK\fP.
 +
 +If you transfer data with the multi interface, this function will not be
 +called during periods of idleness unless you call the appropriate libcurl
 +function that performs transfers.
 +
 +\fICURLOPT_NOPROGRESS(3)\fP must be set to 0 to make this function actually
 +get called.
 +.SH DEFAULT
 +By default, libcurl has an internal progress meter. That's rarely wanted by
 +users.
 +.SH PROTOCOLS
 +All
 +.SH EXAMPLE
 +https://curl.haxx.se/libcurl/c/progressfunc.html
 +.SH AVAILABILITY
 +Added in 7.32.0. This callback replaces \fICURLOPT_PROGRESSFUNCTION(3)\fP
 +.SH RETURN VALUE
 +Returns CURLE_OK.
 +.SH "SEE ALSO"
 +.BR CURLOPT_XFERINFODATA "(3), " CURLOPT_NOPROGRESS "(3), "
diff --cc include/gnurl/multi.h
index fce68f4ff,000000000..3521d85bf
mode 100644,000000..100644
--- a/include/gnurl/multi.h
+++ b/include/gnurl/multi.h
@@@ -1,461 -1,0 +1,471 @@@
 +#ifndef CURLINC_MULTI_H
 +#define CURLINC_MULTI_H
 +/***************************************************************************
 + *                                  _   _ ____  _
 + *  Project                     ___| | | |  _ \| |
 + *                             / __| | | | |_) | |
 + *                            | (__| |_| |  _ <| |___
 + *                             \___|\___/|_| \_\_____|
 + *
 + * Copyright (C) 1998 - 2019, Daniel Stenberg, <address@hidden>, et al.
 + *
 + * This software is licensed as described in the file COPYING, which
 + * you should have received as part of this distribution. The terms
 + * are also available at https://curl.haxx.se/docs/copyright.html.
 + *
 + * You may opt to use, copy, modify, merge, publish, distribute and/or sell
 + * copies of the Software, and permit persons to whom the Software is
 + * furnished to do so, under the terms of the COPYING file.
 + *
 + * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
 + * KIND, either express or implied.
 + *
 + ***************************************************************************/
 +/*
 +  This is an "external" header file. Don't give away any internals here!
 +
 +  GOALS
 +
 +  o Enable a "pull" interface. The application that uses libcurl decides where
 +    and when to ask libcurl to get/send data.
 +
 +  o Enable multiple simultaneous transfers in the same thread without making 
it
 +    complicated for the application.
 +
 +  o Enable the application to select() on its own file descriptors and curl's
 +    file descriptors simultaneous easily.
 +
 +*/
 +
 +/*
 + * This header file should not really need to include "curl.h" since curl.h
 + * itself includes this file and we expect user applications to do #include
 + * <gnurl/curl.h> without the need for especially including multi.h.
 + *
 + * For some reason we added this include here at one point, and rather than to
 + * break existing (wrongly written) libcurl applications, we leave it as-is
 + * but with this warning attached.
 + */
 +#include "curl.h"
 +
 +#ifdef  __cplusplus
 +extern "C" {
 +#endif
 +
 +#if defined(BUILDING_LIBCURL) || defined(CURL_STRICTER)
 +typedef struct Curl_multi CURLM;
 +#else
 +typedef void CURLM;
 +#endif
 +
 +typedef enum {
 +  CURLM_CALL_MULTI_PERFORM = -1, /* please call curl_multi_perform() or
 +                                    curl_multi_socket*() soon */
 +  CURLM_OK,
 +  CURLM_BAD_HANDLE,      /* the passed-in handle is not a valid CURLM handle 
*/
 +  CURLM_BAD_EASY_HANDLE, /* an easy handle was not good/valid */
 +  CURLM_OUT_OF_MEMORY,   /* if you ever get this, you're in deep sh*t */
 +  CURLM_INTERNAL_ERROR,  /* this is a libcurl bug */
 +  CURLM_BAD_SOCKET,      /* the passed in socket argument did not match */
 +  CURLM_UNKNOWN_OPTION,  /* curl_multi_setopt() with unsupported option */
 +  CURLM_ADDED_ALREADY,   /* an easy handle already added to a multi handle was
 +                            attempted to get added - again */
 +  CURLM_RECURSIVE_API_CALL, /* an api function was called from inside a
 +                               callback */
++  CURLM_WAKEUP_FAILURE, /* wakeup is unavailable or failed */
 +  CURLM_LAST
 +} CURLMcode;
 +
 +/* just to make code nicer when using curl_multi_socket() you can now check
 +   for CURLM_CALL_MULTI_SOCKET too in the same style it works for
 +   curl_multi_perform() and CURLM_CALL_MULTI_PERFORM */
 +#define CURLM_CALL_MULTI_SOCKET CURLM_CALL_MULTI_PERFORM
 +
 +/* bitmask bits for CURLMOPT_PIPELINING */
 +#define CURLPIPE_NOTHING   0L
 +#define CURLPIPE_HTTP1     1L
 +#define CURLPIPE_MULTIPLEX 2L
 +
 +typedef enum {
 +  CURLMSG_NONE, /* first, not used */
 +  CURLMSG_DONE, /* This easy handle has completed. 'result' contains
 +                   the CURLcode of the transfer */
 +  CURLMSG_LAST /* last, not used */
 +} CURLMSG;
 +
 +struct CURLMsg {
 +  CURLMSG msg;       /* what this message means */
 +  CURL *easy_handle; /* the handle it concerns */
 +  union {
 +    void *whatever;    /* message-specific data */
 +    CURLcode result;   /* return code for transfer */
 +  } data;
 +};
 +typedef struct CURLMsg CURLMsg;
 +
 +/* Based on poll(2) structure and values.
 + * We don't use pollfd and POLL* constants explicitly
 + * to cover platforms without poll(). */
 +#define CURL_WAIT_POLLIN    0x0001
 +#define CURL_WAIT_POLLPRI   0x0002
 +#define CURL_WAIT_POLLOUT   0x0004
 +
 +struct curl_waitfd {
 +  curl_socket_t fd;
 +  short events;
 +  short revents; /* not supported yet */
 +};
 +
 +/*
 + * Name:    curl_multi_init()
 + *
 + * Desc:    inititalize multi-style curl usage
 + *
 + * Returns: a new CURLM handle to use in all 'curl_multi' functions.
 + */
 +CURL_EXTERN CURLM *curl_multi_init(void);
 +
 +/*
 + * Name:    curl_multi_add_handle()
 + *
 + * Desc:    add a standard curl handle to the multi stack
 + *
 + * Returns: CURLMcode type, general multi error code.
 + */
 +CURL_EXTERN CURLMcode curl_multi_add_handle(CURLM *multi_handle,
 +                                            CURL *curl_handle);
 +
 + /*
 +  * Name:    curl_multi_remove_handle()
 +  *
 +  * Desc:    removes a curl handle from the multi stack again
 +  *
 +  * Returns: CURLMcode type, general multi error code.
 +  */
 +CURL_EXTERN CURLMcode curl_multi_remove_handle(CURLM *multi_handle,
 +                                               CURL *curl_handle);
 +
 + /*
 +  * Name:    curl_multi_fdset()
 +  *
 +  * Desc:    Ask curl for its fd_set sets. The app can use these to select() 
or
 +  *          poll() on. We want curl_multi_perform() called as soon as one of
 +  *          them are ready.
 +  *
 +  * Returns: CURLMcode type, general multi error code.
 +  */
 +CURL_EXTERN CURLMcode curl_multi_fdset(CURLM *multi_handle,
 +                                       fd_set *read_fd_set,
 +                                       fd_set *write_fd_set,
 +                                       fd_set *exc_fd_set,
 +                                       int *max_fd);
 +
 +/*
 + * Name:     curl_multi_wait()
 + *
 + * Desc:     Poll on all fds within a CURLM set as well as any
 + *           additional fds passed to the function.
 + *
 + * Returns:  CURLMcode type, general multi error code.
 + */
 +CURL_EXTERN CURLMcode curl_multi_wait(CURLM *multi_handle,
 +                                      struct curl_waitfd extra_fds[],
 +                                      unsigned int extra_nfds,
 +                                      int timeout_ms,
 +                                      int *ret);
 +
 +/*
 + * Name:     curl_multi_poll()
 + *
 + * Desc:     Poll on all fds within a CURLM set as well as any
 + *           additional fds passed to the function.
 + *
 + * Returns:  CURLMcode type, general multi error code.
 + */
 +CURL_EXTERN CURLMcode curl_multi_poll(CURLM *multi_handle,
 +                                      struct curl_waitfd extra_fds[],
 +                                      unsigned int extra_nfds,
 +                                      int timeout_ms,
 +                                      int *ret);
 +
++/*
++ * Name:     curl_multi_wakeup()
++ *
++ * Desc:     wakes up a sleeping curl_multi_poll call.
++ *
++ * Returns:  CURLMcode type, general multi error code.
++ */
++CURL_EXTERN CURLMcode curl_multi_wakeup(CURLM *multi_handle);
++
 + /*
 +  * Name:    curl_multi_perform()
 +  *
 +  * Desc:    When the app thinks there's data available for curl it calls this
 +  *          function to read/write whatever there is right now. This returns
 +  *          as soon as the reads and writes are done. This function does not
 +  *          require that there actually is data available for reading or that
 +  *          data can be written, it can be called just in case. It returns
 +  *          the number of handles that still transfer data in the second
 +  *          argument's integer-pointer.
 +  *
 +  * Returns: CURLMcode type, general multi error code. *NOTE* that this only
 +  *          returns errors etc regarding the whole multi stack. There might
 +  *          still have occurred problems on individual transfers even when
 +  *          this returns OK.
 +  */
 +CURL_EXTERN CURLMcode curl_multi_perform(CURLM *multi_handle,
 +                                         int *running_handles);
 +
 + /*
 +  * Name:    curl_multi_cleanup()
 +  *
 +  * Desc:    Cleans up and removes a whole multi stack. It does not free or
 +  *          touch any individual easy handles in any way. We need to define
 +  *          in what state those handles will be if this function is called
 +  *          in the middle of a transfer.
 +  *
 +  * Returns: CURLMcode type, general multi error code.
 +  */
 +CURL_EXTERN CURLMcode curl_multi_cleanup(CURLM *multi_handle);
 +
 +/*
 + * Name:    curl_multi_info_read()
 + *
 + * Desc:    Ask the multi handle if there's any messages/informationals from
 + *          the individual transfers. Messages include informationals such as
 + *          error code from the transfer or just the fact that a transfer is
 + *          completed. More details on these should be written down as well.
 + *
 + *          Repeated calls to this function will return a new struct each
 + *          time, until a special "end of msgs" struct is returned as a signal
 + *          that there is no more to get at this point.
 + *
 + *          The data the returned pointer points to will not survive calling
 + *          curl_multi_cleanup().
 + *
 + *          The 'CURLMsg' struct is meant to be very simple and only contain
 + *          very basic information. If more involved information is wanted,
 + *          we will provide the particular "transfer handle" in that struct
 + *          and that should/could/would be used in subsequent
 + *          curl_easy_getinfo() calls (or similar). The point being that we
 + *          must never expose complex structs to applications, as then we'll
 + *          undoubtably get backwards compatibility problems in the future.
 + *
 + * Returns: A pointer to a filled-in struct, or NULL if it failed or ran out
 + *          of structs. It also writes the number of messages left in the
 + *          queue (after this read) in the integer the second argument points
 + *          to.
 + */
 +CURL_EXTERN CURLMsg *curl_multi_info_read(CURLM *multi_handle,
 +                                          int *msgs_in_queue);
 +
 +/*
 + * Name:    curl_multi_strerror()
 + *
 + * Desc:    The curl_multi_strerror function may be used to turn a CURLMcode
 + *          value into the equivalent human readable error string.  This is
 + *          useful for printing meaningful error messages.
 + *
 + * Returns: A pointer to a zero-terminated error message.
 + */
 +CURL_EXTERN const char *curl_multi_strerror(CURLMcode);
 +
 +/*
 + * Name:    curl_multi_socket() and
 + *          curl_multi_socket_all()
 + *
 + * Desc:    An alternative version of curl_multi_perform() that allows the
 + *          application to pass in one of the file descriptors that have been
 + *          detected to have "action" on them and let libcurl perform.
 + *          See man page for details.
 + */
 +#define CURL_POLL_NONE   0
 +#define CURL_POLL_IN     1
 +#define CURL_POLL_OUT    2
 +#define CURL_POLL_INOUT  3
 +#define CURL_POLL_REMOVE 4
 +
 +#define CURL_SOCKET_TIMEOUT CURL_SOCKET_BAD
 +
 +#define CURL_CSELECT_IN   0x01
 +#define CURL_CSELECT_OUT  0x02
 +#define CURL_CSELECT_ERR  0x04
 +
 +typedef int (*curl_socket_callback)(CURL *easy,      /* easy handle */
 +                                    curl_socket_t s, /* socket */
 +                                    int what,        /* see above */
 +                                    void *userp,     /* private callback
 +                                                        pointer */
 +                                    void *socketp);  /* private socket
 +                                                        pointer */
 +/*
 + * Name:    curl_multi_timer_callback
 + *
 + * Desc:    Called by libcurl whenever the library detects a change in the
 + *          maximum number of milliseconds the app is allowed to wait before
 + *          curl_multi_socket() or curl_multi_perform() must be called
 + *          (to allow libcurl's timed events to take place).
 + *
 + * Returns: The callback should return zero.
 + */
 +typedef int (*curl_multi_timer_callback)(CURLM *multi,    /* multi handle */
 +                                         long timeout_ms, /* see above */
 +                                         void *userp);    /* private callback
 +                                                             pointer */
 +
 +CURL_EXTERN CURLMcode curl_multi_socket(CURLM *multi_handle, curl_socket_t s,
 +                                        int *running_handles);
 +
 +CURL_EXTERN CURLMcode curl_multi_socket_action(CURLM *multi_handle,
 +                                               curl_socket_t s,
 +                                               int ev_bitmask,
 +                                               int *running_handles);
 +
 +CURL_EXTERN CURLMcode curl_multi_socket_all(CURLM *multi_handle,
 +                                            int *running_handles);
 +
 +#ifndef CURL_ALLOW_OLD_MULTI_SOCKET
 +/* This macro below was added in 7.16.3 to push users who recompile to use
 +   the new curl_multi_socket_action() instead of the old curl_multi_socket()
 +*/
 +#define curl_multi_socket(x,y,z) curl_multi_socket_action(x,y,0,z)
 +#endif
 +
 +/*
 + * Name:    curl_multi_timeout()
 + *
 + * Desc:    Returns the maximum number of milliseconds the app is allowed to
 + *          wait before curl_multi_socket() or curl_multi_perform() must be
 + *          called (to allow libcurl's timed events to take place).
 + *
 + * Returns: CURLM error code.
 + */
 +CURL_EXTERN CURLMcode curl_multi_timeout(CURLM *multi_handle,
 +                                         long *milliseconds);
 +
 +#undef CINIT /* re-using the same name as in curl.h */
 +
 +#ifdef CURL_ISOCPP
 +#define CINIT(name,type,num) CURLMOPT_ ## name = CURLOPTTYPE_ ## type + num
 +#else
 +/* The macro "##" is ISO C, we assume pre-ISO C doesn't support it. */
 +#define LONG          CURLOPTTYPE_LONG
 +#define OBJECTPOINT   CURLOPTTYPE_OBJECTPOINT
 +#define FUNCTIONPOINT CURLOPTTYPE_FUNCTIONPOINT
 +#define OFF_T         CURLOPTTYPE_OFF_T
 +#define CINIT(name,type,number) CURLMOPT_/**/name = type + number
 +#endif
 +
 +typedef enum {
 +  /* This is the socket callback function pointer */
 +  CINIT(SOCKETFUNCTION, FUNCTIONPOINT, 1),
 +
 +  /* This is the argument passed to the socket callback */
 +  CINIT(SOCKETDATA, OBJECTPOINT, 2),
 +
 +    /* set to 1 to enable pipelining for this multi handle */
 +  CINIT(PIPELINING, LONG, 3),
 +
 +   /* This is the timer callback function pointer */
 +  CINIT(TIMERFUNCTION, FUNCTIONPOINT, 4),
 +
 +  /* This is the argument passed to the timer callback */
 +  CINIT(TIMERDATA, OBJECTPOINT, 5),
 +
 +  /* maximum number of entries in the connection cache */
 +  CINIT(MAXCONNECTS, LONG, 6),
 +
 +  /* maximum number of (pipelining) connections to one host */
 +  CINIT(MAX_HOST_CONNECTIONS, LONG, 7),
 +
 +  /* maximum number of requests in a pipeline */
 +  CINIT(MAX_PIPELINE_LENGTH, LONG, 8),
 +
 +  /* a connection with a content-length longer than this
 +     will not be considered for pipelining */
 +  CINIT(CONTENT_LENGTH_PENALTY_SIZE, OFF_T, 9),
 +
 +  /* a connection with a chunk length longer than this
 +     will not be considered for pipelining */
 +  CINIT(CHUNK_LENGTH_PENALTY_SIZE, OFF_T, 10),
 +
 +  /* a list of site names(+port) that are blacklisted from
 +     pipelining */
 +  CINIT(PIPELINING_SITE_BL, OBJECTPOINT, 11),
 +
 +  /* a list of server types that are blacklisted from
 +     pipelining */
 +  CINIT(PIPELINING_SERVER_BL, OBJECTPOINT, 12),
 +
 +  /* maximum number of open connections in total */
 +  CINIT(MAX_TOTAL_CONNECTIONS, LONG, 13),
 +
 +   /* This is the server push callback function pointer */
 +  CINIT(PUSHFUNCTION, FUNCTIONPOINT, 14),
 +
 +  /* This is the argument passed to the server push callback */
 +  CINIT(PUSHDATA, OBJECTPOINT, 15),
 +
 +  /* maximum number of concurrent streams to support on a connection */
 +  CINIT(MAX_CONCURRENT_STREAMS, LONG, 16),
 +
 +  CURLMOPT_LASTENTRY /* the last unused */
 +} CURLMoption;
 +
 +
 +/*
 + * Name:    curl_multi_setopt()
 + *
 + * Desc:    Sets options for the multi handle.
 + *
 + * Returns: CURLM error code.
 + */
 +CURL_EXTERN CURLMcode curl_multi_setopt(CURLM *multi_handle,
 +                                        CURLMoption option, ...);
 +
 +
 +/*
 + * Name:    curl_multi_assign()
 + *
 + * Desc:    This function sets an association in the multi handle between the
 + *          given socket and a private pointer of the application. This is
 + *          (only) useful for curl_multi_socket uses.
 + *
 + * Returns: CURLM error code.
 + */
 +CURL_EXTERN CURLMcode curl_multi_assign(CURLM *multi_handle,
 +                                        curl_socket_t sockfd, void *sockp);
 +
 +
 +/*
 + * Name: curl_push_callback
 + *
 + * Desc: This callback gets called when a new stream is being pushed by the
 + *       server. It approves or denies the new stream.
 + *
 + * Returns: CURL_PUSH_OK or CURL_PUSH_DENY.
 + */
 +#define CURL_PUSH_OK   0
 +#define CURL_PUSH_DENY 1
 +
 +struct curl_pushheaders;  /* forward declaration only */
 +
 +CURL_EXTERN char *curl_pushheader_bynum(struct curl_pushheaders *h,
 +                                        size_t num);
 +CURL_EXTERN char *curl_pushheader_byname(struct curl_pushheaders *h,
 +                                         const char *name);
 +
 +typedef int (*curl_push_callback)(CURL *parent,
 +                                  CURL *easy,
 +                                  size_t num_headers,
 +                                  struct curl_pushheaders *headers,
 +                                  void *userp);
 +
 +/* value for MAXIMUM CONCURRENT STREAMS upper limit */
 +#define INITIAL_MAX_CONCURRENT_STREAMS ((1U << 31) - 1)
 +
 +#ifdef __cplusplus
 +} /* end of extern "C" */
 +#endif
 +
 +#endif
diff --cc tests/Makefile.am
index 3a3a921bb,b4cb9012e..5d877d7ec
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@@ -24,24 -26,19 +24,25 @@@ MANDISTPAGES = runtests.1.dist testcurl
  
  # the path to the impacket python lib used for SMB tests
  IMP = python_dependencies/impacket
 -SMBDEPS = $(IMP)/__init__.py $(IMP)/nmb.py $(IMP)/nt_errors.py          \
 - $(IMP)/ntlm.py $(IMP)/smb.py $(IMP)/smb3.py $(IMP)/smb3structs.py      \
 - $(IMP)/smbserver.py $(IMP)/spnego.py $(IMP)/structure.py               \
 - $(IMP)/uuid.py $(IMP)/version.py smbserver.py curl_test_data.py
 -
 -EXTRA_DIST = ftpserver.pl httpserver.pl secureserver.pl runtests.pl           
\
 - getpart.pm FILEFORMAT README stunnel.pem memanalyze.pl testcurl.pl           
\
 - valgrind.pm ftp.pm sshserver.pl sshhelp.pm pathhelp.pm testcurl.1 runtests.1 
\
 - serverhelp.pm tftpserver.pl rtspserver.pl directories.pm symbol-scan.pl      
\
 - CMakeLists.txt mem-include-scan.pl valgrind.supp extern-scan.pl              
\
 - manpage-scan.pl nroff-scan.pl http2-server.pl dictserver.py                  
\
 - negtelnetserver.py $(SMBDEPS) objnames-test08.sh objnames-test10.sh          
\
 - objnames.inc disable-scan.pl manpage-syntax.pl error-codes.pl
++
 +SMB_1 = $(IMP)/__init__.py $(IMP)/nmb.py $(IMP)/nt_errors.py
 +SMB_2 = $(IMP)/ntlm.py $(IMP)/smb.py $(IMP)/smb3.py $(IMP)/smb3structs.py
 +SMB_3 = $(IMP)/smbserver.py $(IMP)/spnego.py $(IMP)/structure.py
 +SMB_4 = $(IMP)/uuid.py $(IMP)/version.py smbserver.py.in curl_test_data.py.in
 +SMBDEPS = $(SMB_1) $(SMB_2) $(SMB_3) $(SMB_4)
 +
 +ED_1 = ftpserver.pl httpserver.pl secureserver.pl runtests.pl
 +ED_2 = getpart.pm FILEFORMAT README stunnel.pem memanalyze.pl testcurl.pl
 +ED_3 = valgrind.pm ftp.pm sshserver.pl sshhelp.pm pathhelp.pm testcurl.1 
runtests.1
 +ED_4 = serverhelp.pm tftpserver.pl rtspserver.pl directories.pm symbol-scan.pl
 +ED_5 = mem-include-scan.pl valgrind.supp extern-scan.pl
 +ED_6 = manpage-scan.pl nroff-scan.pl http2-server.pl dictserver.py.in
 +ED_7 = negtelnetserver.py.in $(SMBDEPS) objnames-test08.sh objnames-test10.sh
- ED_8 = objnames.inc disable-scan.pl
++ED_8 = objnames.inc disable-scan.pl error-codes.pl CMakeLists.txt
 +
 +EXTRA_DIST = $(ED_1) $(ED_2) $(ED_3) $(ED_4) $(ED_5) $(ED_6) $(ED_7) $(ED_8)
 +
 +check_SCRIPTS = smbserver.py curl_test_data.py negtelnetserver.py 
dictserver.py
  
  DISTCLEANFILES = configurehelp.pm
  
diff --cc tests/data/DISABLED
index 61bdf1351,61bdf1351..f0d6f8c7f
--- a/tests/data/DISABLED
+++ b/tests/data/DISABLED
@@@ -28,3 -28,3 +28,5 @@@
  1901
  1902
  2033
++# Unused in gnurl
++test1173
diff --cc tests/runtests.1
index 18ddce483,69aafe579..fab635233
--- a/tests/runtests.1
+++ b/tests/runtests.1
@@@ -70,7 -70,7 +70,7 @@@ detected. Useful for debugging
  .IP "-l"
  Lists all test case names.
  .IP "-n"
--Disable the check for and use of valgrind.
++Disable the check for and the use of valgrind.
  .IP "-p"
  Prints out all files in "log/" to stdout when a test case fails. Very
  practical when used in the automated and distributed tests since then the
diff --cc tests/runtests.pl
index 5ab234c0d,27f62edd5..e5c10858c
--- a/tests/runtests.pl
+++ b/tests/runtests.pl
@@@ -150,7 -150,7 +150,7 @@@ my $SMBSPORT;            # SMBS server 
  my $NEGTELNETPORT;       # TELNET server port with negotiation
  
  my $srcdir = $ENV{'srcdir'} || '.';
- my $CURL="../src/gnurl".exe_ext(); # what curl executable to run on the tests
 -my $CURL="../src/curl".exe_ext('TOOL'); # what curl executable to run on the 
tests
++my $CURL="../src/gnurl".exe_ext('TOOL'); # what curl executable to run on the 
tests
  my $VCURL=$CURL;   # what curl binary to use to verify the servers with
                     # VCURL is handy to set to the system one when the one you
                     # just built hangs or crashes and thus prevent verification

-- 
To stop receiving notification emails like this one, please contact
address@hidden.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]