{"id":13000,"date":"2020-01-08T08:13:04","date_gmt":"2020-01-08T07:13:04","guid":{"rendered":"https:\/\/daniel.haxx.se\/blog\/?p=13000"},"modified":"2020-01-08T10:23:15","modified_gmt":"2020-01-08T09:23:15","slug":"curl-7-68-0-with-etags-and-bearssl","status":"publish","type":"post","link":"https:\/\/daniel.haxx.se\/blog\/2020\/01\/08\/curl-7-68-0-with-etags-and-bearssl\/","title":{"rendered":"curl 7.68.0 with etags and BearSSL"},"content":{"rendered":"\n<p>The year is still young, and we&#8217;re here to really kick off 2020 with a brand new curl release! curl 7.68.0 is available at <a href=\"https:\/\/curl.haxx.se\/\">curl.haxx.se<\/a> as always. Once again we&#8217;ve worked hard and pushed through another release cycle to bring you the very best we could do in the 63 days since <a href=\"https:\/\/daniel.haxx.se\/blog\/2019\/11\/06\/curl-7-67-0\/\">7.67.0<\/a>.<\/p>\n\n\n\n<p>(The previous release was said to be the 186th, but it turned out we&#8217;ve been <a href=\"https:\/\/daniel.haxx.se\/blog\/2020\/01\/04\/restored-complete-curl-changelog\/\">off-by-one on the release counter for a while<\/a>.)<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Numbers<\/h2>\n\n\n\n<p class=\"has-text-align-center\"><strong>the 188th release<br>6 changes<br>63 days (total: 7,964)<\/strong><br><strong>124 bug fixes (total: 5,788)<\/strong><br><strong>193 commits (total: 25,124)<br>1 new public libcurl function (total: 82)<br>0 new curl_easy_setopt() option (total: 269)<\/strong><br><strong>3 new curl command line option (total: 229)<\/strong><br><strong>70 contributors, 32 new (total: 2,088)<\/strong><br><strong>31 authors, 13 new (total: 756)<\/strong><br><strong>1 security fixes (total: 93)<\/strong><br><strong>400 USD paid in Bug Bounties<\/strong><\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Security Vulnerability<\/h2>\n\n\n\n<p><a href=\"https:\/\/curl.haxx.se\/docs\/CVE-2019-15601.html\">CVE-2019-15601<\/a>: SMB access smuggling via FILE URL on Windows.<\/p>\n\n\n\n<p>Simply put: you could provide a FILE:\/\/ URL to curl that could trick it to try to access a host name over SMB &#8211; on Windows machines. This could happen because Windows apparently always do this automatically if given the correct file name and curl had no specific filter to avoid it.<\/p>\n\n\n\n<p>For this discovery and report, the <a href=\"https:\/\/curl.haxx.se\/docs\/bugbounty.html\">curl Bug Bounty program<\/a> has rewarded Fernando Mu\u00f1oz 400 USD.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Changes<\/h2>\n\n\n\n<p>We ship a <a href=\"https:\/\/daniel.haxx.se\/blog\/2019\/12\/11\/bearssl-is-curls-14th-tls-backend\/\">new TLS backend: BearSSL<\/a>. The 14th.<\/p>\n\n\n\n<p>We ship <a href=\"https:\/\/daniel.haxx.se\/blog\/2019\/12\/06\/curl-speaks-etag\/\">two new command line options for ETags<\/a>. <\/p>\n\n\n\n<p>We provide a <a href=\"https:\/\/daniel.haxx.se\/blog\/2019\/12\/09\/this-is-your-wake-up-curl\/\">new API call to wakeup &#8220;sleeping&#8221; libcurl poll<\/a> calls.<\/p>\n\n\n\n<p>We changed the default handling in libcurl with OpenSSL for verifying certificates. We now allow &#8220;partial chains&#8221; by default, meaning that you can use an intermediate cert to verify the server cert, not necessarily the whole chain to the root, like you did before. This brings the OpenSSL backend to work more similar to the other TLS backends, and we offer a new option for applications to switch back on the old behavior (<a href=\"https:\/\/curl.haxx.se\/libcurl\/c\/CURLOPT_SSL_OPTIONS.html\">CURLSSLOPT_NO_PARTIALCHAIN).<\/a><\/p>\n\n\n\n<p>The progress callback has a new feature: if you return <a href=\"https:\/\/curl.haxx.se\/libcurl\/c\/CURLOPT_XFERINFOFUNCTION.html\">CURL_PROGRESSFUNC_CONTINUE<\/a> from the callback, it will continue and call the internal progress meter.<\/p>\n\n\n\n<p>The new command line option <code><a href=\"https:\/\/curl.haxx.se\/docs\/manpage.html#--parallel-immediate\">--parallel-immediate<\/a><\/code> is added, and if used will make curl do parallel transfers like before 7.68.0. Starting with 7.68.0, curl will default to defer new connections and rather try to multiplex new transfer over an existing connection if more than one transfer is specified to be done from the same host name.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Bug-fixes<\/h2>\n\n\n\n<p>Some of my favorite fixes done since the last release include&#8230;<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Azure CI and torture<\/h3>\n\n\n\n<p>This cycle we started running a bunch of CI tests on Azure Pipelines, both Linux and macOS tests. We also managed to get torture tests running thanks to the <a href=\"https:\/\/daniel.haxx.se\/blog\/2019\/12\/16\/how-randomly-skipping-tests-made-them-better\/\">new shallow mode<\/a>.<\/p>\n\n\n\n<p>Azure seem to run faster and more reliable than Travis CI, so moving a few jobs over has made a total build run often complete in less total time now.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">prefer multiplexing to using new connections<\/h3>\n\n\n\n<p>A regression was found that made the connection reuse logic in libcurl to prefer new connections to multiplexing more than what was actually intended and once fixed we should see libcurl-using application do more and better HTTP\/2 multiplexing.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">support for ECDSA and ed25519 knownhost keys with libssh2<\/h3>\n\n\n\n<p>libssh2 is the primary SSH backend people use with curl. While the library itself has supported these new &#8220;knownhost&#8221; keys for a while, we hadn&#8217;t previously adjusted curl to play nicely with them. Until now.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">openssl: Revert to less sensitivity for SYSCALL errors<\/h3>\n\n\n\n<p>Another regression in the OpenSSL backend code made curl overly sensitive to some totally benign TLS messages which would cause a curl error when they should just have been silently handled and closed the connection cleanly.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">openssl: set X509_V_FLAG_PARTIAL_CHAIN by default<\/h3>\n\n\n\n<p>The OpenSSL backend now behaves more similar to other TLS backends in curl and now accepts &#8220;partial&#8221; certificate chains. That means you don&#8217;t need to have the entire chain locally all the way to the root in order to verify a server certificate. Unless you set <a href=\"https:\/\/curl.haxx.se\/libcurl\/c\/CURLOPT_SSL_OPTIONS.html\">CURLSSLOPT_NO_PARTIALCHAIN<\/a> to enforce that behavior.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">parsedate: offer a getdate_capped() alternative<\/h3>\n\n\n\n<p>The date parser was extended to make curl handle dates beyond 2038 better on 32 bit systems, which primarily seems to happen with cookies. Now the parser understands that they&#8217;re too big and will use the max time value it can hold instead of failing and using a zero, as that would make the cookies into &#8220;session cookies&#8221; which would have slightly different behavior.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Video presenting the release<\/h2>\n\n\n\n<iframe loading=\"lazy\" width=\"560\" height=\"315\" src=\"https:\/\/www.youtube.com\/embed\/NcPcvhZVn7k\" frameborder=\"0\" allow=\"accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture\" allowfullscreen><\/iframe>\n","protected":false},"excerpt":{"rendered":"<p>The year is still young, and we&#8217;re here to really kick off 2020 with a brand new curl release! curl 7.68.0 is available at curl.haxx.se as always. Once again we&#8217;ve worked hard and pushed through another release cycle to bring you the very best we could do in the 63 days since 7.67.0. (The previous &hellip; <a href=\"https:\/\/daniel.haxx.se\/blog\/2020\/01\/08\/curl-7-68-0-with-etags-and-bearssl\/\" class=\"more-link\">Continue reading <span class=\"screen-reader-text\">curl 7.68.0 with etags and BearSSL<\/span> <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":5,"featured_media":11350,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[7],"tags":[33,95],"class_list":["post-13000","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-curl","tag-curl-and-libcurl","tag-release"],"_links":{"self":[{"href":"https:\/\/daniel.haxx.se\/blog\/wp-json\/wp\/v2\/posts\/13000","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/daniel.haxx.se\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/daniel.haxx.se\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/daniel.haxx.se\/blog\/wp-json\/wp\/v2\/users\/5"}],"replies":[{"embeddable":true,"href":"https:\/\/daniel.haxx.se\/blog\/wp-json\/wp\/v2\/comments?post=13000"}],"version-history":[{"count":10,"href":"https:\/\/daniel.haxx.se\/blog\/wp-json\/wp\/v2\/posts\/13000\/revisions"}],"predecessor-version":[{"id":13169,"href":"https:\/\/daniel.haxx.se\/blog\/wp-json\/wp\/v2\/posts\/13000\/revisions\/13169"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/daniel.haxx.se\/blog\/wp-json\/wp\/v2\/media\/11350"}],"wp:attachment":[{"href":"https:\/\/daniel.haxx.se\/blog\/wp-json\/wp\/v2\/media?parent=13000"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/daniel.haxx.se\/blog\/wp-json\/wp\/v2\/categories?post=13000"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/daniel.haxx.se\/blog\/wp-json\/wp\/v2\/tags?post=13000"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}