Le samedi 28 février 2026, 16:36:27 heure normale d’Europe centrale Adam D. Barratt a écrit : Hi adam, > Control: tags -1 + confirmed > > On Fri, 2026-01-23 at 19:11 +0100, Bastien Roucaries wrote: > > - regression due to http2 > > Please go ahead.
I just propose to use this debdiff instead. Tg tested and it is ok not segfault for a week > > Regards, > > Adam >
diff -Nru apache2-2.4.66/debian/changelog apache2-2.4.66/debian/changelog --- apache2-2.4.66/debian/changelog 2025-12-05 18:52:34.000000000 +0000 +++ apache2-2.4.66/debian/changelog 2026-03-01 13:26:45.000000000 +0000 @@ -1,3 +1,12 @@ +apache2 (2.4.66-1~deb13u2) trixie; urgency=medium + + * Team upload + * Fix a regression on http2 + (Closes: #1125713, #1125368, #1126177, #1128831) + * Split testsuite avoiding timeout (Closes: #1126571) + + -- Bastien Roucariès <[email protected]> Sun, 01 Mar 2026 14:26:45 +0100 + apache2 (2.4.66-1~deb13u1) trixie; urgency=medium * Team upload diff -Nru apache2-2.4.66/debian/patches/0009-From-upstream-module.patch apache2-2.4.66/debian/patches/0009-From-upstream-module.patch --- apache2-2.4.66/debian/patches/0009-From-upstream-module.patch 1970-01-01 00:00:00.000000000 +0000 +++ apache2-2.4.66/debian/patches/0009-From-upstream-module.patch 2026-03-01 13:26:45.000000000 +0000 @@ -0,0 +1,229 @@ +From: =?utf-8?q?Bastien_Roucari=C3=A8s?= <[email protected]> +Date: Tue, 27 Jan 2026 23:54:33 +0100 +Subject: From upstream module + +http2 module was mismerged and some segfault still occurs. Fix mismerge by importing current +HEAD + +origin: backport, https://github.com/icing/mod_h2/commit/b282ffb05cfdfb53c3fdcfb4a66cb79608a46c85 +forwarded: not-needed +bug: https://github.com/icing/mod_h2/issues/313 +debian-bug: http://bugs.debian.org/1126177 +--- + modules/http2/h2_c1.c | 5 ++++- + modules/http2/h2_c2_filter.c | 4 ++-- + modules/http2/h2_mplx.c | 8 +++++--- + modules/http2/h2_proxy_session.c | 4 ++-- + modules/http2/h2_proxy_util.c | 6 +++--- + modules/http2/h2_session.c | 4 ++-- + modules/http2/h2_util.h | 2 +- + modules/http2/h2_version.h | 2 +- + modules/http2/h2_workers.c | 5 +++++ + modules/http2/h2_ws.c | 2 +- + modules/http2/h2_ws.h | 2 +- + 11 files changed, 27 insertions(+), 17 deletions(-) + +diff --git a/modules/http2/h2_c1.c b/modules/http2/h2_c1.c +index 626e665..f4604a4 100644 +--- a/modules/http2/h2_c1.c ++++ b/modules/http2/h2_c1.c +@@ -47,7 +47,10 @@ + + static struct h2_workers *workers; + +-static int async_mpm, mpm_can_waitio; ++static int async_mpm; ++#ifdef AP_MPMQ_CAN_WAITIO ++static int mpm_can_waitio; ++#endif + + APR_OPTIONAL_FN_TYPE(ap_logio_add_bytes_in) *h2_c_logio_add_bytes_in; + APR_OPTIONAL_FN_TYPE(ap_logio_add_bytes_out) *h2_c_logio_add_bytes_out; +diff --git a/modules/http2/h2_c2_filter.c b/modules/http2/h2_c2_filter.c +index 554f88b..523a941 100644 +--- a/modules/http2/h2_c2_filter.c ++++ b/modules/http2/h2_c2_filter.c +@@ -204,7 +204,7 @@ static int uniq_field_values(void *d, const char *key, const char *val) + */ + for (i = 0, strpp = (char **) values->elts; i < values->nelts; + ++i, ++strpp) { +- if (*strpp && apr_strnatcasecmp(*strpp, start) == 0) { ++ if (*strpp && ap_cstr_casecmp(*strpp, start) == 0) { + break; + } + } +@@ -312,7 +312,7 @@ static h2_headers *create_response(request_rec *r) + + while (field && (token = ap_get_list_item(r->pool, &field)) != NULL) { + for (i = 0; i < r->content_languages->nelts; ++i) { +- if (!apr_strnatcasecmp(token, languages[i])) ++ if (!ap_cstr_casecmp(token, languages[i])) + break; + } + if (i == r->content_languages->nelts) { +diff --git a/modules/http2/h2_mplx.c b/modules/http2/h2_mplx.c +index 75518f4..8053f60 100644 +--- a/modules/http2/h2_mplx.c ++++ b/modules/http2/h2_mplx.c +@@ -398,10 +398,11 @@ apr_status_t h2_mplx_c1_streams_do(h2_mplx *m, h2_mplx_stream_cb *cb, void *ctx) + { + stream_iter_ctx_t x; + +- H2_MPLX_ENTER(m); +- + x.cb = cb; + x.ctx = ctx; ++ ++ H2_MPLX_ENTER(m); ++ + h2_ihash_iter(m->streams, m_stream_iter_wrap, &x); + + H2_MPLX_LEAVE(m); +@@ -1033,7 +1034,8 @@ static void s_c2_done(h2_mplx *m, conn_rec *c2, h2_conn_ctx_t *conn_ctx) + int i; + + for (i = 0; i < m->spurge->nelts; ++i) { +- if (stream == APR_ARRAY_IDX(m->spurge, i, h2_stream*)) { ++ stream = APR_ARRAY_IDX(m->spurge, i, h2_stream*); ++ if (stream && (stream->id == conn_ctx->stream_id)) { + ap_log_cerror(APLOG_MARK, APLOG_WARNING, 0, c2, + H2_STRM_LOG(APLOGNO(03517), stream, "already in spurge")); + ap_assert("stream should not be in spurge" == NULL); +diff --git a/modules/http2/h2_proxy_session.c b/modules/http2/h2_proxy_session.c +index acb17a5..3561c24 100644 +--- a/modules/http2/h2_proxy_session.c ++++ b/modules/http2/h2_proxy_session.c +@@ -866,8 +866,8 @@ static apr_status_t open_stream(h2_proxy_session *session, const char *url, + * Host: header */ + authority = r->server->server_hostname; + ap_log_rerror(APLOG_MARK, APLOG_WARNING, 0, r, APLOGNO(10511) +- "HTTP/0.9 request (with no host line) " +- "on incoming request and preserve host set " ++ "incoming HTTP/0.9 request (with no Host header) " ++ "and preserve host set, " + "forcing hostname to be %s for uri %s", + authority, r->uri); + apr_table_setn(r->headers_in, "Host", authority); +diff --git a/modules/http2/h2_proxy_util.c b/modules/http2/h2_proxy_util.c +index bb384b9..c0b3948 100644 +--- a/modules/http2/h2_proxy_util.c ++++ b/modules/http2/h2_proxy_util.c +@@ -381,7 +381,7 @@ static int iq_bubble_down(h2_proxy_iqueue *q, int i, int bottom, + * h2_proxy_ngheader + ******************************************************************************/ + #define H2_HD_MATCH_LIT_CS(l, name) \ +- ((strlen(name) == sizeof(l) - 1) && !apr_strnatcasecmp(l, name)) ++ ((strlen(name) == sizeof(l) - 1) && !ap_cstr_casecmp(l, name)) + + static int h2_util_ignore_header(const char *name) + { +@@ -500,7 +500,7 @@ static int ignore_header(const literal *lits, size_t llen, + + for (i = 0; i < llen; ++i) { + lit = &lits[i]; +- if (lit->len == nlen && !apr_strnatcasecmp(lit->name, name)) { ++ if (lit->len == nlen && !ap_cstr_casecmp(lit->name, name)) { + return 1; + } + } +@@ -542,7 +542,7 @@ void h2_proxy_util_camel_case_header(char *s, size_t len) + + /** Match a header value against a string constance, case insensitive */ + #define H2_HD_MATCH_LIT(l, name, nlen) \ +- ((nlen == sizeof(l) - 1) && !apr_strnatcasecmp(l, name)) ++ ((nlen == sizeof(l) - 1) && !ap_cstr_casecmp(l, name)) + + static apr_status_t h2_headers_add_h1(apr_table_t *headers, apr_pool_t *pool, + const char *name, size_t nlen, +diff --git a/modules/http2/h2_session.c b/modules/http2/h2_session.c +index 21ede5c..2f92150 100644 +--- a/modules/http2/h2_session.c ++++ b/modules/http2/h2_session.c +@@ -125,7 +125,7 @@ static h2_stream *h2_session_open_stream(h2_session *session, int stream_id, + apr_allocator_t *allocator; + apr_pool_t *stream_pool; + apr_status_t rv; +- ++ + rv = apr_allocator_create(&allocator); + if (rv != APR_SUCCESS) + return NULL; +@@ -135,7 +135,7 @@ static h2_stream *h2_session_open_stream(h2_session *session, int stream_id, + apr_allocator_owner_set(allocator, stream_pool); + apr_pool_abort_set(abort_on_oom, stream_pool); + apr_pool_tag(stream_pool, "h2_stream"); +- ++ + stream = h2_stream_create(stream_id, stream_pool, session, + session->monitor, initiated_on); + if (stream) { +diff --git a/modules/http2/h2_util.h b/modules/http2/h2_util.h +index 29d1799..e813bf5 100644 +--- a/modules/http2/h2_util.h ++++ b/modules/http2/h2_util.h +@@ -337,7 +337,7 @@ apr_size_t h2_util_table_bytes(apr_table_t *t, apr_size_t pair_extra); + + /** Match a header value against a string constance, case insensitive */ + #define H2_HD_MATCH_LIT(l, name, nlen) \ +- ((nlen == sizeof(l) - 1) && !apr_strnatcasecmp(l, name)) ++ ((nlen == sizeof(l) - 1) && !ap_cstr_casecmp(l, name)) + + /******************************************************************************* + * HTTP/2 header helpers +diff --git a/modules/http2/h2_version.h b/modules/http2/h2_version.h +index 8bcaf69..5c95a7d 100644 +--- a/modules/http2/h2_version.h ++++ b/modules/http2/h2_version.h +@@ -27,7 +27,7 @@ + * @macro + * Version number of the http2 module as c string + */ +-#define MOD_HTTP2_VERSION "2.0.37" ++#define MOD_HTTP2_VERSION "2.0.37-git" + + /** + * @macro +diff --git a/modules/http2/h2_workers.c b/modules/http2/h2_workers.c +index e7e2039..192dbc0 100644 +--- a/modules/http2/h2_workers.c ++++ b/modules/http2/h2_workers.c +@@ -131,8 +131,13 @@ static apr_status_t activate_slot(h2_workers *workers) + apr_pool_tag(pool, "h2_worker_slot"); + slot->pool = pool; + ++#if defined(AP_HAS_THREAD_LOCAL) + rv = ap_thread_create(&slot->thread, workers->thread_attr, + slot_run, slot, slot->pool); ++#else ++ rv = apr_thread_create(&slot->thread, workers->thread_attr, ++ slot_run, slot, slot->pool); ++#endif + + cleanup: + if (rv != APR_SUCCESS) { +diff --git a/modules/http2/h2_ws.c b/modules/http2/h2_ws.c +index 3715225..4643660 100644 +--- a/modules/http2/h2_ws.c ++++ b/modules/http2/h2_ws.c +@@ -239,7 +239,7 @@ static void ws_handle_resp(conn_rec *c2, h2_conn_ctx_t *conn_ctx, + * or in the request processings implementation of WebSockets */ + ap_log_cerror(APLOG_MARK, APLOG_ERR, 0, c2, APLOGNO(10463) + "h2_c2(%s-%d): websocket CONNECT, 101 response " +- "with 'Sec-WebSocket-Accept: %s' but expected %s", ++ "without 'Sec-WebSocket-Accept: %s' but expected %s", + conn_ctx->id, conn_ctx->stream_id, hd, + ws_ctx->ws_accept_base64); + } +diff --git a/modules/http2/h2_ws.h b/modules/http2/h2_ws.h +index a94d300..4e8967c 100644 +--- a/modules/http2/h2_ws.h ++++ b/modules/http2/h2_ws.h +@@ -23,7 +23,7 @@ + * Rewrite a websocket request. + * + * @param req the h2 request to rewrite +- * @param c2 the connection to process the request on ++ * @param conn the connection to process the request on + * @param no_body != 0 iff the request is known to have no body + * @return the websocket request for internal submit + */ diff -Nru apache2-2.4.66/debian/patches/bug1125368.patch apache2-2.4.66/debian/patches/bug1125368.patch --- apache2-2.4.66/debian/patches/bug1125368.patch 1970-01-01 00:00:00.000000000 +0000 +++ apache2-2.4.66/debian/patches/bug1125368.patch 2026-03-01 13:26:45.000000000 +0000 @@ -0,0 +1,102 @@ +From: Stefan Eissing <[email protected]> +Date: Thu, 11 Dec 2025 08:45:15 +0000 +Subject: *) mod_http2: update to version 2.0.37 Prevent double purge of a + stream, resulting in a double free. Fixes PR 69899. + +git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1930444 13f79535-47bb-0310-9956-ffa450edef68 + +origin: https://github.com/apache/httpd/commit/542e0da07048d3934ef18c22b44cf8d62e64067f +bug-debian: https://bugs.debian.org/1125368 +bug: https://bz.apache.org/bugzilla/show_bug.cgi?id=69899 +--- + changes-entries/h2_v2.0.37.txt | 4 ++++ + modules/http2/h2_mplx.c | 23 ++++++++++++++++++----- + modules/http2/h2_version.h | 4 ++-- + 3 files changed, 24 insertions(+), 7 deletions(-) + create mode 100644 changes-entries/h2_v2.0.37.txt + +diff --git a/changes-entries/h2_v2.0.37.txt b/changes-entries/h2_v2.0.37.txt +new file mode 100644 +index 0000000..8f22cde +--- /dev/null ++++ b/changes-entries/h2_v2.0.37.txt +@@ -0,0 +1,4 @@ ++ *) mod_http2: update to version 2.0.37 ++ Prevent double purge of a stream, resulting in a double free. ++ Fixes PR 69899. ++ [Stefan Eissing] +diff --git a/modules/http2/h2_mplx.c b/modules/http2/h2_mplx.c +index f9616ab..75518f4 100644 +--- a/modules/http2/h2_mplx.c ++++ b/modules/http2/h2_mplx.c +@@ -126,12 +126,24 @@ int h2_mplx_c1_stream_is_running(h2_mplx *m, h2_stream *stream) + return rv; + } + ++static int add_for_purge(h2_mplx *m, h2_stream *stream) ++{ ++ int i; ++ for (i = 0; i < m->spurge->nelts; ++i) { ++ h2_stream *s = APR_ARRAY_IDX(m->spurge, i, h2_stream*); ++ if (s == stream) /* already scheduled for purging */ ++ return FALSE; ++ } ++ APR_ARRAY_PUSH(m->spurge, h2_stream *) = stream; ++ return TRUE; ++} ++ + static void c1c2_stream_joined(h2_mplx *m, h2_stream *stream) + { + ap_assert(!stream_is_running(stream)); + + h2_ihash_remove(m->shold, stream->id); +- APR_ARRAY_PUSH(m->spurge, h2_stream *) = stream; ++ add_for_purge(m, stream); + } + + static void m_stream_cleanup(h2_mplx *m, h2_stream *stream) +@@ -164,7 +176,7 @@ static void m_stream_cleanup(h2_mplx *m, h2_stream *stream) + ap_log_cerror(APLOG_MARK, APLOG_TRACE2, 0, m->c1, + H2_STRM_MSG(stream, "cleanup, c2 is done, move to spurge")); + /* processing has finished */ +- APR_ARRAY_PUSH(m->spurge, h2_stream *) = stream; ++ add_for_purge(m, stream); + } + else { + ap_log_cerror(APLOG_MARK, APLOG_TRACE2, 0, m->c1, +@@ -178,9 +190,10 @@ static void m_stream_cleanup(h2_mplx *m, h2_stream *stream) + } + else { + /* never started */ +- ap_log_cerror(APLOG_MARK, APLOG_TRACE2, 0, m->c1, +- H2_STRM_MSG(stream, "cleanup, never started, move to spurge")); +- APR_ARRAY_PUSH(m->spurge, h2_stream *) = stream; ++ int added = add_for_purge(m, stream); ++ if (added) ++ ap_log_cerror(APLOG_MARK, APLOG_TRACE2, 0, m->c1, ++ H2_STRM_MSG(stream, "cleanup, never started, move to spurge")); + } + } + +diff --git a/modules/http2/h2_version.h b/modules/http2/h2_version.h +index 8d38c34..8bcaf69 100644 +--- a/modules/http2/h2_version.h ++++ b/modules/http2/h2_version.h +@@ -27,7 +27,7 @@ + * @macro + * Version number of the http2 module as c string + */ +-#define MOD_HTTP2_VERSION "2.0.35" ++#define MOD_HTTP2_VERSION "2.0.37" + + /** + * @macro +@@ -35,7 +35,7 @@ + * release. This is a 24 bit number with 8 bits for major number, 8 bits + * for minor and 8 bits for patch. Version 1.2.3 becomes 0x010203. + */ +-#define MOD_HTTP2_VERSION_NUM 0x020023 ++#define MOD_HTTP2_VERSION_NUM 0x020025 + + + #endif /* mod_h2_h2_version_h */ diff -Nru apache2-2.4.66/debian/patches/old-memory-handling-http2.patch apache2-2.4.66/debian/patches/old-memory-handling-http2.patch --- apache2-2.4.66/debian/patches/old-memory-handling-http2.patch 1970-01-01 00:00:00.000000000 +0000 +++ apache2-2.4.66/debian/patches/old-memory-handling-http2.patch 2026-03-01 13:26:45.000000000 +0000 @@ -0,0 +1,44 @@ +From: Thorsten Glaser <[email protected]> +Date: Sun, 1 Mar 2026 18:04:39 +0100 +Subject: Fix http2 segfault + +origin: from https://github.com/icing/mod_h2/issues/313#issuecomment-3834622658 +--- + modules/http2/h2_session.c | 18 +----------------- + 1 file changed, 1 insertion(+), 17 deletions(-) + +diff --git a/modules/http2/h2_session.c b/modules/http2/h2_session.c +index 2f92150..dda6c77 100644 +--- a/modules/http2/h2_session.c ++++ b/modules/http2/h2_session.c +@@ -111,29 +111,13 @@ static void cleanup_unprocessed_streams(h2_session *session) + h2_mplx_c1_streams_do(session->mplx, rst_unprocessed_stream, session); + } + +-/* APR callback invoked if allocation fails. */ +-static int abort_on_oom(int retcode) +-{ +- ap_abort_on_oom(); +- return retcode; /* unreachable, hopefully. */ +-} +- + static h2_stream *h2_session_open_stream(h2_session *session, int stream_id, + int initiated_on) + { + h2_stream * stream; +- apr_allocator_t *allocator; + apr_pool_t *stream_pool; +- apr_status_t rv; +- +- rv = apr_allocator_create(&allocator); +- if (rv != APR_SUCCESS) +- return NULL; + +- apr_allocator_max_free_set(allocator, ap_max_mem_free); +- apr_pool_create_ex(&stream_pool, session->pool, NULL, allocator); +- apr_allocator_owner_set(allocator, stream_pool); +- apr_pool_abort_set(abort_on_oom, stream_pool); ++ apr_pool_create(&stream_pool, session->pool); + apr_pool_tag(stream_pool, "h2_stream"); + + stream = h2_stream_create(stream_id, stream_pool, session, diff -Nru apache2-2.4.66/debian/patches/series apache2-2.4.66/debian/patches/series --- apache2-2.4.66/debian/patches/series 2025-12-05 18:52:34.000000000 +0000 +++ apache2-2.4.66/debian/patches/series 2026-03-01 13:26:45.000000000 +0000 @@ -5,4 +5,6 @@ build_suexec-custom.patch reproducible_builds.diff fix-macro.patch -#0017-When-a-rewrite-to-proxy-is-configured-in-the-server-.patch +bug1125368.patch +0009-From-upstream-module.patch +old-memory-handling-http2.patch diff -Nru apache2-2.4.66/debian/salsa-ci.yml apache2-2.4.66/debian/salsa-ci.yml --- apache2-2.4.66/debian/salsa-ci.yml 2025-12-05 10:21:29.000000000 +0000 +++ apache2-2.4.66/debian/salsa-ci.yml 2026-03-01 13:26:45.000000000 +0000 @@ -2,3 +2,5 @@ include: - https://salsa.debian.org/salsa-ci-team/pipeline/raw/master/salsa-ci.yml - https://salsa.debian.org/salsa-ci-team/pipeline/raw/master/pipeline-jobs.yml +variables: + RELEASE: 'trixie' diff -Nru apache2-2.4.66/debian/tests/control apache2-2.4.66/debian/tests/control --- apache2-2.4.66/debian/tests/control 2025-12-05 18:52:34.000000000 +0000 +++ apache2-2.4.66/debian/tests/control 2026-03-01 13:26:45.000000000 +0000 @@ -1,4 +1,44 @@ -Tests: run-test-suite +Tests: run-test-suite_prefork +Features: no-build-needed +Restrictions: allow-stderr isolation-container breaks-testbed needs-root +Depends: apache2, + apache2-dev, + build-essential, + libanyevent-perl, + libanyevent-websocket-client-perl, + libcrypt-ssleay-perl, + libdatetime-perl, + libfcgi-perl, + libhtml-parser-perl, + libhttp-dav-perl, + libnet-ssleay-perl, + libpcre2-dev, + libprotocol-http2-perl, + libtime-hires-perl, + libwww-perl, + perl-doc + +Tests: run-test-suite_worker +Features: no-build-needed +Restrictions: allow-stderr isolation-container breaks-testbed needs-root +Depends: apache2, + apache2-dev, + build-essential, + libanyevent-perl, + libanyevent-websocket-client-perl, + libcrypt-ssleay-perl, + libdatetime-perl, + libfcgi-perl, + libhtml-parser-perl, + libhttp-dav-perl, + libnet-ssleay-perl, + libpcre2-dev, + libprotocol-http2-perl, + libtime-hires-perl, + libwww-perl, + perl-doc + +Tests: run-test-suite_event Features: no-build-needed Restrictions: allow-stderr isolation-container breaks-testbed needs-root Depends: apache2, diff -Nru apache2-2.4.66/debian/tests/run-test-suite apache2-2.4.66/debian/tests/run-test-suite --- apache2-2.4.66/debian/tests/run-test-suite 2025-12-05 18:52:13.000000000 +0000 +++ apache2-2.4.66/debian/tests/run-test-suite 1970-01-01 00:00:00.000000000 +0000 @@ -1,66 +0,0 @@ -#!/bin/bash - -. /etc/apache2/envvars -set -xeu -set -o pipefail -export LANG=C -export PATH=/usr/lib/ccache:$PATH -# set to "-v t/modules/ext_filter.t ..." to run only a few test, but verbose -TESTS="" -TESTUSER=tuser - -# The test framework assumes localhost resolves exclusively to 127.0.0.1 -# (and not to ::1). So remove 'localhost' from the ::1 entry. -perl -p -i -e ' if (/^\s*::1\s+/) { s/\s+localhost\s+/ /g }' /etc/hosts - -useradd --user-group --system --create-home -s /bin/bash $TESTUSER -cp -a debian/perl-framework $AUTOPKGTEST_TMP -cd $AUTOPKGTEST_TMP/perl-framework - -export HARNESS_VERBOSE=1 - -run_tests () { - local MPM=$1 - shift - local LOG=testlog.$MPM - - echo =============Running-with-${MPM}========== - rm -f apache2.conf.debian - cp /etc/apache2/apache2.conf apache2.conf.debian - cat /etc/apache2/mods-available/$MPM.load >> apache2.conf.debian - ls /etc/apache2/mods-available/*.load | grep -v mpm_ | xargs cat >> apache2.conf.debian - # these are only for tests and don't have a .load file - for m in bucketeer case_filter case_filter_in ; do - echo "LoadModule ${m}_module /usr/lib/apache2/modules/mod_${m}.so" >> apache2.conf.debian - done - # need TypesConfig from mime.conf for t/modules/filter.t - cat /etc/apache2/mods-available/mime.conf >> apache2.conf.debian - echo "Servername localhost" >> apache2.conf.debian - make clean || true - perl -p -i -e 's,^Include,#Include,' apache2.conf.debian - chown -R $TESTUSER: $AUTOPKGTEST_TMP - su $TESTUSER -c "perl Makefile.PL -apxs /usr/bin/apxs2 -httpd_conf $PWD/apache2.conf.debian" \ - || return 1 - su $TESTUSER -c "t/TEST $TESTS" | tee $LOG - if ! grep -E "^Files=[0-9]+, Tests=[0-9]+" $LOG ; then - echo "Message about Files/Tests not found in $LOG" >&2 - return 1 - fi - if ! grep -E "^Result: PASS" $LOG ; then - echo "PASS message not found in $LOG" >&2 - return 1 - fi - if grep -E "^Result: FAIL" $LOG ; then >&2 - echo "Test suite failed" - return 1 - fi - if grep -E "server dumped core" $LOG ; then >&2 - echo "segfault detected" - return 1 - fi - return 0 -} - -run_tests mpm_prefork -run_tests mpm_worker -run_tests mpm_event diff -Nru apache2-2.4.66/debian/tests/run-test-suite.sh apache2-2.4.66/debian/tests/run-test-suite.sh --- apache2-2.4.66/debian/tests/run-test-suite.sh 1970-01-01 00:00:00.000000000 +0000 +++ apache2-2.4.66/debian/tests/run-test-suite.sh 2026-03-01 13:26:45.000000000 +0000 @@ -0,0 +1,45 @@ +#!/bin/bash + +. /etc/apache2/envvars + +run_tests () { + local MPM=$1 + shift + local LOG=testlog.$MPM + + echo =============Running-with-${MPM}========== + rm -f apache2.conf.debian + cp /etc/apache2/apache2.conf apache2.conf.debian + cat /etc/apache2/mods-available/$MPM.load >> apache2.conf.debian + ls /etc/apache2/mods-available/*.load | grep -v mpm_ | xargs cat >> apache2.conf.debian + # these are only for tests and don't have a .load file + for m in bucketeer case_filter case_filter_in ; do + echo "LoadModule ${m}_module /usr/lib/apache2/modules/mod_${m}.so" >> apache2.conf.debian + done + # need TypesConfig from mime.conf for t/modules/filter.t + cat /etc/apache2/mods-available/mime.conf >> apache2.conf.debian + echo "Servername localhost" >> apache2.conf.debian + make clean || true + perl -p -i -e 's,^Include,#Include,' apache2.conf.debian + chown -R $TESTUSER: $AUTOPKGTEST_TMP + su $TESTUSER -c "perl Makefile.PL -apxs /usr/bin/apxs2 -httpd_conf $PWD/apache2.conf.debian" \ + || return 1 + su $TESTUSER -c "t/TEST $TESTS" | tee $LOG + if ! grep -E "^Files=[0-9]+, Tests=[0-9]+" $LOG ; then + echo "Message about Files/Tests not found in $LOG" >&2 + return 1 + fi + if ! grep -E "^Result: PASS" $LOG ; then + echo "PASS message not found in $LOG" >&2 + return 1 + fi + if grep -E "^Result: FAIL" $LOG ; then >&2 + echo "Test suite failed" + return 1 + fi + if grep -E "server dumped core" $LOG ; then >&2 + echo "segfault detected" + return 1 + fi + return 0 +} diff -Nru apache2-2.4.66/debian/tests/run-test-suite_event apache2-2.4.66/debian/tests/run-test-suite_event --- apache2-2.4.66/debian/tests/run-test-suite_event 1970-01-01 00:00:00.000000000 +0000 +++ apache2-2.4.66/debian/tests/run-test-suite_event 2026-03-01 13:26:45.000000000 +0000 @@ -0,0 +1,24 @@ +#!/bin/bash + +. debian/tests/run-test-suite.sh + +set -xeu +set -o pipefail +export LANG=C +export PATH=/usr/lib/ccache:$PATH +# set to "-v t/modules/ext_filter.t ..." to run only a few test, but verbose +TESTS="" +TESTUSER=tuserevent + + +# The test framework assumes localhost resolves exclusively to 127.0.0.1 +# (and not to ::1). So remove 'localhost' from the ::1 entry. +perl -p -i -e ' if (/^\s*::1\s+/) { s/\s+localhost\s+/ /g }' /etc/hosts + +useradd --user-group --system --create-home -s /bin/bash $TESTUSER +cp -a debian/perl-framework $AUTOPKGTEST_TMP +cd $AUTOPKGTEST_TMP/perl-framework + +export HARNESS_VERBOSE=1 + +run_tests mpm_event diff -Nru apache2-2.4.66/debian/tests/run-test-suite_prefork apache2-2.4.66/debian/tests/run-test-suite_prefork --- apache2-2.4.66/debian/tests/run-test-suite_prefork 1970-01-01 00:00:00.000000000 +0000 +++ apache2-2.4.66/debian/tests/run-test-suite_prefork 2026-03-01 13:26:45.000000000 +0000 @@ -0,0 +1,24 @@ +#!/bin/bash + +. debian/tests/run-test-suite.sh + +set -xeu +set -o pipefail +export LANG=C +export PATH=/usr/lib/ccache:$PATH +# set to "-v t/modules/ext_filter.t ..." to run only a few test, but verbose +TESTS="" +TESTUSER=tuserprefork + + +# The test framework assumes localhost resolves exclusively to 127.0.0.1 +# (and not to ::1). So remove 'localhost' from the ::1 entry. +perl -p -i -e ' if (/^\s*::1\s+/) { s/\s+localhost\s+/ /g }' /etc/hosts + +useradd --user-group --system --create-home -s /bin/bash $TESTUSER +cp -a debian/perl-framework $AUTOPKGTEST_TMP +cd $AUTOPKGTEST_TMP/perl-framework + +export HARNESS_VERBOSE=1 + +run_tests mpm_prefork diff -Nru apache2-2.4.66/debian/tests/run-test-suite_worker apache2-2.4.66/debian/tests/run-test-suite_worker --- apache2-2.4.66/debian/tests/run-test-suite_worker 1970-01-01 00:00:00.000000000 +0000 +++ apache2-2.4.66/debian/tests/run-test-suite_worker 2026-03-01 13:26:45.000000000 +0000 @@ -0,0 +1,24 @@ +#!/bin/bash + +. debian/tests/run-test-suite.sh + +set -xeu +set -o pipefail +export LANG=C +export PATH=/usr/lib/ccache:$PATH +# set to "-v t/modules/ext_filter.t ..." to run only a few test, but verbose +TESTS="" +TESTUSER=tuserworker + + +# The test framework assumes localhost resolves exclusively to 127.0.0.1 +# (and not to ::1). So remove 'localhost' from the ::1 entry. +perl -p -i -e ' if (/^\s*::1\s+/) { s/\s+localhost\s+/ /g }' /etc/hosts + +useradd --user-group --system --create-home -s /bin/bash $TESTUSER +cp -a debian/perl-framework $AUTOPKGTEST_TMP +cd $AUTOPKGTEST_TMP/perl-framework + +export HARNESS_VERBOSE=1 + +run_tests mpm_worker
signature.asc
Description: This is a digitally signed message part.

