* Move up bind_impl so that it can be found by non-MSVC.
* Avoid useless qualification making GCC unhappy.
* Make GZIP/DEFLATE/BROTLI constant chars.
* Remove unneeded ;
* Remove broken qualification attempting to forward declare web::http::compression::decompress_factory.
* Don't use nonstandard for each.
* Remove another unnecessary const.
* Mark unused parameters with (void).
* Guard -Wno-format-truncation from GCC 5.4.
* Fix bogus writtenSize warning from GCC 5.4.
* Attempt to avoid std::make_unique in compression tests.
* Avoid Concurrency::task_group_status because gcc 5.4 hates it for some reason.
* Fix default installation path
* Fixup previous commit.
This makes the install location not correct for Debian and similar linux distro, but upstream don't plan to change "lib/cpprestsdk" location,
so at least we can override the location with -DCPPREST_EXPORT_DIR=cmake and keep the CMAKE_INSTALL_LIBDIR multiarch location
* Implement host override of CN checking in the ASIO backend
Add new function calc_cn_host which applies our host header override policy.
Add the CN hostname used to asio_connection. Change the protocol such that the SSL upgrade request needs to come with the target hostname to use.
Replace std::deque in connection pooling with a version that has constant amortized time per insertion. (std::deque is only constant amortized time for insertions in terms of element operations, not overall). Factor out the replacement policy from the overall pool machinery.
Change release() to take shared_ptr&& to make sure the caller has let go.
Enable verify_cert_chain_platform_specific on Windows; otherwise OpenSSL says that the root CAs are untrusted and all SSL tests fail on Windows.
This accidentially repairs these test cases on Windows:
**** outside_tests:outside_wikipedia_compressed_http_response FAILED ****
**** outside_tests:multiple_https_requests FAILED ****
**** outside_tests:outside_ssl_json FAILED ****
* Add missing std::move.
* Use hot connections instead of cold connections in connection pool.
* Put timer start code back.
* Reset the shared_ptr when it is being dropped.
* Fix end comment broken by merge hell.
* Implement CN overrides via the Host: header in the WinHTTP backend.
* Repair lack of fallback CN verification on Windows.
* Set security settings even for non-HTTPS URIs in WinHTTP, in case we get upgraded to SSL/TLS later.
* Add test to make sure this doesn't explode.
* Repair CPPREST_EXCLUDE_WEBSOCKETS support.
* Move x509_cert_utilities.h out of public headers.
AND_CAPTURE_MEMBER_FUNCTION_POINTERS workaround had a check for GCC,
but did not exclude Clang. Clang has a fake GCC version of 4.2, thus
caused problems.
* Microperf: Use lock_guard instead of unique_lock.
* Bill hates lock_guard more.
* Ref them connections.
* Demacroize.
* Commonize port and merge some CRLFs into adjacent string literals.
* Add missing template keyword.
* Avoid stringstream in constructing the proxy_str.
* Remove unused forward declarations of some HTTP things.
* Use NOMINMAX instead of undef min and max everywhere.
* Bunch of inheritance hygiene.
* What do you mean you want examples to compile?
* More CR comments from Robert.
* Add static.
* Use existing to_string_t.
* Update CMakeLists.txt to install the cmake bindings in the right location
/usr/lib/cpprestsdk is not the correct FHS standard cmake location.
It should be placed in /usr/lib/<triplet>/cmake/cpprestsdk instead.
Same goes for libraries, support multiarch location if we use UNIX
* Revert changes to CPPREST_EXPORT_DIR. Use GNUInstallDirs on all platforms.
* Add asio_connection::was_closed_by_server() to reduce duplication
Reduce code duplication between ssl_proxy_tunnel::handle_status_line()
and the method with the same name in asio_context itself by moving the
common handling of connections closed by server into a new function.
No real changes, this is a pure refactoring.
* Fix checking for server-side closure of HTTPS connections
When an SSL connection times out due to being closed by server, a
different error code is returned, so we need to check for it too in
was_closed_by_server().
Without this, losing connection was not detected at all when using
HTTPS, resulting in "Failed to read HTTP status line" errors whenever
the same http_client was reused after more than the server keep alive
timeout of inactivity.
See #592.
* Fix bug with using re-opened connections with ASIO
Creating a new request when the existing connection being used was
closed by the server didn't work correctly because the associated input
stream was already exhausted, as its contents had been already "sent" to
the server using the now discarded connection, so starting a new request
using the same body stream never worked.
Fix this by explicitly rewinding the stream to the beginning before
using it again.
Note that even with this fix using a custom body stream which is not
positioned at the beginning initially (or which doesn't support
rewinding) still wouldn't work, but at least it fixes the most common
use case.
See #592.
* Reduce duplicate code between ssl_proxy and asio_context in handle_read_status_line.
Avoid increasing public surface with rewind function.
* Improve error handling in on_accept
* Move lock to the top of the function
* Lock shared data at the right locations.
* [http_listener] improve refcount and lifetime management by using RAII.
* Delete open() from _http_client_communicator and move its functionality into WinHTTP, as that is the only backend using that thing.
* Some CR comments from Robert.