1
0
mirror of https://github.com/apache/httpd.git synced 2025-08-08 15:02:10 +03:00

46 Commits

Author SHA1 Message Date
Stefan Eissing
3ed9d65b05 *) mod_http2: added support for bootstrapping WebSockets via HTTP/2, as
described in RFC 8441. A new directive 'H2WebSockets on|off' has been
     added. The feature is by default not enabled.
     As also discussed in the manual, this feature should work for setups
     using "ProxyPass backend-url upgrade=websocket" without further changes.
     Special server modules for WebSockets will have to be adapted,
     most likely, as the handling if IO events is different with HTTP/2.
     HTTP/2 WebSockets are supported on platforms with native pipes. This
     excludes Windows.



git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1910507 13f79535-47bb-0310-9956-ffa450edef68
2023-06-20 12:01:09 +00:00
Yann Ylavic
d49af21477 mod_http2: Fix memory leak in calc_sha256_hash().
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1908502 13f79535-47bb-0310-9956-ffa450edef68
2023-03-18 15:28:33 +00:00
Stefan Eissing
61ebb22bf9 Sync with v2.0.10 from github:
* Extensive testing in production done by Alessandro Bianchi (@alexskynet)
   on the v2.0.x versions for stability. Many thanks!
 * refactored stream response handling to reflect the different phases
   (response/data/trailers) more clearly and help resolving cpu busy loops.
 * Adding more negative tests for handling of errored responses to cover
   edge cases.
 * mod_http2: fixed handling of response where neiter an EOS nor an ERROR was
   received as a cause to reset the stream.
 * mod_proxy_http2: generating error buckets for fault response bodies, to
   signal failure to fron when response header were already sent.

v2.0.9
--------------------------------------------------------------------------------
 * Fixed a bug where errors during reponse body handling did not lead to
   a proper RST_STREAM. Instead processing went into an infinite loop.
   Extended test cases to catch this condition.

v2.0.8
--------------------------------------------------------------------------------
 * Delaying input setup of a stream just before processing starts. This allows
   any EOS indicator arriving from the client before that to take effect.
   Without knowing that a stream has no input, internal processing has to
   simulate chunked encoding. This is not wrong, but somewhat more expensive
   and mod_security has been reported to be allergic to seeing 'chunked'
   on some requests. See <https://bz.apache.org/bugzilla/show_bug.cgi?id=66282>.
 * mod_proxy_http2: fixed #235 by no longer forwarding 'Host:' header when
   request ':authority' is known. Improved test case that did not catch that
   the previous 'fix' was incorrect.



git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1904522 13f79535-47bb-0310-9956-ffa450edef68
2022-10-11 14:54:08 +00:00
Stefan Eissing
cc77f54228 *) mod_http2: synchronization with github sources.
Building in trunk and against 2.4.x is now supported
     via AP_HAS_RESPONSE_BUCKETS defines.



git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1904305 13f79535-47bb-0310-9956-ffa450edef68
2022-09-27 13:21:21 +00:00
Stefan Eissing
b88117f602 *) mod_http2: type adjustments and castings for int/apr_uint32_t/apr_size_t/apr_off_t.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1904297 13f79535-47bb-0310-9956-ffa450edef68
2022-09-27 10:53:51 +00:00
Stefan Eissing
8ce99f9ef1 *) mod_http2: use the new RESPONSE buckets introduced in r1899648.
This replaces the internal H2_HEADERS bucket, removing its
     source file and also obsoletes any interim response parsing
     needs.



git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1899649 13f79535-47bb-0310-9956-ffa450edef68
2022-04-07 10:55:09 +00:00
Stefan Eissing
6a355db082 *) mod_http2:
- Fixed an issue since 1.15.24 that "Server" headers in proxied requests
       were overwritten instead of preserved. [PR by @daum3ns]
     - Added directove 'H2StreamTimeout' to configure a separate value for HTTP/2
       streams, overriding server's 'Timeout' configuration. [rpluem]
     - HTTP/2 connections now use pollsets to monitor the status of the
       ongoing streams and their main connection when host OS allows this.
     - Removed work-arounds for older versions of libnghttp2 and checking
       during configure that at least version 1.15.0 is present.
     - The HTTP/2 connection state handler, based on an experiment and draft
       at the IETF http working group (abandoned for some time), has been removed.
     - H2SerializeHeaders no longer has an effect. A warning is logged when it is
       set to "on". The switch enabled the internal writing of requests to be parsed
       by the internal HTTP/1.1 protocol handler and was introduced to avoid
       potential incompatibilities during the introduction of HTTP/2.
     - Removed the abort/redo of tasks when mood swings lower the active limit.



