import UBI mod_http2-1.15.19-5.el9_3.1
This commit is contained in:
parent
974bc9b581
commit
07619d83d8
|
@ -0,0 +1,56 @@
|
||||||
|
From 134e28ae5abc997fe064995627b3ebe247a5d5d8 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Stefan Eissing <stefan@eissing.org>
|
||||||
|
Date: Fri, 23 Feb 2024 15:13:56 +0100
|
||||||
|
Subject: [PATCH] RESET stream after 100 failed incoming headers
|
||||||
|
|
||||||
|
---
|
||||||
|
mod_http2/h2_session.c | 10 +++++++---
|
||||||
|
mod_http2/h2_stream.c | 1 +
|
||||||
|
mod_http2/h2_stream.h | 1 +
|
||||||
|
3 files changed, 9 insertions(+), 3 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/mod_http2/h2_session.c b/mod_http2/h2_session.c
|
||||||
|
index 1915855..d9c077a 100644
|
||||||
|
--- a/mod_http2/h2_session.c
|
||||||
|
+++ b/mod_http2/h2_session.c
|
||||||
|
@@ -311,9 +311,13 @@ static int on_header_cb(nghttp2_session *ngh2, const nghttp2_frame *frame,
|
||||||
|
|
||||||
|
status = h2_stream_add_header(stream, (const char *)name, namelen,
|
||||||
|
(const char *)value, valuelen);
|
||||||
|
- if (status != APR_SUCCESS
|
||||||
|
- && (!stream->rtmp
|
||||||
|
- || stream->rtmp->http_status == H2_HTTP_STATUS_UNSET)) {
|
||||||
|
+ if (status != APR_SUCCESS &&
|
||||||
|
+ (!stream->rtmp ||
|
||||||
|
+ stream->rtmp->http_status == H2_HTTP_STATUS_UNSET ||
|
||||||
|
+ /* We accept a certain amount of failures in order to reply
|
||||||
|
+ * with an informative HTTP error response like 413. But of the
|
||||||
|
+ * client is too wrong, we fail the request an RESET the stream */
|
||||||
|
+ stream->request_headers_failed > 100)) {
|
||||||
|
return NGHTTP2_ERR_TEMPORAL_CALLBACK_FAILURE;
|
||||||
|
}
|
||||||
|
return 0;
|
||||||
|
diff --git a/mod_http2/h2_stream.c b/mod_http2/h2_stream.c
|
||||||
|
index 4fec537..2b2caaf 100644
|
||||||
|
--- a/mod_http2/h2_stream.c
|
||||||
|
+++ b/mod_http2/h2_stream.c
|
||||||
|
@@ -764,6 +764,7 @@ apr_status_t h2_stream_add_header(h2_stream *stream,
|
||||||
|
|
||||||
|
cleanup:
|
||||||
|
if (error) {
|
||||||
|
+ ++stream->request_headers_failed;
|
||||||
|
set_error_response(stream, error);
|
||||||
|
return APR_EINVAL;
|
||||||
|
}
|
||||||
|
diff --git a/mod_http2/h2_stream.h b/mod_http2/h2_stream.h
|
||||||
|
index 08f7888..baf8b50 100644
|
||||||
|
--- a/mod_http2/h2_stream.h
|
||||||
|
+++ b/mod_http2/h2_stream.h
|
||||||
|
@@ -75,6 +75,7 @@ struct h2_stream {
|
||||||
|
struct h2_request *rtmp; /* request being assembled */
|
||||||
|
apr_table_t *trailers; /* optional incoming trailers */
|
||||||
|
int request_headers_added; /* number of request headers added */
|
||||||
|
+ int request_headers_failed; /* number of request headers failed to add */
|
||||||
|
|
||||||
|
struct h2_bucket_beam *input;
|
||||||
|
apr_bucket_brigade *in_buffer;
|
|
@ -3,7 +3,7 @@
|
||||||
|
|
||||||
Name: mod_http2
|
Name: mod_http2
|
||||||
Version: 1.15.19
|
Version: 1.15.19
|
||||||
Release: 5%{?dist}
|
Release: 5%{?dist}.1
|
||||||
Summary: module implementing HTTP/2 for Apache 2
|
Summary: module implementing HTTP/2 for Apache 2
|
||||||
License: ASL 2.0
|
License: ASL 2.0
|
||||||
URL: https://icing.github.io/mod_h2/
|
URL: https://icing.github.io/mod_h2/
|
||||||
|
@ -16,6 +16,8 @@ Patch2: mod_http2-1.15.14-openssl30.patch
|
||||||
Patch100: mod_http2-1.15.19-CVE-2021-44224.patch
|
Patch100: mod_http2-1.15.19-CVE-2021-44224.patch
|
||||||
# https://bugzilla.redhat.com/show_bug.cgi?id=2176209
|
# https://bugzilla.redhat.com/show_bug.cgi?id=2176209
|
||||||
Patch101: mod_http2-1.15.19-CVE-2023-25690.patch
|
Patch101: mod_http2-1.15.19-CVE-2023-25690.patch
|
||||||
|
# https://bugzilla.redhat.com/show_bug.cgi?id=2268277
|
||||||
|
Patch102: mod_http2-1.15.19-CVE-2024-27316.patch
|
||||||
|
|
||||||
BuildRequires: make
|
BuildRequires: make
|
||||||
BuildRequires: gcc
|
BuildRequires: gcc
|
||||||
|
@ -36,6 +38,7 @@ top of libnghttp2 for httpd 2.4 servers.
|
||||||
|
|
||||||
%patch100 -p1 -b .CVE-2021-44224
|
%patch100 -p1 -b .CVE-2021-44224
|
||||||
%patch101 -p1 -b .CVE-2023-25690
|
%patch101 -p1 -b .CVE-2023-25690
|
||||||
|
%patch102 -p1 -b .CVE-2024-27316
|
||||||
|
|
||||||
%build
|
%build
|
||||||
autoreconf -i
|
autoreconf -i
|
||||||
|
@ -60,6 +63,10 @@ echo "LoadModule proxy_http2_module modules/mod_proxy_http2.so" > %{buildroot}%{
|
||||||
%{_httpd_moddir}/mod_proxy_http2.so
|
%{_httpd_moddir}/mod_proxy_http2.so
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Fri Apr 05 2024 Luboš Uhliarik <luhliari@redhat.com> - 1.15.19-5.1
|
||||||
|
- Resolves: RHEL-29826 - mod_http2: httpd: CONTINUATION frames
|
||||||
|
DoS (CVE-2024-27316)
|
||||||
|
|
||||||
* Wed Aug 16 2023 Luboš Uhliarik <luhliari@redhat.com> - 1.15.19-5
|
* Wed Aug 16 2023 Luboš Uhliarik <luhliari@redhat.com> - 1.15.19-5
|
||||||
- Resolves: #2177753 - CVE-2023-25690 httpd: HTTP request splitting with
|
- Resolves: #2177753 - CVE-2023-25690 httpd: HTTP request splitting with
|
||||||
mod_rewrite and mod_proxy
|
mod_rewrite and mod_proxy
|
||||||
|
|
Loading…
Reference in New Issue