https://redmine.lighttpd.net/https://redmine.lighttpd.net/favicon.ico?13667327412017-05-24T22:44:09Zlighty labsLighttpd - Feature #2813: Support for HTTP/2 protocolhttps://redmine.lighttpd.net/issues/2813?journal_id=110422017-05-24T22:44:09Zgstrauss
<ul><li><strong>Has duplicate</strong> <i><a class="issue tracker-2 status-10 priority-3 priority-lowest closed" href="/issues/2726">Feature #2726</a>: Support for HTTP/2 protocol</i> added</li></ul> Lighttpd - Feature #2813: Support for HTTP/2 protocolhttps://redmine.lighttpd.net/issues/2813?journal_id=120232020-08-28T08:41:37Zgstrauss
<ul><li><strong>Status</strong> changed from <i>New</i> to <i>Patch Pending</i></li><li><strong>Priority</strong> changed from <i>Low</i> to <i>Normal</i></li><li><strong>Target version</strong> set to <i>1.4.56</i></li><li><strong>ASK QUESTIONS IN Forums</strong> set to <i>No</i></li></ul><p>I am nearly ready to post to my development branch some pre-alpha code with basic HTTP/2 support, and might be ready as early as this weekend.</p>
<p>Are there some volunteers who would be willing to build lighttpd from source (off of my development branch)?</p>
<p>Please be aware that HTTP/2 support in lighttpd entails a very large set of code changes, and there are quite possibly some critical bugs (crashing, memory leaks, etc) in this pre-alpha implementation of the HTTP/2 protocol in lighttpd. This is not intended for production use.</p>
<p>Caveats aside, my testing thus far performs nicely with h2load and passes h2spec tests<br /><a class="external" href="https://nghttp2.org/documentation/h2load-howto.html">https://nghttp2.org/documentation/h2load-howto.html</a><br /><a class="external" href="https://github.com/summerwind/h2spec">https://github.com/summerwind/h2spec</a></p>
<p>I did have to make an adjustment for h2spec tests to pass, and have filed some issues upstream for h2spec.<br />- <a class="external" href="https://github.com/summerwind/h2spec/issues/120">https://github.com/summerwind/h2spec/issues/120</a><br />- <a class="external" href="https://github.com/summerwind/h2spec/issues/121">https://github.com/summerwind/h2spec/issues/121</a><br />- <a class="external" href="https://github.com/summerwind/h2spec/issues/122">https://github.com/summerwind/h2spec/issues/122</a></p>
<p>The pre-alpha HTTP/2 implementation has some limitations.<br />TODO: more testing<br />TODO: performance tuning<br />TODO: do something better than ignoring HTTP/2 PRIORITY (handled and discarded)<br />TODO: add additional debugging trace<br />TODO: mod_status modifications<br />...<br />future: enforce HTTP/2 requirements in TLS (or return INADEQUATE_SECURITY)<br />future: improve HTTP trailers support (maybe; low priority)<br />future: enhancements such as server-side PUSH_PROMISE (distant future; NOT IMPLEMENTED)</p>
<p>(If you do not want to receive email updates on this issue, please ask me to remove you from Watchers list on this issue, or you may do so yourself)</p> Lighttpd - Feature #2813: Support for HTTP/2 protocolhttps://redmine.lighttpd.net/issues/2813?journal_id=120252020-08-29T00:50:45Zgstrauss
<ul></ul><p>HTTP/2 development in lighttpd 1.4.x: discussion started in the lighttpd Development forum at: <a class="external" href="https://redmine.lighttpd.net/boards/3/topics/9339">https://redmine.lighttpd.net/boards/3/topics/9339</a><br />Let's please keep discussion on the development forum, and I'll summarize status here in the issue ticket.</p>
<p>I have pushed my development branch <code>personal/gstrauss/master</code> with support for HTTP/2.<br />Please refer to <a class="wiki-page" href="https://redmine.lighttpd.net/projects/lighttpd/wiki/DevelGit">DevelGit</a> for how to obtain the source code.</p>
<p>Please be aware that <code>personal/gstrauss/master</code> is my <strong>development</strong> branch, and I often edit and rewrite the git history during development.<br />Please <code>git pull --rebase</code> to fetch changes, including the rewritten history.</p>
<p>HTTP/2 support in lighttpd (development) can be enabled in lighttpd.conf with:<br /><code>server.feature-flags += ("server.h2proto" => "enable")</code><br />For now, server.h2proto is disabled by default.</p>
<p>In addition to the above, <code>Upgrade: h2c</code> support can be enabled with<br /><code>server.feature-flags += ("server.h2c" => "enable")</code></p> Lighttpd - Feature #2813: Support for HTTP/2 protocolhttps://redmine.lighttpd.net/issues/2813?journal_id=120362020-10-19T06:16:28Zgstrauss
<ul></ul><p>h2spec is a conformance testing tool for HTTP/2 implementation.<br /><a class="external" href="https://github.com/summerwind/h2spec">https://github.com/summerwind/h2spec</a></p>
<p>Running h2spec against lighttpd requires a target file (/index.html) at least 16k+1 bytes in size (16385) or else some of the tests (which expect multiple frames) do not pass.<br />(documenting some manual testing from August) (edit: with lighttpd 1.4.60, target file must be at least 32k+1 bytes (32769))</p>
While h2spec has been very useful in testing lighttpd HTTP/2 support, there are a number of shortcomings for which I have provided patches upstream.
<ul>
<li><a class="external" href="https://github.com/summerwind/h2spec/issues/120">https://github.com/summerwind/h2spec/issues/120</a></li>
<li><a class="external" href="https://github.com/summerwind/h2spec/issues/121">https://github.com/summerwind/h2spec/issues/121</a></li>
<li><a class="external" href="https://github.com/summerwind/h2spec/issues/122">https://github.com/summerwind/h2spec/issues/122</a></li>
</ul>
<p>In the meantime, <code>lighttpd h2.c:h2_recv_headers()</code> has a <code>#if 0</code> block that sends stream PROTOCOL_ERROR instead of 400 Bad Request, and enabling the block allows lighttpd to pass all h2spec tests except for the generic/5 HPACK test (for HTTPS), and for the generic/5 HPACK test and http2/3.5 HTTP/2 Connection Preface test (for HTTP). lighttpd behavior conforms to the RFCs; these test failures<br />are false positives. See the links above for suggested fixes to h2spec.</p>
<p><code>h2spec -P /index.html -p 8443 -S -k -t</code><br /><code>h2spec -P /index.html -p 8080 -S</code></p> Lighttpd - Feature #2813: Support for HTTP/2 protocolhttps://redmine.lighttpd.net/issues/2813?journal_id=120382020-10-20T22:28:13Zgstrauss
<ul><li><strong>Status</strong> changed from <i>Patch Pending</i> to <i>Fixed</i></li></ul><p>HTTP/2 support has been merged to lighttpd 1.4 master branch</p>