git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1894163 13f79535-47bb-0310-9956-ffa450edef68
2021-10-12 13:34:01 +00:00
Stefan Eissing
fe3a48a632 * Switch to using OpenSSL EVP_* API to avoid deprecation warnings with
OpenSSL 3.0. [@notroj]



git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1893220 13f79535-47bb-0310-9956-ffa450edef68
2021-09-10 09:46:05 +00:00
Stefan Eissing
f1e4032670 *) mod_http2: remote support for abandoned http-wg draft
<https://datatracker.ietf.org/doc/draft-kazuho-h2-cache-digest/>.



git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1880395 13f79535-47bb-0310-9956-ffa450edef68
2020-07-29 12:15:58 +00:00
Mike Rumph
85760859ca Fix spelling errors found by codespell. [skip ci]
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1873985 13f79535-47bb-0310-9956-ffa450edef68
2020-02-13 18:15:57 +00:00
Stefan Eissing
5b32f27b77 * modules/http2: reverting r1859724, as no good.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1860257 13f79535-47bb-0310-9956-ffa450edef68
2019-05-28 12:42:17 +00:00
Stefan Eissing
d5767ac605 *) mod_http2: internal code cleanups and simplifications. Common output code for
h2 and h2c protocols, using nested mutex locks for simplified calls. [Stefan Eissing]



git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1859724 13f79535-47bb-0310-9956-ffa450edef68
2019-05-22 13:41:36 +00:00
Stefan Eissing
67ff312994 mod_http2: bringing some signed/unsigned casting goodness, aligning with github mod-h2 again
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1843424 13f79535-47bb-0310-9956-ffa450edef68
2018-10-10 11:22:53 +00:00
Stefan Eissing
03e3ef23a8 On the trunk:
mod_http2: accurate reporting of h2 data input/output per request via mod_logio. Fixes
     an issue where output sizes where counted n-times on reused slave connections. See
     gituhub issue: https://github.com/icing/mod_h2/issues/158


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1828687 13f79535-47bb-0310-9956-ffa450edef68
2018-04-09 09:39:08 +00:00
Stefan Eissing
eb0fb1c922 On the trunk:
mod_http2: removing comments that documented that greenbytes has untransferable copyright to the sources. The rights, of course, remain unaffected, but maybe some people can sleep better.



git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1821371 13f79535-47bb-0310-9956-ffa450edef68
2018-01-17 14:41:30 +00:00
Jim Jagielski
1aa89da70c correct copyright/license headers
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1818306 13f79535-47bb-0310-9956-ffa450edef68
2017-12-15 17:10:14 +00:00
Stefan Eissing
7c8a148333 On the trunk:
mod_http2: aplogno tags, more unified log formatting



git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1782958 13f79535-47bb-0310-9956-ffa450edef68
2017-02-14 12:54:22 +00:00
Stefan Eissing
d300afee34 mod_http2: H2PushResource directive for early pushing
mod_proxy_http2: Link header uris are reverse mapped


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1769550 13f79535-47bb-0310-9956-ffa450edef68
2016-11-13 21:30:40 +00:00
Stefan Eissing
fc770710e1 mod_http2/mod_proxy_http2: proper 100-continue handling up to backend, more robustness on connection reuse with PING frames
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1765318 13f79535-47bb-0310-9956-ffa450edef68
2016-10-17 15:52:01 +00:00
Stefan Eissing
0da36a75f8 mod_http2: reverting int->apr_uint32_t changes of v1.7.x
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1764005 13f79535-47bb-0310-9956-ffa450edef68
2016-10-09 20:22:40 +00:00
Stefan Eissing
2d12cf2d7a various fixes, mod_cgid interop, response/trailer forwarding rewritten, stability
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1763158 13f79535-47bb-0310-9956-ffa450edef68
2016-10-03 11:47:45 +00:00
Stefan Eissing
08df710604 mod_http2: more const goodiness and checks on h2 request creation, less NULL checking while processing
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1759547 13f79535-47bb-0310-9956-ffa450edef68
2016-09-07 06:44:16 +00:00
Rainer Jung
d79b514c4b Fix spelling in comments and text files.
No functional change.
PR 59990


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1756038 13f79535-47bb-0310-9956-ffa450edef68
2016-08-11 19:50:02 +00:00
Stefan Eissing
824121f7f9 mod_http2/mod_proxy_http2: no longer reusing h2_request.o for proxy module
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1741596 13f79535-47bb-0310-9956-ffa450edef68
2016-04-29 09:35:18 +00:00
Stefan Eissing
c828bbc586 mod_http2: some DoS protection, fix for read after free
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1733113 13f79535-47bb-0310-9956-ffa450edef68
2016-03-01 17:19:25 +00:00
Stefan Eissing
b65f9f1e49 adding accep,accept-encoding headers from initiating request to push promises
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1732507 13f79535-47bb-0310-9956-ffa450edef68
2016-02-26 15:56:20 +00:00
Stefan Eissing
dce4ce7f57 mod_proxy_http2: start of some sort of flow control, mod_http2: keeping spare allocator_t for slave connections around
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1732477 13f79535-47bb-0310-9956-ffa450edef68
2016-02-26 13:26:25 +00:00
Stefan Eissing
3567f9f7c6 new experimental http2 proxy module for h2: and h2c: proxy urls
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1729209 13f79535-47bb-0310-9956-ffa450edef68
2016-02-08 16:53:45 +00:00
Stefan Eissing
45e1dee27b correctly processing multiple rel values in Link headers, suppressing PUSH if nopush param is present in link header
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1727545 13f79535-47bb-0310-9956-ffa450edef68
2016-01-29 11:40:19 +00:00
Stefan Eissing
11e47dd8f0 checking for stopping MPM before going into blocking keepalive read
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1725543 13f79535-47bb-0310-9956-ffa450edef68
2016-01-19 15:24:41 +00:00
Rainer Jung
af14d158a3 Added many log numbers to log statements that
had none.

Those were not detected by the coccinelle script.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1725485 13f79535-47bb-0310-9956-ffa450edef68
2016-01-19 12:02:41 +00:00
Rainer Jung
38c527a6cd Silence compiler warning:
format '%ld' expects argument of type 'long int',
but argument 10 has type 'apr_uint64_t'


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1725473 13f79535-47bb-0310-9956-ffa450edef68
2016-01-19 11:31:54 +00:00
Rainer Jung
44ce30494e Added many log numbers to log statements that
had none.

Handled all files in modules/.

I used the coccinelle script provided by Stefan.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1725392 13f79535-47bb-0310-9956-ffa450edef68
2016-01-19 00:03:18 +00:00
Stefan Eissing
036c8322fa better formatting of apr_utin64_t log output
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1725288 13f79535-47bb-0310-9956-ffa450edef68
2016-01-18 15:24:10 +00:00
Stefan Eissing
32ebc57fd1 log2n compilation error fix, cache digest calculation fix
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1725262 13f79535-47bb-0310-9956-ffa450edef68
2016-01-18 13:10:27 +00:00
Stefan Eissing
17282190d0 mod_http2: push diary to avoid duplicate pushes, cache-digest handling, http2-status handler for stats about current http2 connection
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1724820 13f79535-47bb-0310-9956-ffa450edef68
2016-01-15 14:27:59 +00:00
Stefan Eissing
d3d3c379b7 push diary work, introduction of N/P for cache digest handling
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1724206 13f79535-47bb-0310-9956-ffa450edef68
2016-01-12 11:20:54 +00:00
Stefan Eissing
cb8084064d new directive H2PushDiarySize, first simple apr_hash implementation of a push diary that prevents duplicate pushes on a connection
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1724086 13f79535-47bb-0310-9956-ffa450edef68
2016-01-11 17:12:24 +00:00
Stefan Eissing
93c609224e fixed segfault in connection shutdown, added accept-push-policy support
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1721547 13f79535-47bb-0310-9956-ffa450edef68
2015-12-23 14:50:54 +00:00
Stefan Eissing
483c9dd060 byte savings by using bit fields, new env vars HTTP2 and H2PUSH, set to on when enabled on request
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1721121 13f79535-47bb-0310-9956-ffa450edef68
2015-12-21 10:54:38 +00:00
Stefan Eissing
ef14549031 new directive H2PushPriority to define content-type based priorities on server pushed resources
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1716388 13f79535-47bb-0310-9956-ffa450edef68
2015-11-25 13:26:31 +00:00
Stefan Eissing
07517e5da6 priorities for pushed streams are changed if nghttp2 library supports this, configurations for type based priority specs TBD
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1716197 13f79535-47bb-0310-9956-ffa450edef68
2015-11-24 16:22:50 +00:00
Stefan Eissing
98a612bb81 start of PUSH priority handling, fixing core when task produces no response at all
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1716146 13f79535-47bb-0310-9956-ffa450edef68
2015-11-24 14:21:26 +00:00
Stefan Eissing
b29a584827 sending trailers out, when seeing EOR bucket and r->trailers_out is non-empty
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1715919 13f79535-47bb-0310-9956-ffa450edef68
2015-11-23 19:08:19 +00:00
Stefan Eissing
364b3f79c4 new directive H2Push on/off to en-/disable HTTP/2 server pushes. Server pushes are recognized by Link: headers in responses that carry the rel=preload parameter
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1714219 13f79535-47bb-0310-9956-ffa450edef68
2015-11-13 14:54:15 +00:00
Stefan Eissing
62e2350bcb some rework for server push
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1713887 13f79535-47bb-0310-9956-ffa450edef68
2015-11-11 16:40:18 +00:00