Compare commits
34 commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
0c203aeed6 | ||
|
|
0914a96ecc | ||
|
|
f3e631b085 | ||
|
|
fb46d5df49 | ||
|
|
943e0af2d4 | ||
|
|
23f7eb497e | ||
|
|
04d6a20806 | ||
|
|
817134c70c | ||
|
|
4797340d3d | ||
|
|
b4edf40a55 | ||
|
|
47d73dc1b5 | ||
|
|
1f087eb8b1 | ||
|
|
70f6633789 | ||
|
|
cbd0a3cf61 | ||
|
|
243d8d79fb | ||
|
|
d91306617e | ||
|
|
52584b9265 |
||
|
|
6763440aa7 | ||
|
|
4bfb30c1fa | ||
|
|
5bc2bd7773 | ||
|
|
c521675754 | ||
|
|
8f936f8f7b | ||
|
|
093221ab5b | ||
|
|
ff21bd7fac | ||
|
|
867a5dc053 | ||
|
|
a2ee4184f2 | ||
|
|
a58a25a257 | ||
|
|
d4e3bcb534 | ||
|
|
b8ad0c4e43 | ||
|
|
2c933bc9ee | ||
|
|
6900761be4 | ||
|
|
cb9044baa2 | ||
|
|
72c8812120 | ||
|
|
53ecf37db7 |
25 changed files with 433 additions and 3418 deletions
6
.gitignore
vendored
6
.gitignore
vendored
|
|
@ -50,3 +50,9 @@ x86_64
|
|||
/httpd-2.4.57.tar.bz2.asc
|
||||
/httpd-2.4.58.tar.bz2.asc
|
||||
/httpd-2.4.59.tar.bz2.asc
|
||||
/httpd-2.4.61.tar.bz2.asc
|
||||
/httpd-2.4.62.tar.bz2.asc
|
||||
/httpd-2.4.63.tar.bz2.asc
|
||||
/httpd-2.4.64.tar.bz2.asc
|
||||
/httpd-2.4.65.tar.bz2.asc
|
||||
/httpd-2.4.66.tar.bz2.asc
|
||||
|
|
|
|||
|
|
@ -5,6 +5,7 @@
|
|||
]>
|
||||
<!--
|
||||
Copyright 2020 Red Hat, Inc.
|
||||
Copyright 2018 Frank Dana
|
||||
|
||||
Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
contributor license agreements. See the NOTICE file distributed with
|
||||
|
|
@ -70,7 +71,7 @@
|
|||
|
||||
<para>The version of <command>apachectl</command> used on this
|
||||
system is a replacement script intended to be mostly (but not
|
||||
completely) compatible with version provided with
|
||||
completely) compatible with the version provided with
|
||||
<emphasis>Apache httpd</emphasis>. This
|
||||
<command>apachectl</command> mostly acts as a wrapper around
|
||||
<command>systemctl</command> and manipulates the
|
||||
|
|
@ -172,8 +173,8 @@
|
|||
</refsect1>
|
||||
|
||||
<refsect1 id='bugs'>
|
||||
<title>Bugs</title>
|
||||
<para>Please report bugs by filing an issue in Bugzilla via <ulink url='https://bugzilla.redhat.com/'/>.</para>
|
||||
<title>Reporting Bugs</title>
|
||||
<para>Please report bugs by filing an issue in @BUG_REPORT_URL@.</para>
|
||||
</refsect1>
|
||||
|
||||
<refsect1>
|
||||
|
|
|
|||
|
|
@ -106,6 +106,11 @@
|
|||
<filename>/etc/sysconfig/htcacheclean</filename></para>
|
||||
</refsect1>
|
||||
|
||||
<refsect1>
|
||||
<title>Reporting Bugs</title>
|
||||
<para>Please report bugs by filing an issue in @BUG_REPORT_URL@.</para>
|
||||
</refsect1>
|
||||
|
||||
<refsect1>
|
||||
<title>See also</title>
|
||||
|
||||
|
|
|
|||
|
|
@ -1,3 +1,6 @@
|
|||
|
||||
Upstream-Status: local customisation, not needed upstream
|
||||
|
||||
diff --git a/configure.in b/configure.in
|
||||
index f8f9442..f276550 100644
|
||||
--- a/configure.in
|
||||
|
|
|
|||
|
|
@ -1,300 +0,0 @@
|
|||
diff --git a/server/listen.c b/server/listen.c
|
||||
index 5242c2a..e2e028a 100644
|
||||
--- a/server/listen.c
|
||||
+++ b/server/listen.c
|
||||
@@ -34,6 +34,10 @@
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
|
||||
+#ifdef HAVE_SYSTEMD
|
||||
+#include <systemd/sd-daemon.h>
|
||||
+#endif
|
||||
+
|
||||
/* we know core's module_index is 0 */
|
||||
#undef APLOG_MODULE_INDEX
|
||||
#define APLOG_MODULE_INDEX AP_CORE_MODULE_INDEX
|
||||
@@ -59,9 +63,12 @@ static int ap_listenbacklog;
|
||||
static int ap_listencbratio;
|
||||
static int send_buffer_size;
|
||||
static int receive_buffer_size;
|
||||
+#ifdef HAVE_SYSTEMD
|
||||
+static int use_systemd = -1;
|
||||
+#endif
|
||||
|
||||
/* TODO: make_sock is just begging and screaming for APR abstraction */
|
||||
-static apr_status_t make_sock(apr_pool_t *p, ap_listen_rec *server)
|
||||
+static apr_status_t make_sock(apr_pool_t *p, ap_listen_rec *server, int do_bind_listen)
|
||||
{
|
||||
apr_socket_t *s = server->sd;
|
||||
int one = 1;
|
||||
@@ -94,20 +101,6 @@ static apr_status_t make_sock(apr_pool_t *p, ap_listen_rec *server)
|
||||
return stat;
|
||||
}
|
||||
|
||||
-#if APR_HAVE_IPV6
|
||||
- if (server->bind_addr->family == APR_INET6) {
|
||||
- stat = apr_socket_opt_set(s, APR_IPV6_V6ONLY, v6only_setting);
|
||||
- if (stat != APR_SUCCESS && stat != APR_ENOTIMPL) {
|
||||
- ap_log_perror(APLOG_MARK, APLOG_CRIT, stat, p, APLOGNO(00069)
|
||||
- "make_sock: for address %pI, apr_socket_opt_set: "
|
||||
- "(IPV6_V6ONLY)",
|
||||
- server->bind_addr);
|
||||
- apr_socket_close(s);
|
||||
- return stat;
|
||||
- }
|
||||
- }
|
||||
-#endif
|
||||
-
|
||||
/*
|
||||
* To send data over high bandwidth-delay connections at full
|
||||
* speed we must force the TCP window to open wide enough to keep the
|
||||
@@ -169,21 +162,37 @@ static apr_status_t make_sock(apr_pool_t *p, ap_listen_rec *server)
|
||||
}
|
||||
#endif
|
||||
|
||||
- if ((stat = apr_socket_bind(s, server->bind_addr)) != APR_SUCCESS) {
|
||||
- ap_log_perror(APLOG_MARK, APLOG_STARTUP|APLOG_CRIT, stat, p, APLOGNO(00072)
|
||||
- "make_sock: could not bind to address %pI",
|
||||
- server->bind_addr);
|
||||
- apr_socket_close(s);
|
||||
- return stat;
|
||||
- }
|
||||
+ if (do_bind_listen) {
|
||||
+#if APR_HAVE_IPV6
|
||||
+ if (server->bind_addr->family == APR_INET6) {
|
||||
+ stat = apr_socket_opt_set(s, APR_IPV6_V6ONLY, v6only_setting);
|
||||
+ if (stat != APR_SUCCESS && stat != APR_ENOTIMPL) {
|
||||
+ ap_log_perror(APLOG_MARK, APLOG_CRIT, stat, p, APLOGNO(00069)
|
||||
+ "make_sock: for address %pI, apr_socket_opt_set: "
|
||||
+ "(IPV6_V6ONLY)",
|
||||
+ server->bind_addr);
|
||||
+ apr_socket_close(s);
|
||||
+ return stat;
|
||||
+ }
|
||||
+ }
|
||||
+#endif
|
||||
|
||||
- if ((stat = apr_socket_listen(s, ap_listenbacklog)) != APR_SUCCESS) {
|
||||
- ap_log_perror(APLOG_MARK, APLOG_STARTUP|APLOG_ERR, stat, p, APLOGNO(00073)
|
||||
- "make_sock: unable to listen for connections "
|
||||
- "on address %pI",
|
||||
- server->bind_addr);
|
||||
- apr_socket_close(s);
|
||||
- return stat;
|
||||
+ if ((stat = apr_socket_bind(s, server->bind_addr)) != APR_SUCCESS) {
|
||||
+ ap_log_perror(APLOG_MARK, APLOG_STARTUP|APLOG_CRIT, stat, p, APLOGNO(00072)
|
||||
+ "make_sock: could not bind to address %pI",
|
||||
+ server->bind_addr);
|
||||
+ apr_socket_close(s);
|
||||
+ return stat;
|
||||
+ }
|
||||
+
|
||||
+ if ((stat = apr_socket_listen(s, ap_listenbacklog)) != APR_SUCCESS) {
|
||||
+ ap_log_perror(APLOG_MARK, APLOG_STARTUP|APLOG_ERR, stat, p, APLOGNO(00073)
|
||||
+ "make_sock: unable to listen for connections "
|
||||
+ "on address %pI",
|
||||
+ server->bind_addr);
|
||||
+ apr_socket_close(s);
|
||||
+ return stat;
|
||||
+ }
|
||||
}
|
||||
|
||||
#ifdef WIN32
|
||||
@@ -315,6 +324,123 @@ static int find_listeners(ap_listen_rec **from, ap_listen_rec **to,
|
||||
return found;
|
||||
}
|
||||
|
||||
+#ifdef HAVE_SYSTEMD
|
||||
+
|
||||
+static int find_systemd_socket(process_rec * process, apr_port_t port) {
|
||||
+ int fdcount, fd;
|
||||
+ int sdc = sd_listen_fds(0);
|
||||
+
|
||||
+ if (sdc < 0) {
|
||||
+ ap_log_perror(APLOG_MARK, APLOG_CRIT, sdc, process->pool, APLOGNO(02486)
|
||||
+ "find_systemd_socket: Error parsing enviroment, sd_listen_fds returned %d",
|
||||
+ sdc);
|
||||
+ return -1;
|
||||
+ }
|
||||
+
|
||||
+ if (sdc == 0) {
|
||||
+ ap_log_perror(APLOG_MARK, APLOG_CRIT, sdc, process->pool, APLOGNO(02487)
|
||||
+ "find_systemd_socket: At least one socket must be set.");
|
||||
+ return -1;
|
||||
+ }
|
||||
+
|
||||
+ fdcount = atoi(getenv("LISTEN_FDS"));
|
||||
+ for (fd = SD_LISTEN_FDS_START; fd < SD_LISTEN_FDS_START + fdcount; fd++) {
|
||||
+ if (sd_is_socket_inet(fd, 0, 0, -1, port) > 0) {
|
||||
+ return fd;
|
||||
+ }
|
||||
+ }
|
||||
+
|
||||
+ return -1;
|
||||
+}
|
||||
+
|
||||
+static apr_status_t alloc_systemd_listener(process_rec * process,
|
||||
+ int fd, const char *proto,
|
||||
+ ap_listen_rec **out_rec)
|
||||
+{
|
||||
+ apr_status_t rv;
|
||||
+ struct sockaddr sa;
|
||||
+ socklen_t len = sizeof(struct sockaddr);
|
||||
+ apr_os_sock_info_t si;
|
||||
+ ap_listen_rec *rec;
|
||||
+ *out_rec = NULL;
|
||||
+
|
||||
+ memset(&si, 0, sizeof(si));
|
||||
+
|
||||
+ rv = getsockname(fd, &sa, &len);
|
||||
+
|
||||
+ if (rv != 0) {
|
||||
+ rv = apr_get_netos_error();
|
||||
+ ap_log_perror(APLOG_MARK, APLOG_CRIT, rv, process->pool, APLOGNO(02489)
|
||||
+ "getsockname on %d failed.", fd);
|
||||
+ return rv;
|
||||
+ }
|
||||
+
|
||||
+ si.os_sock = &fd;
|
||||
+ si.family = sa.sa_family;
|
||||
+ si.local = &sa;
|
||||
+ si.type = SOCK_STREAM;
|
||||
+ si.protocol = APR_PROTO_TCP;
|
||||
+
|
||||
+ rec = apr_palloc(process->pool, sizeof(ap_listen_rec));
|
||||
+ rec->active = 0;
|
||||
+ rec->next = 0;
|
||||
+
|
||||
+
|
||||
+ rv = apr_os_sock_make(&rec->sd, &si, process->pool);
|
||||
+ if (rv != APR_SUCCESS) {
|
||||
+ ap_log_perror(APLOG_MARK, APLOG_CRIT, rv, process->pool, APLOGNO(02490)
|
||||
+ "apr_os_sock_make on %d failed.", fd);
|
||||
+ return rv;
|
||||
+ }
|
||||
+
|
||||
+ rv = apr_socket_addr_get(&rec->bind_addr, APR_LOCAL, rec->sd);
|
||||
+ if (rv != APR_SUCCESS) {
|
||||
+ ap_log_perror(APLOG_MARK, APLOG_CRIT, rv, process->pool, APLOGNO(02491)
|
||||
+ "apr_socket_addr_get on %d failed.", fd);
|
||||
+ return rv;
|
||||
+ }
|
||||
+
|
||||
+ rec->protocol = apr_pstrdup(process->pool, proto);
|
||||
+
|
||||
+ *out_rec = rec;
|
||||
+
|
||||
+ return make_sock(process->pool, rec, 0);
|
||||
+}
|
||||
+
|
||||
+static const char *set_systemd_listener(process_rec *process, apr_port_t port,
|
||||
+ const char *proto)
|
||||
+{
|
||||
+ ap_listen_rec *last, *new;
|
||||
+ apr_status_t rv;
|
||||
+ int fd = find_systemd_socket(process, port);
|
||||
+ if (fd < 0) {
|
||||
+ return "Systemd socket activation is used, but this port is not "
|
||||
+ "configured in systemd";
|
||||
+ }
|
||||
+
|
||||
+ last = ap_listeners;
|
||||
+ while (last && last->next) {
|
||||
+ last = last->next;
|
||||
+ }
|
||||
+
|
||||
+ rv = alloc_systemd_listener(process, fd, proto, &new);
|
||||
+ if (rv != APR_SUCCESS) {
|
||||
+ return "Failed to setup socket passed by systemd using socket activation";
|
||||
+ }
|
||||
+
|
||||
+ if (last == NULL) {
|
||||
+ ap_listeners = last = new;
|
||||
+ }
|
||||
+ else {
|
||||
+ last->next = new;
|
||||
+ last = new;
|
||||
+ }
|
||||
+
|
||||
+ return NULL;
|
||||
+}
|
||||
+
|
||||
+#endif /* HAVE_SYSTEMD */
|
||||
+
|
||||
static const char *alloc_listener(process_rec *process, const char *addr,
|
||||
apr_port_t port, const char* proto,
|
||||
void *slave)
|
||||
@@ -495,7 +621,7 @@ static int open_listeners(apr_pool_t *pool)
|
||||
}
|
||||
}
|
||||
#endif
|
||||
- if (make_sock(pool, lr) == APR_SUCCESS) {
|
||||
+ if (make_sock(pool, lr, 1) == APR_SUCCESS) {
|
||||
++num_open;
|
||||
}
|
||||
else {
|
||||
@@ -607,8 +733,28 @@ AP_DECLARE(int) ap_setup_listeners(server_rec *s)
|
||||
}
|
||||
}
|
||||
|
||||
- if (open_listeners(s->process->pool)) {
|
||||
- return 0;
|
||||
+#ifdef HAVE_SYSTEMD
|
||||
+ if (use_systemd) {
|
||||
+ const char *userdata_key = "ap_open_systemd_listeners";
|
||||
+ void *data;
|
||||
+ /* clear the enviroment on our second run
|
||||
+ * so that none of our future children get confused.
|
||||
+ */
|
||||
+ apr_pool_userdata_get(&data, userdata_key, s->process->pool);
|
||||
+ if (!data) {
|
||||
+ apr_pool_userdata_set((const void *)1, userdata_key,
|
||||
+ apr_pool_cleanup_null, s->process->pool);
|
||||
+ }
|
||||
+ else {
|
||||
+ sd_listen_fds(1);
|
||||
+ }
|
||||
+ }
|
||||
+ else
|
||||
+#endif
|
||||
+ {
|
||||
+ if (open_listeners(s->process->pool)) {
|
||||
+ return 0;
|
||||
+ }
|
||||
}
|
||||
|
||||
for (lr = ap_listeners; lr; lr = lr->next) {
|
||||
@@ -698,7 +844,7 @@ AP_DECLARE(apr_status_t) ap_duplicate_listeners(apr_pool_t *p, server_rec *s,
|
||||
duplr->bind_addr);
|
||||
return stat;
|
||||
}
|
||||
- make_sock(p, duplr);
|
||||
+ make_sock(p, duplr, 1);
|
||||
#if AP_NONBLOCK_WHEN_MULTI_LISTEN
|
||||
use_nonblock = (ap_listeners && ap_listeners->next);
|
||||
stat = apr_socket_opt_set(duplr->sd, APR_SO_NONBLOCK, use_nonblock);
|
||||
@@ -825,6 +971,11 @@ AP_DECLARE_NONSTD(const char *) ap_set_listener(cmd_parms *cmd, void *dummy,
|
||||
if (argc < 1 || argc > 2) {
|
||||
return "Listen requires 1 or 2 arguments.";
|
||||
}
|
||||
+#ifdef HAVE_SYSTEMD
|
||||
+ if (use_systemd == -1) {
|
||||
+ use_systemd = sd_listen_fds(0) > 0;
|
||||
+ }
|
||||
+#endif
|
||||
|
||||
rv = apr_parse_addr_port(&host, &scope_id, &port, argv[0], cmd->pool);
|
||||
if (rv != APR_SUCCESS) {
|
||||
@@ -856,6 +1007,12 @@ AP_DECLARE_NONSTD(const char *) ap_set_listener(cmd_parms *cmd, void *dummy,
|
||||
ap_str_tolower(proto);
|
||||
}
|
||||
|
||||
+#ifdef HAVE_SYSTEMD
|
||||
+ if (use_systemd) {
|
||||
+ return set_systemd_listener(cmd->server->process, port, proto);
|
||||
+ }
|
||||
+#endif
|
||||
+
|
||||
return alloc_listener(cmd->server->process, host, port, proto, NULL);
|
||||
}
|
||||
|
||||
|
|
@ -1,3 +1,6 @@
|
|||
|
||||
Upstream-Status: r1861685 in trunk, not proposed for 2.4.x
|
||||
|
||||
diff --git a/Makefile.in b/Makefile.in
|
||||
index bd8045c..d6733a5 100644
|
||||
--- a/Makefile.in
|
||||
|
|
|
|||
|
|
@ -1,286 +0,0 @@
|
|||
diff --git a/acinclude.m4 b/acinclude.m4
|
||||
index 05abe18..97484c9 100644
|
||||
--- a/acinclude.m4
|
||||
+++ b/acinclude.m4
|
||||
@@ -631,7 +631,6 @@ case $host in
|
||||
if test "${ac_cv_header_systemd_sd_daemon_h}" = "no" || test -z "${SYSTEMD_LIBS}"; then
|
||||
AC_MSG_WARN([Your system does not support systemd.])
|
||||
else
|
||||
- APR_ADDTO(HTTPD_LIBS, [$SYSTEMD_LIBS])
|
||||
AC_DEFINE(HAVE_SYSTEMD, 1, [Define if systemd is supported])
|
||||
fi
|
||||
fi
|
||||
diff --git a/include/ap_listen.h b/include/ap_listen.h
|
||||
index 58c2574..d5ed968 100644
|
||||
--- a/include/ap_listen.h
|
||||
+++ b/include/ap_listen.h
|
||||
@@ -29,6 +29,7 @@
|
||||
#include "apr_network_io.h"
|
||||
#include "httpd.h"
|
||||
#include "http_config.h"
|
||||
+#include "apr_optional.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
@@ -143,6 +144,15 @@ AP_DECLARE_NONSTD(const char *) ap_set_receive_buffer_size(cmd_parms *cmd,
|
||||
void *dummy,
|
||||
const char *arg);
|
||||
|
||||
+#ifdef HAVE_SYSTEMD
|
||||
+APR_DECLARE_OPTIONAL_FN(int,
|
||||
+ ap_find_systemd_socket, (process_rec *, apr_port_t));
|
||||
+
|
||||
+APR_DECLARE_OPTIONAL_FN(int,
|
||||
+ ap_systemd_listen_fds, (int));
|
||||
+#endif
|
||||
+
|
||||
+
|
||||
#define LISTEN_COMMANDS \
|
||||
AP_INIT_TAKE1("ListenBacklog", ap_set_listenbacklog, NULL, RSRC_CONF, \
|
||||
"Maximum length of the queue of pending connections, as used by listen(2)"), \
|
||||
diff --git a/modules/arch/unix/mod_systemd.c b/modules/arch/unix/mod_systemd.c
|
||||
index eda1272..fc059fc 100644
|
||||
--- a/modules/arch/unix/mod_systemd.c
|
||||
+++ b/modules/arch/unix/mod_systemd.c
|
||||
@@ -35,6 +35,15 @@
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
|
||||
+APR_DECLARE_OPTIONAL_FN(int,
|
||||
+ ap_find_systemd_socket, (process_rec *, apr_port_t));
|
||||
+
|
||||
+APR_DECLARE_OPTIONAL_FN(int,
|
||||
+ ap_systemd_listen_fds, (int));
|
||||
+
|
||||
+APR_DECLARE_OPTIONAL_FN(int,
|
||||
+ ap_systemd_journal_stream_fd, (const char *, int, int));
|
||||
+
|
||||
static char describe_listeners[30];
|
||||
|
||||
static int systemd_pre_config(apr_pool_t *pconf, apr_pool_t *plog,
|
||||
@@ -145,8 +154,47 @@ static int systemd_monitor(apr_pool_t *p, server_rec *s)
|
||||
return DECLINED;
|
||||
}
|
||||
|
||||
+static int ap_find_systemd_socket(process_rec * process, apr_port_t port) {
|
||||
+ int fdcount, fd;
|
||||
+ int sdc = sd_listen_fds(0);
|
||||
+
|
||||
+ if (sdc < 0) {
|
||||
+ ap_log_perror(APLOG_MARK, APLOG_CRIT, sdc, process->pool, APLOGNO(02486)
|
||||
+ "find_systemd_socket: Error parsing enviroment, sd_listen_fds returned %d",
|
||||
+ sdc);
|
||||
+ return -1;
|
||||
+ }
|
||||
+
|
||||
+ if (sdc == 0) {
|
||||
+ ap_log_perror(APLOG_MARK, APLOG_CRIT, sdc, process->pool, APLOGNO(02487)
|
||||
+ "find_systemd_socket: At least one socket must be set.");
|
||||
+ return -1;
|
||||
+ }
|
||||
+
|
||||
+ fdcount = atoi(getenv("LISTEN_FDS"));
|
||||
+ for (fd = SD_LISTEN_FDS_START; fd < SD_LISTEN_FDS_START + fdcount; fd++) {
|
||||
+ if (sd_is_socket_inet(fd, 0, 0, -1, port) > 0) {
|
||||
+ return fd;
|
||||
+ }
|
||||
+ }
|
||||
+
|
||||
+ return -1;
|
||||
+}
|
||||
+
|
||||
+static int ap_systemd_listen_fds(int unset_environment){
|
||||
+ return sd_listen_fds(unset_environment);
|
||||
+}
|
||||
+
|
||||
+static int ap_systemd_journal_stream_fd(const char *identifier, int priority, int level_prefix){
|
||||
+ return sd_journal_stream_fd("httpd", priority, 0);
|
||||
+}
|
||||
+
|
||||
static void systemd_register_hooks(apr_pool_t *p)
|
||||
{
|
||||
+ APR_REGISTER_OPTIONAL_FN(ap_systemd_listen_fds);
|
||||
+ APR_REGISTER_OPTIONAL_FN(ap_find_systemd_socket);
|
||||
+ APR_REGISTER_OPTIONAL_FN(ap_systemd_journal_stream_fd);
|
||||
+
|
||||
/* Enable ap_extended_status. */
|
||||
ap_hook_pre_config(systemd_pre_config, NULL, NULL, APR_HOOK_LAST);
|
||||
/* Signal service is ready. */
|
||||
diff --git a/modules/loggers/config.m4 b/modules/loggers/config.m4
|
||||
index 0848d2e..8af2299 100644
|
||||
--- a/modules/loggers/config.m4
|
||||
+++ b/modules/loggers/config.m4
|
||||
@@ -5,7 +5,6 @@ dnl APACHE_MODULE(name, helptext[, objects[, structname[, default[, config]]]])
|
||||
APACHE_MODPATH_INIT(loggers)
|
||||
|
||||
APACHE_MODULE(log_config, logging configuration. You won't be able to log requests to the server without this module., , , yes)
|
||||
-APR_ADDTO(MOD_LOG_CONFIG_LDADD, [$SYSTEMD_LIBS])
|
||||
|
||||
APACHE_MODULE(log_debug, configurable debug logging, , , most)
|
||||
APACHE_MODULE(log_forensic, forensic logging)
|
||||
diff --git a/modules/loggers/mod_log_config.c b/modules/loggers/mod_log_config.c
|
||||
index 0b11f60..c3f0a51 100644
|
||||
--- a/modules/loggers/mod_log_config.c
|
||||
+++ b/modules/loggers/mod_log_config.c
|
||||
@@ -172,10 +172,6 @@
|
||||
#include <limits.h>
|
||||
#endif
|
||||
|
||||
-#ifdef HAVE_SYSTEMD
|
||||
-#include <systemd/sd-journal.h>
|
||||
-#endif
|
||||
-
|
||||
#define DEFAULT_LOG_FORMAT "%h %l %u %t \"%r\" %>s %b"
|
||||
|
||||
module AP_MODULE_DECLARE_DATA log_config_module;
|
||||
@@ -1640,8 +1636,15 @@ static apr_status_t wrap_journal_stream(apr_pool_t *p, apr_file_t **outfd,
|
||||
{
|
||||
#ifdef HAVE_SYSTEMD
|
||||
int fd;
|
||||
+ APR_OPTIONAL_FN_TYPE(ap_systemd_journal_stream_fd) *systemd_journal_stream_fd;
|
||||
+
|
||||
+ systemd_journal_stream_fd = APR_RETRIEVE_OPTIONAL_FN(ap_systemd_journal_stream_fd);
|
||||
+ if (systemd_journal_stream_fd == NULL) {
|
||||
+ return APR_ENOTIMPL;
|
||||
+ }
|
||||
|
||||
- fd = sd_journal_stream_fd("httpd", priority, 0);
|
||||
+ fd = systemd_journal_stream_fd("httpd", priority, 0);
|
||||
+
|
||||
if (fd < 0) return fd;
|
||||
|
||||
/* This is an AF_UNIX socket fd so is more pipe-like than
|
||||
diff --git a/modules/loggers/mod_log_config.h b/modules/loggers/mod_log_config.h
|
||||
index 877a593..bd52a98 100644
|
||||
--- a/modules/loggers/mod_log_config.h
|
||||
+++ b/modules/loggers/mod_log_config.h
|
||||
@@ -69,6 +69,10 @@ APR_DECLARE_OPTIONAL_FN(ap_log_writer_init*, ap_log_set_writer_init,(ap_log_writ
|
||||
*/
|
||||
APR_DECLARE_OPTIONAL_FN(ap_log_writer*, ap_log_set_writer, (ap_log_writer* func));
|
||||
|
||||
+#ifdef HAVE_SYSTEMD
|
||||
+APR_DECLARE_OPTIONAL_FN(int, ap_systemd_journal_stream_fd, (const char *, int, int));
|
||||
+#endif
|
||||
+
|
||||
#endif /* MOD_LOG_CONFIG */
|
||||
/** @} */
|
||||
|
||||
diff --git a/server/listen.c b/server/listen.c
|
||||
index e2e028a..5d1c0e1 100644
|
||||
--- a/server/listen.c
|
||||
+++ b/server/listen.c
|
||||
@@ -34,10 +34,6 @@
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
|
||||
-#ifdef HAVE_SYSTEMD
|
||||
-#include <systemd/sd-daemon.h>
|
||||
-#endif
|
||||
-
|
||||
/* we know core's module_index is 0 */
|
||||
#undef APLOG_MODULE_INDEX
|
||||
#define APLOG_MODULE_INDEX AP_CORE_MODULE_INDEX
|
||||
@@ -325,34 +321,6 @@ static int find_listeners(ap_listen_rec **from, ap_listen_rec **to,
|
||||
}
|
||||
|
||||
#ifdef HAVE_SYSTEMD
|
||||
-
|
||||
-static int find_systemd_socket(process_rec * process, apr_port_t port) {
|
||||
- int fdcount, fd;
|
||||
- int sdc = sd_listen_fds(0);
|
||||
-
|
||||
- if (sdc < 0) {
|
||||
- ap_log_perror(APLOG_MARK, APLOG_CRIT, sdc, process->pool, APLOGNO(02486)
|
||||
- "find_systemd_socket: Error parsing enviroment, sd_listen_fds returned %d",
|
||||
- sdc);
|
||||
- return -1;
|
||||
- }
|
||||
-
|
||||
- if (sdc == 0) {
|
||||
- ap_log_perror(APLOG_MARK, APLOG_CRIT, sdc, process->pool, APLOGNO(02487)
|
||||
- "find_systemd_socket: At least one socket must be set.");
|
||||
- return -1;
|
||||
- }
|
||||
-
|
||||
- fdcount = atoi(getenv("LISTEN_FDS"));
|
||||
- for (fd = SD_LISTEN_FDS_START; fd < SD_LISTEN_FDS_START + fdcount; fd++) {
|
||||
- if (sd_is_socket_inet(fd, 0, 0, -1, port) > 0) {
|
||||
- return fd;
|
||||
- }
|
||||
- }
|
||||
-
|
||||
- return -1;
|
||||
-}
|
||||
-
|
||||
static apr_status_t alloc_systemd_listener(process_rec * process,
|
||||
int fd, const char *proto,
|
||||
ap_listen_rec **out_rec)
|
||||
@@ -412,6 +380,14 @@ static const char *set_systemd_listener(process_rec *process, apr_port_t port,
|
||||
{
|
||||
ap_listen_rec *last, *new;
|
||||
apr_status_t rv;
|
||||
+ APR_OPTIONAL_FN_TYPE(ap_find_systemd_socket) *find_systemd_socket;
|
||||
+
|
||||
+ find_systemd_socket = APR_RETRIEVE_OPTIONAL_FN(ap_find_systemd_socket);
|
||||
+
|
||||
+ if (!find_systemd_socket)
|
||||
+ return "Systemd socket activation is used, but mod_systemd is probably "
|
||||
+ "not loaded";
|
||||
+
|
||||
int fd = find_systemd_socket(process, port);
|
||||
if (fd < 0) {
|
||||
return "Systemd socket activation is used, but this port is not "
|
||||
@@ -438,7 +414,6 @@ static const char *set_systemd_listener(process_rec *process, apr_port_t port,
|
||||
|
||||
return NULL;
|
||||
}
|
||||
-
|
||||
#endif /* HAVE_SYSTEMD */
|
||||
|
||||
static const char *alloc_listener(process_rec *process, const char *addr,
|
||||
@@ -707,6 +682,9 @@ AP_DECLARE(int) ap_setup_listeners(server_rec *s)
|
||||
int num_listeners = 0;
|
||||
const char* proto;
|
||||
int found;
|
||||
+#ifdef HAVE_SYSTEMD
|
||||
+ APR_OPTIONAL_FN_TYPE(ap_systemd_listen_fds) *systemd_listen_fds;
|
||||
+#endif
|
||||
|
||||
for (ls = s; ls; ls = ls->next) {
|
||||
proto = ap_get_server_protocol(ls);
|
||||
@@ -746,7 +724,10 @@ AP_DECLARE(int) ap_setup_listeners(server_rec *s)
|
||||
apr_pool_cleanup_null, s->process->pool);
|
||||
}
|
||||
else {
|
||||
- sd_listen_fds(1);
|
||||
+ systemd_listen_fds = APR_RETRIEVE_OPTIONAL_FN(ap_systemd_listen_fds);
|
||||
+ if (systemd_listen_fds != NULL) {
|
||||
+ systemd_listen_fds(1);
|
||||
+ }
|
||||
}
|
||||
}
|
||||
else
|
||||
@@ -963,6 +944,9 @@ AP_DECLARE_NONSTD(const char *) ap_set_listener(cmd_parms *cmd, void *dummy,
|
||||
apr_port_t port;
|
||||
apr_status_t rv;
|
||||
const char *err = ap_check_cmd_context(cmd, GLOBAL_ONLY);
|
||||
+#ifdef HAVE_SYSTEMD
|
||||
+ APR_OPTIONAL_FN_TYPE(ap_systemd_listen_fds) *systemd_listen_fds;
|
||||
+#endif
|
||||
|
||||
if (err != NULL) {
|
||||
return err;
|
||||
@@ -973,7 +957,12 @@ AP_DECLARE_NONSTD(const char *) ap_set_listener(cmd_parms *cmd, void *dummy,
|
||||
}
|
||||
#ifdef HAVE_SYSTEMD
|
||||
if (use_systemd == -1) {
|
||||
- use_systemd = sd_listen_fds(0) > 0;
|
||||
+ systemd_listen_fds = APR_RETRIEVE_OPTIONAL_FN(ap_systemd_listen_fds);
|
||||
+ if (systemd_listen_fds != NULL) {
|
||||
+ use_systemd = systemd_listen_fds(0) > 0;
|
||||
+ } else {
|
||||
+ use_systemd = 0;
|
||||
+ }
|
||||
}
|
||||
#endif
|
||||
|
||||
|
|
@ -1,64 +0,0 @@
|
|||
|
||||
Upstream-Status: in trunk not in 2.4.x
|
||||
|
||||
diff --git a/configure.in b/configure.in
|
||||
index 74015ca..8c0ee10 100644
|
||||
--- httpd-2.4.54/modules/arch/unix/config5.m4.selinux
|
||||
+++ httpd-2.4.54/modules/arch/unix/config5.m4
|
||||
@@ -23,6 +23,11 @@
|
||||
AC_MSG_WARN([Your system does not support systemd.])
|
||||
enable_systemd="no"
|
||||
else
|
||||
+ AC_CHECK_LIB(selinux, is_selinux_enabled, [
|
||||
+ AC_DEFINE(HAVE_SELINUX, 1, [Defined if SELinux is supported])
|
||||
+ APR_ADDTO(MOD_SYSTEMD_LDADD, [-lselinux])
|
||||
+ ])
|
||||
+
|
||||
APR_ADDTO(MOD_SYSTEMD_LDADD, [$SYSTEMD_LIBS])
|
||||
fi
|
||||
])
|
||||
--- httpd-2.4.54/modules/arch/unix/mod_systemd.c.selinux
|
||||
+++ httpd-2.4.54/modules/arch/unix/mod_systemd.c
|
||||
@@ -35,6 +35,10 @@
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
|
||||
+#ifdef HAVE_SELINUX
|
||||
+#include <selinux/selinux.h>
|
||||
+#endif
|
||||
+
|
||||
APR_DECLARE_OPTIONAL_FN(int,
|
||||
ap_find_systemd_socket, (process_rec *, apr_port_t));
|
||||
|
||||
@@ -70,6 +74,20 @@
|
||||
return apr_psprintf(p, "%s port %u", addr, sa->port);
|
||||
}
|
||||
|
||||
+#ifdef HAVE_SELINUX
|
||||
+static void log_selinux_context(void)
|
||||
+{
|
||||
+ char *con;
|
||||
+
|
||||
+ if (is_selinux_enabled() && getcon(&con) == 0) {
|
||||
+ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, NULL,
|
||||
+ "SELinux policy enabled; "
|
||||
+ "httpd running as context %s", con);
|
||||
+ freecon(con);
|
||||
+ }
|
||||
+}
|
||||
+#endif
|
||||
+
|
||||
/* Report the service is ready in post_config, which could be during
|
||||
* startup or after a reload. The server could still hit a fatal
|
||||
* startup error after this point during ap_run_mpm(), so this is
|
||||
@@ -87,6 +105,10 @@
|
||||
if (ap_state_query(AP_SQ_MAIN_STATE) == AP_SQ_MS_CREATE_PRE_CONFIG)
|
||||
return OK;
|
||||
|
||||
+#ifdef HAVE_SELINUX
|
||||
+ log_selinux_context();
|
||||
+#endif
|
||||
+
|
||||
for (lr = ap_listeners; lr; lr = lr->next) {
|
||||
char *s = dump_listener(lr, ptemp);
|
||||
|
||||
|
|
@ -1,221 +0,0 @@
|
|||
# ./pullrev.sh 1914365
|
||||
http://svn.apache.org/viewvc?view=revision&revision=1914365
|
||||
|
||||
Upstream-Status: in trunk, not proposed for 2.4.x
|
||||
|
||||
--- httpd-2.4.58/modules/ssl/ssl_engine_init.c.r1914365
|
||||
+++ httpd-2.4.58/modules/ssl/ssl_engine_init.c
|
||||
@@ -1421,8 +1421,10 @@
|
||||
if (cert) {
|
||||
if (SSL_CTX_use_certificate(mctx->ssl_ctx, cert) < 1) {
|
||||
ap_log_error(APLOG_MARK, APLOG_EMERG, 0, s, APLOGNO(10137)
|
||||
- "Failed to configure engine certificate %s, check %s",
|
||||
- key_id, certfile);
|
||||
+ "Failed to configure certificate %s from %s, check %s",
|
||||
+ key_id, mc->szCryptoDevice ?
|
||||
+ mc->szCryptoDevice : "provider",
|
||||
+ certfile);
|
||||
ssl_log_ssl_error(SSLLOG_MARK, APLOG_EMERG, s);
|
||||
return APR_EGENERAL;
|
||||
}
|
||||
@@ -1433,8 +1435,9 @@
|
||||
|
||||
if (SSL_CTX_use_PrivateKey(mctx->ssl_ctx, pkey) < 1) {
|
||||
ap_log_error(APLOG_MARK, APLOG_EMERG, 0, s, APLOGNO(10130)
|
||||
- "Failed to configure private key %s from engine",
|
||||
- keyfile);
|
||||
+ "Failed to configure private key %s from %s",
|
||||
+ keyfile, mc->szCryptoDevice ?
|
||||
+ mc->szCryptoDevice : "provider");
|
||||
ssl_log_ssl_error(SSLLOG_MARK, APLOG_EMERG, s);
|
||||
return APR_EGENERAL;
|
||||
}
|
||||
--- httpd-2.4.58/modules/ssl/ssl_engine_pphrase.c.r1914365
|
||||
+++ httpd-2.4.58/modules/ssl/ssl_engine_pphrase.c
|
||||
@@ -31,6 +31,9 @@
|
||||
#include "ssl_private.h"
|
||||
|
||||
#include <openssl/ui.h>
|
||||
+#if MODSSL_HAVE_OPENSSL_STORE
|
||||
+#include <openssl/store.h>
|
||||
+#endif
|
||||
|
||||
typedef struct {
|
||||
server_rec *s;
|
||||
@@ -608,7 +611,7 @@
|
||||
return (len);
|
||||
}
|
||||
|
||||
-#if MODSSL_HAVE_ENGINE_API
|
||||
+#if MODSSL_HAVE_ENGINE_API || MODSSL_HAVE_OPENSSL_STORE
|
||||
|
||||
/* OpenSSL UI implementation for passphrase entry; largely duplicated
|
||||
* from ssl_pphrase_Handle_CB but adjusted for UI API. TODO: Might be
|
||||
@@ -826,13 +829,14 @@
|
||||
}
|
||||
#endif
|
||||
|
||||
-
|
||||
-apr_status_t modssl_load_engine_keypair(server_rec *s, apr_pool_t *p,
|
||||
+#if MODSSL_HAVE_ENGINE_API
|
||||
+static apr_status_t modssl_load_keypair_engine(server_rec *s, apr_pool_t *p,
|
||||
const char *vhostid,
|
||||
- const char *certid, const char *keyid,
|
||||
- X509 **pubkey, EVP_PKEY **privkey)
|
||||
+ const char *certid,
|
||||
+ const char *keyid,
|
||||
+ X509 **pubkey,
|
||||
+ EVP_PKEY **privkey)
|
||||
{
|
||||
-#if MODSSL_HAVE_ENGINE_API
|
||||
const char *c, *scheme;
|
||||
ENGINE *e;
|
||||
UI_METHOD *ui_method = get_passphrase_ui(p);
|
||||
@@ -906,6 +910,118 @@
|
||||
ENGINE_free(e);
|
||||
|
||||
return APR_SUCCESS;
|
||||
+}
|
||||
+#endif
|
||||
+
|
||||
+#if MODSSL_HAVE_OPENSSL_STORE
|
||||
+static OSSL_STORE_INFO *modssl_load_store_uri(server_rec *s, apr_pool_t *p,
|
||||
+ const char *vhostid,
|
||||
+ const char *uri, int info_type)
|
||||
+{
|
||||
+ OSSL_STORE_CTX *sctx;
|
||||
+ UI_METHOD *ui_method = get_passphrase_ui(p);
|
||||
+ pphrase_cb_arg_t ppcb;
|
||||
+ OSSL_STORE_INFO *info = NULL;
|
||||
+
|
||||
+ memset(&ppcb, 0, sizeof ppcb);
|
||||
+ ppcb.s = s;
|
||||
+ ppcb.p = p;
|
||||
+ ppcb.bPassPhraseDialogOnce = TRUE;
|
||||
+ ppcb.key_id = vhostid;
|
||||
+ ppcb.pkey_file = uri;
|
||||
+
|
||||
+ sctx = OSSL_STORE_open(uri, ui_method, &ppcb, NULL, NULL);
|
||||
+ if (!sctx) {
|
||||
+ ap_log_error(APLOG_MARK, APLOG_ERR, 0, s, APLOGNO(10491)
|
||||
+ "Init: OSSL_STORE_open failed for PKCS#11 URI `%s'",
|
||||
+ uri);
|
||||
+ return NULL;
|
||||
+ }
|
||||
+
|
||||
+ while (!OSSL_STORE_eof(sctx)) {
|
||||
+ info = OSSL_STORE_load(sctx);
|
||||
+ if (!info)
|
||||
+ break;
|
||||
+
|
||||
+ if (OSSL_STORE_INFO_get_type(info) == info_type)
|
||||
+ break;
|
||||
+
|
||||
+ OSSL_STORE_INFO_free(info);
|
||||
+ info = NULL;
|
||||
+ }
|
||||
+
|
||||
+ OSSL_STORE_close(sctx);
|
||||
+
|
||||
+ return info;
|
||||
+}
|
||||
+
|
||||
+static apr_status_t modssl_load_keypair_store(server_rec *s, apr_pool_t *p,
|
||||
+ const char *vhostid,
|
||||
+ const char *certid,
|
||||
+ const char *keyid,
|
||||
+ X509 **pubkey,
|
||||
+ EVP_PKEY **privkey)
|
||||
+{
|
||||
+ OSSL_STORE_INFO *info = NULL;
|
||||
+
|
||||
+ *privkey = NULL;
|
||||
+ *pubkey = NULL;
|
||||
+
|
||||
+ info = modssl_load_store_uri(s, p, vhostid, keyid, OSSL_STORE_INFO_PKEY);
|
||||
+ if (!info) {
|
||||
+ ap_log_error(APLOG_MARK, APLOG_EMERG, 0, s, APLOGNO(10492)
|
||||
+ "Init: OSSL_STORE_INFO_PKEY lookup failed for private key identifier `%s'",
|
||||
+ keyid);
|
||||
+ return ssl_die(s);
|
||||
+ }
|
||||
+
|
||||
+ *privkey = OSSL_STORE_INFO_get1_PKEY(info);
|
||||
+ OSSL_STORE_INFO_free(info);
|
||||
+ if (!*privkey) {
|
||||
+ ap_log_error(APLOG_MARK, APLOG_EMERG, 0, s, APLOGNO(10493)
|
||||
+ "Init: OSSL_STORE_INFO_PKEY lookup failed for private key identifier `%s'",
|
||||
+ keyid);
|
||||
+ return ssl_die(s);
|
||||
+ }
|
||||
+
|
||||
+ if (certid) {
|
||||
+ info = modssl_load_store_uri(s, p, vhostid, certid, OSSL_STORE_INFO_CERT);
|
||||
+ if (!info) {
|
||||
+ ap_log_error(APLOG_MARK, APLOG_EMERG, 0, s, APLOGNO(10494)
|
||||
+ "Init: OSSL_STORE_INFO_CERT lookup failed for certificate identifier `%s'",
|
||||
+ keyid);
|
||||
+ return ssl_die(s);
|
||||
+ }
|
||||
+
|
||||
+ *pubkey = OSSL_STORE_INFO_get1_CERT(info);
|
||||
+ OSSL_STORE_INFO_free(info);
|
||||
+ if (!*pubkey) {
|
||||
+ ap_log_error(APLOG_MARK, APLOG_EMERG, 0, s, APLOGNO(10495)
|
||||
+ "Init: OSSL_STORE_INFO_CERT lookup failed for certificate identifier `%s'",
|
||||
+ certid);
|
||||
+ return ssl_die(s);
|
||||
+ }
|
||||
+ }
|
||||
+
|
||||
+ return APR_SUCCESS;
|
||||
+}
|
||||
+#endif
|
||||
+
|
||||
+apr_status_t modssl_load_engine_keypair(server_rec *s, apr_pool_t *p,
|
||||
+ const char *vhostid,
|
||||
+ const char *certid, const char *keyid,
|
||||
+ X509 **pubkey, EVP_PKEY **privkey)
|
||||
+{
|
||||
+#if MODSSL_HAVE_OPENSSL_STORE
|
||||
+ SSLModConfigRec *mc = myModConfig(s);
|
||||
+
|
||||
+ if (!mc->szCryptoDevice)
|
||||
+ return modssl_load_keypair_store(s, p, vhostid, certid, keyid,
|
||||
+ pubkey, privkey);
|
||||
+#endif
|
||||
+#if MODSSL_HAVE_ENGINE_API
|
||||
+ return modssl_load_keypair_engine(s, p, vhostid, certid, keyid,
|
||||
+ pubkey, privkey);
|
||||
#else
|
||||
return APR_ENOTIMPL;
|
||||
#endif
|
||||
--- httpd-2.4.58/modules/ssl/ssl_private.h.r1914365
|
||||
+++ httpd-2.4.58/modules/ssl/ssl_private.h
|
||||
@@ -118,6 +118,15 @@
|
||||
#define MODSSL_HAVE_ENGINE_API 0
|
||||
#endif
|
||||
|
||||
+/* Use OpenSSL 3.x STORE for loading URI keys and certificates starting with
|
||||
+ * OpenSSL 3.0
|
||||
+ */
|
||||
+#if OPENSSL_VERSION_NUMBER >= 0x30000000
|
||||
+#define MODSSL_HAVE_OPENSSL_STORE 1
|
||||
+#else
|
||||
+#define MODSSL_HAVE_OPENSSL_STORE 0
|
||||
+#endif
|
||||
+
|
||||
#if (OPENSSL_VERSION_NUMBER < 0x0090801f)
|
||||
#error mod_ssl requires OpenSSL 0.9.8a or later
|
||||
#endif
|
||||
--- httpd-2.4.58/modules/ssl/ssl_util.c.r1914365
|
||||
+++ httpd-2.4.58/modules/ssl/ssl_util.c
|
||||
@@ -476,7 +476,7 @@
|
||||
|
||||
int modssl_is_engine_id(const char *name)
|
||||
{
|
||||
-#if MODSSL_HAVE_ENGINE_API
|
||||
+#if MODSSL_HAVE_ENGINE_API || MODSSL_HAVE_OPENSSL_STORE
|
||||
/* ### Can handle any other special ENGINE key names here? */
|
||||
return strncmp(name, "pkcs11:", 7) == 0;
|
||||
#else
|
||||
|
|
@ -1,14 +0,0 @@
|
|||
|
||||
Upstream-Status: not pushed upstream
|
||||
|
||||
--- httpd-2.4.54/server/log.c.gettid
|
||||
+++ httpd-2.4.54/server/log.c
|
||||
@@ -968,7 +972,7 @@
|
||||
#if APR_HAS_THREADS
|
||||
field_start = len;
|
||||
len += cpystrn(buf + len, ":tid ", buflen - len);
|
||||
- item_len = log_tid(info, NULL, buf + len, buflen - len);
|
||||
+ item_len = log_tid(info, "g", buf + len, buflen - len);
|
||||
if (!item_len)
|
||||
len = field_start;
|
||||
else
|
||||
|
|
@ -1,54 +0,0 @@
|
|||
# ./pullrev.sh 1916863
|
||||
http://svn.apache.org/viewvc?view=revision&revision=1916863
|
||||
|
||||
Upstream-Status: in trunk, not proposed for 2.4.x
|
||||
|
||||
--- httpd-2.4.59/modules/ssl/ssl_engine_init.c
|
||||
+++ httpd-2.4.59/modules/ssl/ssl_engine_init.c
|
||||
@@ -1416,6 +1416,7 @@
|
||||
const char *vhost_id = mctx->sc->vhost_id, *key_id, *certfile, *keyfile;
|
||||
int i;
|
||||
EVP_PKEY *pkey;
|
||||
+ int custom_dh_done = 0;
|
||||
#ifdef HAVE_ECC
|
||||
EC_GROUP *ecgroup = NULL;
|
||||
int curve_nid = 0;
|
||||
@@ -1591,14 +1592,14 @@
|
||||
*/
|
||||
certfile = APR_ARRAY_IDX(mctx->pks->cert_files, 0, const char *);
|
||||
if (certfile && !modssl_is_engine_id(certfile)) {
|
||||
- int done = 0, num_bits = 0;
|
||||
+ int num_bits = 0;
|
||||
#if OPENSSL_VERSION_NUMBER < 0x30000000L
|
||||
DH *dh = modssl_dh_from_file(certfile);
|
||||
if (dh) {
|
||||
num_bits = DH_bits(dh);
|
||||
SSL_CTX_set_tmp_dh(mctx->ssl_ctx, dh);
|
||||
DH_free(dh);
|
||||
- done = 1;
|
||||
+ custom_dh_done = 1;
|
||||
}
|
||||
#else
|
||||
pkey = modssl_dh_pkey_from_file(certfile);
|
||||
@@ -1608,18 +1609,18 @@
|
||||
EVP_PKEY_free(pkey);
|
||||
}
|
||||
else {
|
||||
- done = 1;
|
||||
+ custom_dh_done = 1;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
- if (done) {
|
||||
+ if (custom_dh_done) {
|
||||
ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, s, APLOGNO(02540)
|
||||
"Custom DH parameters (%d bits) for %s loaded from %s",
|
||||
num_bits, vhost_id, certfile);
|
||||
}
|
||||
}
|
||||
#if !MODSSL_USE_OPENSSL_PRE_1_1_API
|
||||
- else {
|
||||
+ if (!custom_dh_done) {
|
||||
/* If no parameter is manually configured, enable auto
|
||||
* selection. */
|
||||
SSL_CTX_set_dh_auto(mctx->ssl_ctx, 1);
|
||||
File diff suppressed because it is too large
Load diff
|
|
@ -7,9 +7,11 @@ http://svn.apache.org/viewvc?view=revision&revision=1914438
|
|||
|
||||
Upstream-Status: in trunk, not proposed for 2.4.x
|
||||
|
||||
--- httpd-2.4.58/modules/dav/fs/config6.m4.r1912477+
|
||||
+++ httpd-2.4.58/modules/dav/fs/config6.m4
|
||||
@@ -20,4 +20,10 @@
|
||||
diff --git a/modules/dav/fs/config6.m4 b/modules/dav/fs/config6.m4
|
||||
index dd26ec8..72fff9a 100644
|
||||
--- a/modules/dav/fs/config6.m4
|
||||
+++ b/modules/dav/fs/config6.m4
|
||||
@@ -20,4 +20,10 @@ esac
|
||||
|
||||
APACHE_MODULE(dav_fs, DAV provider for the filesystem. --enable-dav also enables mod_dav_fs., $dav_fs_objects, , $dav_fs_enable,,dav)
|
||||
|
||||
|
|
@ -20,8 +22,10 @@ Upstream-Status: in trunk, not proposed for 2.4.x
|
|||
+fi
|
||||
+
|
||||
APACHE_MODPATH_FINISH
|
||||
--- httpd-2.4.58/modules/dav/fs/dbm.c.r1912477+
|
||||
+++ httpd-2.4.58/modules/dav/fs/dbm.c
|
||||
diff --git a/modules/dav/fs/dbm.c b/modules/dav/fs/dbm.c
|
||||
index 39ab4ad..4551f70 100644
|
||||
--- a/modules/dav/fs/dbm.c
|
||||
+++ b/modules/dav/fs/dbm.c
|
||||
@@ -47,6 +47,10 @@
|
||||
#include "http_log.h"
|
||||
#include "http_main.h" /* for ap_server_conf */
|
||||
|
|
@ -33,16 +37,7 @@ Upstream-Status: in trunk, not proposed for 2.4.x
|
|||
APLOG_USE_MODULE(dav_fs);
|
||||
|
||||
struct dav_db {
|
||||
@@ -100,7 +104,7 @@
|
||||
/* There might not be a <db> if we had problems creating it. */
|
||||
if (db == NULL) {
|
||||
errcode = 1;
|
||||
- errstr = "Could not open property database.";
|
||||
+ errstr = "Could not open database.";
|
||||
if (APR_STATUS_IS_EDSOOPEN(status))
|
||||
ap_log_error(APLOG_MARK, APLOG_CRIT, status, ap_server_conf, APLOGNO(00576)
|
||||
"The DBM driver could not be loaded");
|
||||
@@ -129,10 +133,10 @@
|
||||
@@ -129,10 +133,10 @@ void dav_fs_ensure_state_dir(apr_pool_t * p, const char *dirname)
|
||||
/* dav_dbm_open_direct: Opens a *dbm database specified by path.
|
||||
* ro = boolean read-only flag.
|
||||
*/
|
||||
|
|
@ -56,7 +51,7 @@ Upstream-Status: in trunk, not proposed for 2.4.x
|
|||
const apr_dbm_driver_t *driver;
|
||||
const apu_err_t *err;
|
||||
#endif
|
||||
@@ -141,13 +145,13 @@
|
||||
@@ -141,11 +145,12 @@ dav_error * dav_dbm_open_direct(apr_pool_t *p, const char *pathname, int ro,
|
||||
|
||||
*pdb = NULL;
|
||||
|
||||
|
|
@ -64,18 +59,16 @@ Upstream-Status: in trunk, not proposed for 2.4.x
|
|||
- if ((status = apr_dbm_get_driver(&driver, NULL, &err, p)) != APR_SUCCESS) {
|
||||
+#if APR_MAJOR_VERSION > 1 || (APU_MAJOR_VERSION == 1 && APU_MINOR_VERSION >= 7)
|
||||
+ if ((status = apr_dbm_get_driver(&driver, dbmtype, &err, p)) != APR_SUCCESS) {
|
||||
+
|
||||
ap_log_error(APLOG_MARK, APLOG_ERR, status, ap_server_conf, APLOGNO(10289)
|
||||
- "mod_dav_fs: The DBM library '%s' could not be loaded: %s",
|
||||
- err->reason, err->msg);
|
||||
+ "mod_dav_fs: The DBM library '%s' for '%s' could not be loaded: %s",
|
||||
+ err->reason, dbmtype, err->msg);
|
||||
return dav_new_error(p, HTTP_INTERNAL_SERVER_ERROR, 1, status,
|
||||
- "Could not load library for property database.");
|
||||
+ "Could not load library for database.");
|
||||
"Could not load library for database.");
|
||||
}
|
||||
if ((status = apr_dbm_open2(&file, driver, pathname,
|
||||
ro ? APR_DBM_READONLY : APR_DBM_RWCREATE,
|
||||
@@ -156,7 +160,7 @@
|
||||
@@ -156,7 +161,7 @@ dav_error * dav_dbm_open_direct(apr_pool_t *p, const char *pathname, int ro,
|
||||
return dav_fs_dbm_error(NULL, p, status);
|
||||
}
|
||||
#else
|
||||
|
|
@ -84,7 +77,7 @@ Upstream-Status: in trunk, not proposed for 2.4.x
|
|||
ro ? APR_DBM_READONLY : APR_DBM_RWCREATE,
|
||||
APR_OS_DEFAULT, p))
|
||||
!= APR_SUCCESS
|
||||
@@ -206,7 +210,7 @@
|
||||
@@ -206,7 +211,7 @@ static dav_error * dav_dbm_open(apr_pool_t * p, const dav_resource *resource,
|
||||
|
||||
/* ### do we need to deal with the umask? */
|
||||
|
||||
|
|
@ -93,9 +86,11 @@ Upstream-Status: in trunk, not proposed for 2.4.x
|
|||
}
|
||||
|
||||
void dav_dbm_close(dav_db *db)
|
||||
--- httpd-2.4.58/modules/dav/fs/lock.c.r1912477+
|
||||
+++ httpd-2.4.58/modules/dav/fs/lock.c
|
||||
@@ -181,8 +181,7 @@
|
||||
diff --git a/modules/dav/fs/lock.c b/modules/dav/fs/lock.c
|
||||
index ef18c4a..29d167d 100644
|
||||
--- a/modules/dav/fs/lock.c
|
||||
+++ b/modules/dav/fs/lock.c
|
||||
@@ -181,8 +181,7 @@ struct dav_lockdb_private
|
||||
{
|
||||
request_rec *r; /* for accessing the uuid state */
|
||||
apr_pool_t *pool; /* a pool to use */
|
||||
|
|
@ -105,7 +100,7 @@ Upstream-Status: in trunk, not proposed for 2.4.x
|
|||
int opened; /* we opened the database */
|
||||
dav_db *db; /* if non-NULL, the lock database */
|
||||
};
|
||||
@@ -292,6 +291,19 @@
|
||||
@@ -292,6 +291,19 @@ static int dav_fs_compare_locktoken(
|
||||
return dav_compare_locktoken(lt1, lt2);
|
||||
}
|
||||
|
||||
|
|
@ -125,7 +120,7 @@ Upstream-Status: in trunk, not proposed for 2.4.x
|
|||
/*
|
||||
** dav_fs_really_open_lockdb:
|
||||
**
|
||||
@@ -300,15 +312,27 @@
|
||||
@@ -300,15 +312,27 @@ static int dav_fs_compare_locktoken(
|
||||
static dav_error * dav_fs_really_open_lockdb(dav_lockdb *lockdb)
|
||||
{
|
||||
dav_error *err;
|
||||
|
|
@ -154,7 +149,7 @@ Upstream-Status: in trunk, not proposed for 2.4.x
|
|||
return dav_push_error(lockdb->info->pool,
|
||||
HTTP_INTERNAL_SERVER_ERROR,
|
||||
DAV_ERR_LOCK_OPENDB,
|
||||
@@ -316,6 +340,10 @@
|
||||
@@ -316,6 +340,10 @@ static dav_error * dav_fs_really_open_lockdb(dav_lockdb *lockdb)
|
||||
err);
|
||||
}
|
||||
|
||||
|
|
@ -165,7 +160,7 @@ Upstream-Status: in trunk, not proposed for 2.4.x
|
|||
/* all right. it is opened now. */
|
||||
lockdb->info->opened = 1;
|
||||
|
||||
@@ -341,9 +369,9 @@
|
||||
@@ -341,9 +369,9 @@ static dav_error * dav_fs_open_lockdb(request_rec *r, int ro, int force,
|
||||
comb->pub.info = &comb->priv;
|
||||
comb->priv.r = r;
|
||||
comb->priv.pool = r->pool;
|
||||
|
|
@ -178,7 +173,7 @@ Upstream-Status: in trunk, not proposed for 2.4.x
|
|||
return dav_new_error(r->pool, HTTP_INTERNAL_SERVER_ERROR,
|
||||
DAV_ERR_LOCK_NO_DB, 0,
|
||||
"A lock database was not specified with the "
|
||||
@@ -369,8 +397,8 @@
|
||||
@@ -369,8 +397,8 @@ static dav_error * dav_fs_open_lockdb(request_rec *r, int ro, int force,
|
||||
*/
|
||||
static void dav_fs_close_lockdb(dav_lockdb *lockdb)
|
||||
{
|
||||
|
|
@ -189,8 +184,10 @@ Upstream-Status: in trunk, not proposed for 2.4.x
|
|||
}
|
||||
|
||||
/*
|
||||
--- httpd-2.4.58/modules/dav/fs/mod_dav_fs.c.r1912477+
|
||||
+++ httpd-2.4.58/modules/dav/fs/mod_dav_fs.c
|
||||
diff --git a/modules/dav/fs/mod_dav_fs.c b/modules/dav/fs/mod_dav_fs.c
|
||||
index 2389f8f..4bf6c51 100644
|
||||
--- a/modules/dav/fs/mod_dav_fs.c
|
||||
+++ b/modules/dav/fs/mod_dav_fs.c
|
||||
@@ -14,31 +14,35 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
|
@ -238,7 +235,7 @@ Upstream-Status: in trunk, not proposed for 2.4.x
|
|||
}
|
||||
|
||||
static void *dav_fs_create_server_config(apr_pool_t *p, server_rec *s)
|
||||
@@ -57,15 +61,50 @@
|
||||
@@ -57,15 +61,50 @@ static void *dav_fs_merge_server_config(apr_pool_t *p,
|
||||
|
||||
newconf->lockdb_path =
|
||||
child->lockdb_path ? child->lockdb_path : parent->lockdb_path;
|
||||
|
|
@ -272,8 +269,9 @@ Upstream-Status: in trunk, not proposed for 2.4.x
|
|||
apr_pool_t *ptemp, server_rec *base_server)
|
||||
{
|
||||
server_rec *s;
|
||||
-
|
||||
+ apr_status_t rv;
|
||||
|
||||
+
|
||||
+ /* Ignore first pass through the config. */
|
||||
+ if (ap_state_query(AP_SQ_MAIN_STATE) == AP_SQ_MS_CREATE_PRE_CONFIG)
|
||||
+ return OK;
|
||||
|
|
@ -289,7 +287,7 @@ Upstream-Status: in trunk, not proposed for 2.4.x
|
|||
for (s = base_server; s; s = s->next) {
|
||||
dav_fs_server_conf *conf;
|
||||
|
||||
@@ -74,6 +113,13 @@
|
||||
@@ -74,6 +113,13 @@ static apr_status_t dav_fs_post_config(apr_pool_t *p, apr_pool_t *plog,
|
||||
if (!conf->lockdb_path) {
|
||||
conf->lockdb_path = ap_state_dir_relative(p, DEFAULT_DAV_LOCKDB);
|
||||
}
|
||||
|
|
@ -303,7 +301,7 @@ Upstream-Status: in trunk, not proposed for 2.4.x
|
|||
}
|
||||
|
||||
return OK;
|
||||
@@ -98,19 +144,36 @@
|
||||
@@ -98,19 +144,36 @@ static const char *dav_fs_cmd_davlockdb(cmd_parms *cmd, void *config,
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
|
@ -341,8 +339,10 @@ Upstream-Status: in trunk, not proposed for 2.4.x
|
|||
dav_hook_gather_propsets(dav_fs_gather_propsets, NULL, NULL,
|
||||
APR_HOOK_MIDDLE);
|
||||
dav_hook_find_liveprop(dav_fs_find_liveprop, NULL, NULL, APR_HOOK_MIDDLE);
|
||||
--- httpd-2.4.58/modules/dav/fs/repos.h.r1912477+
|
||||
+++ httpd-2.4.58/modules/dav/fs/repos.h
|
||||
diff --git a/modules/dav/fs/repos.h b/modules/dav/fs/repos.h
|
||||
index b164611..d3a55a5 100644
|
||||
--- a/modules/dav/fs/repos.h
|
||||
+++ b/modules/dav/fs/repos.h
|
||||
@@ -25,6 +25,8 @@
|
||||
#ifndef _DAV_FS_REPOS_H_
|
||||
#define _DAV_FS_REPOS_H_
|
||||
|
|
@ -352,7 +352,7 @@ Upstream-Status: in trunk, not proposed for 2.4.x
|
|||
/* the subdirectory to hold all DAV-related information for a directory */
|
||||
#define DAV_FS_STATE_DIR ".DAV"
|
||||
#define DAV_FS_STATE_FILE_FOR_DIR ".state_for_dir"
|
||||
@@ -53,8 +55,8 @@
|
||||
@@ -53,8 +55,8 @@ dav_error * dav_fs_get_locknull_members(const dav_resource *resource,
|
||||
/* DBM functions used by the repository and locking providers */
|
||||
extern const dav_hooks_db dav_hooks_db_dbm;
|
||||
|
||||
|
|
@ -363,7 +363,7 @@ Upstream-Status: in trunk, not proposed for 2.4.x
|
|||
void dav_dbm_get_statefiles(apr_pool_t *p, const char *fname,
|
||||
const char **state1, const char **state2);
|
||||
dav_error * dav_dbm_delete(dav_db *db, apr_datum_t key);
|
||||
@@ -64,8 +66,15 @@
|
||||
@@ -64,8 +66,15 @@ void dav_dbm_freedatum(dav_db *db, apr_datum_t data);
|
||||
int dav_dbm_exists(dav_db *db, apr_datum_t key);
|
||||
void dav_dbm_close(dav_db *db);
|
||||
|
||||
|
|
@ -1,10 +1,12 @@
|
|||
|
||||
More verbose startup logging for mod_systemd.
|
||||
|
||||
--- httpd-2.4.43/modules/arch/unix/mod_systemd.c.mod_systemd
|
||||
+++ httpd-2.4.43/modules/arch/unix/mod_systemd.c
|
||||
@@ -29,11 +29,14 @@
|
||||
#include "mpm_common.h"
|
||||
diff --git a/modules/arch/unix/mod_systemd.c b/modules/arch/unix/mod_systemd.c
|
||||
index 22482fd..b46d3ef 100644
|
||||
--- a/modules/arch/unix/mod_systemd.c
|
||||
+++ b/modules/arch/unix/mod_systemd.c
|
||||
@@ -34,11 +34,14 @@
|
||||
#endif
|
||||
|
||||
#include "systemd/sd-daemon.h"
|
||||
+#include "systemd/sd-journal.h"
|
||||
|
|
@ -18,9 +20,9 @@ More verbose startup logging for mod_systemd.
|
|||
static int systemd_pre_config(apr_pool_t *pconf, apr_pool_t *plog,
|
||||
apr_pool_t *ptemp)
|
||||
{
|
||||
@@ -44,6 +47,20 @@
|
||||
return OK;
|
||||
@@ -63,6 +66,20 @@ static void log_selinux_context(void)
|
||||
}
|
||||
#endif
|
||||
|
||||
+static char *dump_listener(ap_listen_rec *lr, apr_pool_t *p)
|
||||
+{
|
||||
|
|
@ -39,21 +41,17 @@ More verbose startup logging for mod_systemd.
|
|||
/* Report the service is ready in post_config, which could be during
|
||||
* startup or after a reload. The server could still hit a fatal
|
||||
* startup error after this point during ap_run_mpm(), so this is
|
||||
@@ -51,19 +68,51 @@
|
||||
* the TCP ports so new connections will not be rejected. There will
|
||||
* always be a possible async failure event simultaneous to the
|
||||
* service reporting "ready", so this should be good enough. */
|
||||
-static int systemd_post_config(apr_pool_t *p, apr_pool_t *plog,
|
||||
+static int systemd_post_config(apr_pool_t *pconf, apr_pool_t *plog,
|
||||
@@ -73,23 +90,52 @@ static void log_selinux_context(void)
|
||||
static int systemd_post_config(apr_pool_t *pconf, apr_pool_t *plog,
|
||||
apr_pool_t *ptemp, server_rec *main_server)
|
||||
{
|
||||
+ ap_listen_rec *lr;
|
||||
+ apr_size_t plen = sizeof describe_listeners;
|
||||
+ char *p = describe_listeners;
|
||||
+
|
||||
+ if (ap_state_query(AP_SQ_MAIN_STATE) == AP_SQ_MS_CREATE_PRE_CONFIG)
|
||||
+ return OK;
|
||||
+
|
||||
if (ap_state_query(AP_SQ_MAIN_STATE) == AP_SQ_MS_CREATE_PRE_CONFIG)
|
||||
return OK;
|
||||
|
||||
+ for (lr = ap_listeners; lr; lr = lr->next) {
|
||||
+ char *s = dump_listener(lr, ptemp);
|
||||
+
|
||||
|
|
@ -74,6 +72,10 @@ More verbose startup logging for mod_systemd.
|
|||
+ }
|
||||
+ }
|
||||
+
|
||||
#ifdef HAVE_SELINUX
|
||||
log_selinux_context();
|
||||
#endif
|
||||
|
||||
sd_notify(0, "READY=1\n"
|
||||
"STATUS=Configuration loaded.\n");
|
||||
+
|
||||
101
httpd-2.4.64-separate-systemd-fns.patch
Normal file
101
httpd-2.4.64-separate-systemd-fns.patch
Normal file
|
|
@ -0,0 +1,101 @@
|
|||
diff --git a/acinclude.m4 b/acinclude.m4
|
||||
index 05abe18..97484c9 100644
|
||||
--- a/acinclude.m4
|
||||
+++ b/acinclude.m4
|
||||
@@ -631,7 +631,6 @@ case $host in
|
||||
if test "${ac_cv_header_systemd_sd_daemon_h}" = "no" || test -z "${SYSTEMD_LIBS}"; then
|
||||
AC_MSG_WARN([Your system does not support systemd.])
|
||||
else
|
||||
- APR_ADDTO(HTTPD_LIBS, [$SYSTEMD_LIBS])
|
||||
AC_DEFINE(HAVE_SYSTEMD, 1, [Define if systemd is supported])
|
||||
fi
|
||||
fi
|
||||
diff --git a/modules/arch/unix/mod_systemd.c b/modules/arch/unix/mod_systemd.c
|
||||
index af68249..7232a45 100644
|
||||
--- a/modules/arch/unix/mod_systemd.c
|
||||
+++ b/modules/arch/unix/mod_systemd.c
|
||||
@@ -40,6 +40,9 @@
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
|
||||
+APR_DECLARE_OPTIONAL_FN(int,
|
||||
+ ap_systemd_journal_stream_fd, (const char *, int, int));
|
||||
+
|
||||
static char describe_listeners[30];
|
||||
|
||||
static int systemd_pre_config(apr_pool_t *pconf, apr_pool_t *plog,
|
||||
@@ -217,10 +220,15 @@ static int ap_systemd_listen_fds(int unset_environment){
|
||||
return sd_listen_fds(unset_environment);
|
||||
}
|
||||
|
||||
+static int ap_systemd_journal_stream_fd(const char *identifier, int priority, int level_prefix){
|
||||
+ return sd_journal_stream_fd("httpd", priority, 0);
|
||||
+}
|
||||
+
|
||||
static void systemd_register_hooks(apr_pool_t *p)
|
||||
{
|
||||
APR_REGISTER_OPTIONAL_FN(ap_systemd_listen_fds);
|
||||
APR_REGISTER_OPTIONAL_FN(ap_find_systemd_socket);
|
||||
+ APR_REGISTER_OPTIONAL_FN(ap_systemd_journal_stream_fd);
|
||||
|
||||
/* Enable ap_extended_status. */
|
||||
ap_hook_pre_config(systemd_pre_config, NULL, NULL, APR_HOOK_LAST);
|
||||
diff --git a/modules/loggers/config.m4 b/modules/loggers/config.m4
|
||||
index 0848d2e..8af2299 100644
|
||||
--- a/modules/loggers/config.m4
|
||||
+++ b/modules/loggers/config.m4
|
||||
@@ -5,7 +5,6 @@ dnl APACHE_MODULE(name, helptext[, objects[, structname[, default[, config]]]])
|
||||
APACHE_MODPATH_INIT(loggers)
|
||||
|
||||
APACHE_MODULE(log_config, logging configuration. You won't be able to log requests to the server without this module., , , yes)
|
||||
-APR_ADDTO(MOD_LOG_CONFIG_LDADD, [$SYSTEMD_LIBS])
|
||||
|
||||
APACHE_MODULE(log_debug, configurable debug logging, , , most)
|
||||
APACHE_MODULE(log_forensic, forensic logging)
|
||||
diff --git a/modules/loggers/mod_log_config.c b/modules/loggers/mod_log_config.c
|
||||
index 694f447..a65b982 100644
|
||||
--- a/modules/loggers/mod_log_config.c
|
||||
+++ b/modules/loggers/mod_log_config.c
|
||||
@@ -172,10 +172,6 @@
|
||||
#include <limits.h>
|
||||
#endif
|
||||
|
||||
-#ifdef HAVE_SYSTEMD
|
||||
-#include <systemd/sd-journal.h>
|
||||
-#endif
|
||||
-
|
||||
#define DEFAULT_LOG_FORMAT "%h %l %u %t \"%r\" %>s %b"
|
||||
|
||||
module AP_MODULE_DECLARE_DATA log_config_module;
|
||||
@@ -1640,8 +1636,15 @@ static apr_status_t wrap_journal_stream(apr_pool_t *p, apr_file_t **outfd,
|
||||
{
|
||||
#ifdef HAVE_SYSTEMD
|
||||
int fd;
|
||||
+ APR_OPTIONAL_FN_TYPE(ap_systemd_journal_stream_fd) *systemd_journal_stream_fd;
|
||||
+
|
||||
+ systemd_journal_stream_fd = APR_RETRIEVE_OPTIONAL_FN(ap_systemd_journal_stream_fd);
|
||||
+ if (systemd_journal_stream_fd == NULL) {
|
||||
+ return APR_ENOTIMPL;
|
||||
+ }
|
||||
|
||||
- fd = sd_journal_stream_fd("httpd", priority, 0);
|
||||
+ fd = systemd_journal_stream_fd("httpd", priority, 0);
|
||||
+
|
||||
if (fd < 0) return fd;
|
||||
|
||||
/* This is an AF_UNIX socket fd so is more pipe-like than
|
||||
diff --git a/modules/loggers/mod_log_config.h b/modules/loggers/mod_log_config.h
|
||||
index 877a593..bd52a98 100644
|
||||
--- a/modules/loggers/mod_log_config.h
|
||||
+++ b/modules/loggers/mod_log_config.h
|
||||
@@ -69,6 +69,10 @@ APR_DECLARE_OPTIONAL_FN(ap_log_writer_init*, ap_log_set_writer_init,(ap_log_writ
|
||||
*/
|
||||
APR_DECLARE_OPTIONAL_FN(ap_log_writer*, ap_log_set_writer, (ap_log_writer* func));
|
||||
|
||||
+#ifdef HAVE_SYSTEMD
|
||||
+APR_DECLARE_OPTIONAL_FN(int, ap_systemd_journal_stream_fd, (const char *, int, int));
|
||||
+#endif
|
||||
+
|
||||
#endif /* MOD_LOG_CONFIG */
|
||||
/** @} */
|
||||
|
||||
|
|
@ -1,8 +1,8 @@
|
|||
diff --git a/modules/ssl/ssl_engine_config.c b/modules/ssl/ssl_engine_config.c
|
||||
index 27e7a53..b53f3f8 100644
|
||||
index 8fae1f8..c5dce7f 100644
|
||||
--- a/modules/ssl/ssl_engine_config.c
|
||||
+++ b/modules/ssl/ssl_engine_config.c
|
||||
@@ -119,7 +119,7 @@ static void modssl_ctx_init(modssl_ctx_t *mctx, apr_pool_t *p)
|
||||
@@ -127,7 +127,7 @@ static void modssl_ctx_init(modssl_ctx_t *mctx, apr_pool_t *p)
|
||||
mctx->ticket_key = NULL;
|
||||
#endif
|
||||
|
||||
|
|
@ -11,7 +11,7 @@ index 27e7a53..b53f3f8 100644
|
|||
mctx->protocol_set = 0;
|
||||
|
||||
mctx->pphrase_dialog_type = SSL_PPTYPE_UNSET;
|
||||
@@ -263,6 +263,7 @@ static void modssl_ctx_cfg_merge(apr_pool_t *p,
|
||||
@@ -268,6 +268,7 @@ static void modssl_ctx_cfg_merge(apr_pool_t *p,
|
||||
if (add->protocol_set) {
|
||||
mrg->protocol_set = 1;
|
||||
mrg->protocol = add->protocol;
|
||||
|
|
@ -19,20 +19,19 @@ index 27e7a53..b53f3f8 100644
|
|||
}
|
||||
else {
|
||||
mrg->protocol_set = base->protocol_set;
|
||||
|
||||
diff --git a/modules/ssl/ssl_engine_init.c b/modules/ssl/ssl_engine_init.c
|
||||
index bfad47a..b0fcf81 100644
|
||||
index 4e265b3..2fbd076 100644
|
||||
--- a/modules/ssl/ssl_engine_init.c
|
||||
+++ b/modules/ssl/ssl_engine_init.c
|
||||
@@ -577,6 +577,7 @@ static apr_status_t ssl_init_ctx_protocol(server_rec *s,
|
||||
@@ -638,6 +638,7 @@ static apr_status_t ssl_init_ctx_protocol(server_rec *s,
|
||||
MODSSL_SSL_METHOD_CONST SSL_METHOD *method = NULL;
|
||||
char *cp;
|
||||
int protocol = mctx->protocol;
|
||||
+ int protocol_set = mctx->protocol_set;
|
||||
SSLSrvConfigRec *sc = mySrvConfig(s);
|
||||
#if OPENSSL_VERSION_NUMBER >= 0x10100000L
|
||||
int prot;
|
||||
@@ -586,12 +587,18 @@ static apr_status_t ssl_init_ctx_protocol(server_rec *s,
|
||||
/* default is highest supported version, will be overridden below */
|
||||
@@ -652,12 +653,18 @@ static apr_status_t ssl_init_ctx_protocol(server_rec *s,
|
||||
* Create the new per-server SSL context
|
||||
*/
|
||||
if (protocol == SSL_PROTOCOL_NONE) {
|
||||
|
|
@ -56,7 +55,7 @@ index bfad47a..b0fcf81 100644
|
|||
#ifndef OPENSSL_NO_SSL3
|
||||
(protocol & SSL_PROTOCOL_SSLV3 ? "SSLv3, " : ""),
|
||||
#endif
|
||||
@@ -604,7 +611,8 @@ static apr_status_t ssl_init_ctx_protocol(server_rec *s,
|
||||
@@ -670,7 +677,8 @@ static apr_status_t ssl_init_ctx_protocol(server_rec *s,
|
||||
#endif
|
||||
#endif
|
||||
NULL);
|
||||
|
|
@ -66,7 +65,7 @@ index bfad47a..b0fcf81 100644
|
|||
|
||||
ap_log_error(APLOG_MARK, APLOG_TRACE3, 0, s,
|
||||
"Creating new SSL context (protocols: %s)", cp);
|
||||
@@ -705,13 +713,15 @@ static apr_status_t ssl_init_ctx_protocol(server_rec *s,
|
||||
@@ -776,13 +784,15 @@ static apr_status_t ssl_init_ctx_protocol(server_rec *s,
|
||||
prot = SSL3_VERSION;
|
||||
#endif
|
||||
} else {
|
||||
|
|
@ -88,7 +87,7 @@ index bfad47a..b0fcf81 100644
|
|||
|
||||
/* Next we scan for the minimal protocol version we should provide,
|
||||
* but we do not allow holes between max and min */
|
||||
@@ -731,7 +741,7 @@ static apr_status_t ssl_init_ctx_protocol(server_rec *s,
|
||||
@@ -806,7 +816,7 @@ static apr_status_t ssl_init_ctx_protocol(server_rec *s,
|
||||
prot = SSL3_VERSION;
|
||||
}
|
||||
#endif
|
||||
66
httpd-2.4.65-hcheck-stuck.patch
Normal file
66
httpd-2.4.65-hcheck-stuck.patch
Normal file
|
|
@ -0,0 +1,66 @@
|
|||
--- a/modules/proxy/mod_proxy_hcheck.c
|
||||
+++ b/modules/proxy/mod_proxy_hcheck.c
|
||||
@@ -989,12 +989,30 @@ static apr_status_t hc_watchdog_callback(int state
|
||||
sctx_t *ctx = (sctx_t *)data;
|
||||
server_rec *s = ctx->s;
|
||||
proxy_server_conf *conf;
|
||||
+ proxy_worker **workers;
|
||||
+ proxy_worker *worker;
|
||||
+ apr_time_t now;
|
||||
+ int i, n;
|
||||
|
||||
+ conf = (proxy_server_conf *) ap_get_module_config(s->module_config, &proxy_module);
|
||||
+ balancer = (proxy_balancer *)conf->balancers->elts;
|
||||
+
|
||||
switch (state) {
|
||||
case AP_WATCHDOG_STATE_STARTING:
|
||||
ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, s, APLOGNO(03258)
|
||||
"%s watchdog started.",
|
||||
HCHECK_WATHCHDOG_NAME);
|
||||
+ /* set last update time for all workers */
|
||||
+ now = apr_time_now();
|
||||
+ for (i = 0; i < conf->balancers->nelts; i++, balancer++) {
|
||||
+ workers = (proxy_worker **)balancer->workers->elts;
|
||||
+ for (n = 0; n < balancer->workers->nelts; n++, ++workers) {
|
||||
+ worker = *workers;
|
||||
+ if (worker->s->updated == 0) {
|
||||
+ worker->s->updated = now;
|
||||
+ }
|
||||
+ }
|
||||
+ }
|
||||
#if HC_USE_THREADS
|
||||
if (tpsize && hctp == NULL) {
|
||||
rv = apr_thread_pool_create(&hctp, tpsize,
|
||||
@@ -1020,21 +1038,13 @@ static apr_status_t hc_watchdog_callback(int state
|
||||
|
||||
case AP_WATCHDOG_STATE_RUNNING:
|
||||
/* loop thru all workers */
|
||||
- if (s) {
|
||||
- int i;
|
||||
- conf = (proxy_server_conf *) ap_get_module_config(s->module_config, &proxy_module);
|
||||
- balancer = (proxy_balancer *)conf->balancers->elts;
|
||||
- ctx->s = s;
|
||||
+ {
|
||||
+ now = apr_time_now();
|
||||
for (i = 0; i < conf->balancers->nelts; i++, balancer++) {
|
||||
- int n;
|
||||
- apr_time_t now;
|
||||
- proxy_worker **workers;
|
||||
- proxy_worker *worker;
|
||||
/* Have any new balancers or workers been added dynamically? */
|
||||
ap_proxy_sync_balancer(balancer, s, conf);
|
||||
workers = (proxy_worker **)balancer->workers->elts;
|
||||
- now = apr_time_now();
|
||||
- for (n = 0; n < balancer->workers->nelts; n++) {
|
||||
+ for (n = 0; n < balancer->workers->nelts; n++, workers++) {
|
||||
worker = *workers;
|
||||
if (!PROXY_WORKER_IS(worker, PROXY_WORKER_STOPPED) &&
|
||||
(worker->s->method != NONE) &&
|
||||
@@ -1074,7 +1084,6 @@ static apr_status_t hc_watchdog_callback(int state
|
||||
hc_check(NULL, baton);
|
||||
}
|
||||
}
|
||||
- workers++;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -33,7 +33,7 @@ sscg -q \
|
|||
--cert-file /etc/pki/tls/certs/localhost.crt \
|
||||
--cert-key-file /etc/pki/tls/private/localhost.key \
|
||||
--ca-file /etc/pki/tls/certs/localhost.crt \
|
||||
--dhparams-file /tmp/dhparams.pem \
|
||||
--no-dhparams-file \
|
||||
--lifetime 365 \
|
||||
--hostname $FQDN \
|
||||
--email root@$FQDN
|
||||
|
|
|
|||
26
httpd.conf
26
httpd.conf
|
|
@ -151,7 +151,7 @@ DocumentRoot "/var/www/html"
|
|||
#
|
||||
# AllowOverride controls what directives may be placed in .htaccess files.
|
||||
# It can be "All", "None", or any combination of the keywords:
|
||||
# Options FileInfo AuthConfig Limit
|
||||
# AllowOverride FileInfo AuthConfig Limit
|
||||
#
|
||||
AllowOverride None
|
||||
|
||||
|
|
@ -199,6 +199,7 @@ LogLevel warn
|
|||
# a CustomLog directive (see below).
|
||||
#
|
||||
LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined
|
||||
LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\" PID: %P %{tid}P %T" combined_ext
|
||||
LogFormat "%h %l %u %t \"%r\" %>s %b" common
|
||||
|
||||
<IfModule logio_module>
|
||||
|
|
@ -216,10 +217,11 @@ LogLevel warn
|
|||
#CustomLog "logs/access_log" common
|
||||
|
||||
#
|
||||
# If you prefer a logfile with access, agent, and referer information
|
||||
# (Combined Logfile Format) you can use the following directive.
|
||||
# If you prefer a logfile with access, agent, referer, and process/thread
|
||||
# information (an extended Combined Logfile Format), you can use the
|
||||
# following directive.
|
||||
#
|
||||
CustomLog "logs/access_log" combined
|
||||
CustomLog "logs/access_log" combined_ext
|
||||
</IfModule>
|
||||
|
||||
<IfModule alias_module>
|
||||
|
|
@ -263,6 +265,15 @@ LogLevel warn
|
|||
Require all granted
|
||||
</Directory>
|
||||
|
||||
<IfModule headers_module>
|
||||
#
|
||||
# Avoid passing HTTP_PROXY environment to CGI's on this or any proxied
|
||||
# backend servers which have lingering "httpoxy" defects.
|
||||
# 'Proxy' request header is undefined by the IETF, not listed by IANA
|
||||
#
|
||||
RequestHeader unset Proxy early
|
||||
</IfModule>
|
||||
|
||||
<IfModule mime_module>
|
||||
#
|
||||
# TypesConfig points to the file containing the list of mappings from
|
||||
|
|
@ -340,6 +351,13 @@ AddDefaultCharset UTF-8
|
|||
#ErrorDocument 402 http://www.example.com/subscription_info.html
|
||||
#
|
||||
|
||||
#
|
||||
# MaxRanges: Maximum number of Ranges in a request before
|
||||
# returning the entire resource, or one of the special
|
||||
# values 'default', 'none' or 'unlimited'.
|
||||
# Default setting is to accept 200 Ranges.
|
||||
#MaxRanges unlimited
|
||||
|
||||
#
|
||||
# EnableMMAP and EnableSendfile: On systems that support it,
|
||||
# memory-mapping or the sendfile syscall may be used to deliver
|
||||
|
|
|
|||
|
|
@ -241,6 +241,11 @@
|
|||
<filename>/etc/httpd/conf.modules.d</filename>
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
<refsect1>
|
||||
<title>Reporting Bugs</title>
|
||||
<para>Please report bugs by filing an issue in @BUG_REPORT_URL@.</para>
|
||||
</refsect1>
|
||||
|
||||
<refsect1>
|
||||
<title>See also</title>
|
||||
|
|
|
|||
|
|
@ -233,8 +233,8 @@ Wants=network-online.target</programlisting>
|
|||
|
||||
<para>The <command>httpd.service</command> unit enables a
|
||||
variety of sandboxing options. Many of these prevent the service
|
||||
from changing the system configuration - such as
|
||||
<emphasis>ProtectClock</emphasis> and
|
||||
from changing the system configuration or attributes of the
|
||||
kernel - such as <emphasis>ProtectClock</emphasis> and
|
||||
<emphasis>ProtectKernelModules</emphasis>. See
|
||||
<citerefentry><refentrytitle>systemd.exec</refentrytitle><manvolnum>5</manvolnum></citerefentry>
|
||||
and
|
||||
|
|
@ -262,6 +262,13 @@ Wants=network-online.target</programlisting>
|
|||
<emphasis>UserDir</emphasis> will not be able modify any
|
||||
content in <filename>/home</filename> by
|
||||
default.</para></listitem>
|
||||
|
||||
<listitem><para><emphasis>ProtectSystem</emphasis> is set to
|
||||
<emphasis>yes</emphasis> by default; this mounts various
|
||||
system paths like <filename>/usr</filename> and
|
||||
<filename>/boot</filename> as read-only by
|
||||
default.</para></listitem>
|
||||
|
||||
</itemizedlist></para>
|
||||
|
||||
</refsect2>
|
||||
|
|
@ -361,7 +368,12 @@ ReloadPropagatedFrom=httpd.service</programlisting>
|
|||
<filename>/usr/lib/systemd/system/httpd@.service</filename>,
|
||||
<filename>/etc/systemd/systemd/httpd.service.d</filename></para>
|
||||
</refsect1>
|
||||
|
||||
|
||||
<refsect1>
|
||||
<title>Reporting Bugs</title>
|
||||
<para>Please report bugs by filing an issue in @BUG_REPORT_URL@.</para>
|
||||
</refsect1>
|
||||
|
||||
<refsect1>
|
||||
<title>See also</title>
|
||||
|
||||
|
|
|
|||
152
httpd.spec
152
httpd.spec
|
|
@ -4,6 +4,7 @@
|
|||
%define mmn 20120211
|
||||
%define mmnisa %{mmn}%{__isa_name}%{__isa_bits}
|
||||
%define vstring %(source /etc/os-release; echo ${NAME})
|
||||
%define bugurl %(source /etc/os-release; echo ${BUG_REPORT_URL})
|
||||
%if 0%{?fedora} > 26 || 0%{?rhel} > 7
|
||||
%global mpm event
|
||||
%else
|
||||
|
|
@ -18,13 +19,19 @@
|
|||
%bcond_without pcre
|
||||
%endif
|
||||
|
||||
%if 0%{?fedora} > 40 || 0%{?rhel} > 9
|
||||
%bcond_with engine
|
||||
%else
|
||||
%bcond_without engine
|
||||
%endif
|
||||
|
||||
# Similar issue to https://bugzilla.redhat.com/show_bug.cgi?id=2043092
|
||||
%undefine _package_note_flags
|
||||
|
||||
Summary: Apache HTTP Server
|
||||
Name: httpd
|
||||
Version: 2.4.59
|
||||
Release: 2%{?dist}
|
||||
Version: 2.4.66
|
||||
Release: 1%{?dist}
|
||||
URL: https://httpd.apache.org/
|
||||
Source0: https://www.apache.org/dist/httpd/httpd-%{version}.tar.bz2
|
||||
Source1: https://www.apache.org/dist/httpd/httpd-%{version}.tar.bz2.asc
|
||||
|
|
@ -82,26 +89,21 @@ Patch3: httpd-2.4.43-deplibs.patch
|
|||
Patch19: httpd-2.4.53-detect-systemd.patch
|
||||
# Features/functional changes
|
||||
Patch20: httpd-2.4.48-r1842929+.patch
|
||||
Patch21: httpd-2.4.43-mod_systemd.patch
|
||||
Patch21: httpd-2.4.64-mod_systemd.patch
|
||||
Patch22: httpd-2.4.53-export.patch
|
||||
Patch23: httpd-2.4.43-corelimit.patch
|
||||
Patch24: httpd-2.4.59-gettid.patch
|
||||
Patch25: httpd-2.4.54-icons.patch
|
||||
Patch26: httpd-2.4.43-cachehardmax.patch
|
||||
Patch27: httpd-2.4.43-socket-activation.patch
|
||||
Patch28: httpd-2.4.43-sslciphdefault.patch
|
||||
Patch29: httpd-2.4.43-sslprotdefault.patch
|
||||
Patch31: httpd-2.4.59-unifycgid.patch
|
||||
Patch32: httpd-2.4.43-logjournal.patch
|
||||
Patch33: httpd-2.4.53-separate-systemd-fns.patch
|
||||
Patch34: httpd-2.4.58-r1912477+.patch
|
||||
Patch36: httpd-2.4.58-r1914365.patch
|
||||
Patch37: httpd-2.4.54-selinux.patch
|
||||
Patch24: httpd-2.4.54-icons.patch
|
||||
Patch25: httpd-2.4.43-cachehardmax.patch
|
||||
Patch26: httpd-2.4.43-sslciphdefault.patch
|
||||
Patch27: httpd-2.4.64-sslprotdefault.patch
|
||||
Patch28: httpd-2.4.43-logjournal.patch
|
||||
Patch29: httpd-2.4.63-r1912477+.patch
|
||||
Patch30: httpd-2.4.64-separate-systemd-fns.patch
|
||||
|
||||
# Bug fixes
|
||||
# https://bugzilla.redhat.com/show_bug.cgi?id=1397243
|
||||
Patch60: httpd-2.4.43-enable-sslv3.patch
|
||||
Patch61: httpd-2.4.59-r1916863.patch
|
||||
Patch61: httpd-2.4.65-hcheck-stuck.patch
|
||||
|
||||
# Security fixes
|
||||
# Patch200: ...
|
||||
|
|
@ -116,7 +118,9 @@ BuildRequires: gcc, autoconf, pkgconfig, findutils, xmlto
|
|||
BuildRequires: perl-interpreter, perl-generators, systemd-devel
|
||||
BuildRequires: zlib-devel, libselinux-devel, lua-devel, brotli-devel
|
||||
BuildRequires: apr-devel >= 1.5.0, apr-util-devel >= 1.5.0
|
||||
BuildRequires: openldap-devel
|
||||
BuildRequires: systemd-rpm-macros
|
||||
BuildRequires: libxcrypt-devel
|
||||
%if %{with pcre2}
|
||||
BuildRequires: pcre2-devel
|
||||
%endif
|
||||
|
|
@ -150,6 +154,14 @@ Conflicts: apr < 1.5.0-1
|
|||
Conflicts: httpd < 2.4.53-2
|
||||
Obsoletes: mod_proxy_uwsgi < 2.0.17.1-2
|
||||
|
||||
# Compat symlinks for Requires in other packages.
|
||||
%if "%{_sbindir}" == "%{_bindir}"
|
||||
# We rely on filesystem to create the symlink for us.
|
||||
Requires: filesystem(unmerged-sbin-symlinks)
|
||||
Provides: /usr/sbin/apachectl
|
||||
Provides: /usr/sbin/httpd
|
||||
%endif
|
||||
|
||||
%description core
|
||||
The httpd-core package contains essential httpd binaries.
|
||||
|
||||
|
|
@ -258,6 +270,12 @@ sed -i '/^#define PLATFORM/s/Unix/%{vstring}/' os/unix/os.h
|
|||
# Prevent use of setcap in "install-suexec-caps" target.
|
||||
sed -i '/suexec/s,setcap ,echo Skipping setcap for ,' Makefile.in
|
||||
|
||||
%if %{without engine}
|
||||
: Forcibly disable ENGINE support in mod_ssl
|
||||
sed -i.engine '/^#define MODSSL_HAVE_ENGINE_API/{s/1/0/}' modules/ssl/ssl_private.h
|
||||
! diff -u modules/ssl/ssl_private.h{.engine,}
|
||||
%endif
|
||||
|
||||
# Example conf for instances
|
||||
cp $RPM_SOURCE_DIR/instance.conf .
|
||||
sed < $RPM_SOURCE_DIR/httpd.conf >> instance.conf '
|
||||
|
|
@ -283,23 +301,20 @@ cp %{SOURCE48} ./docs/icons/apache_pb3.png
|
|||
# Provide default layout
|
||||
cp $RPM_SOURCE_DIR/config.layout .
|
||||
|
||||
sed '
|
||||
for f in httpd.conf htcacheclean.service httpd.service apachectl; do
|
||||
sed '
|
||||
s,@MPM@,%{mpm},g
|
||||
s,@DOCROOT@,%{docroot},g
|
||||
s,@LOGDIR@,%{_localstatedir}/log/httpd,g
|
||||
' < $RPM_SOURCE_DIR/httpd.conf.xml \
|
||||
> httpd.conf.xml
|
||||
|
||||
xmlto man ./httpd.conf.xml
|
||||
xmlto man $RPM_SOURCE_DIR/htcacheclean.service.xml
|
||||
xmlto man $RPM_SOURCE_DIR/httpd.service.xml
|
||||
|
||||
# apachectl.xml => apachectl.8
|
||||
xmlto man %{SOURCE47}
|
||||
s|@BUG_REPORT_URL@|%{bugurl}|g
|
||||
' < $RPM_SOURCE_DIR/${f}.xml > ${f}.xml
|
||||
xmlto man ${f}.xml
|
||||
done
|
||||
|
||||
: Building with MMN %{mmn}, MMN-ISA %{mmnisa}
|
||||
: Default MPM is %{mpm}, vendor string is '%{vstring}'
|
||||
: Regex Engine: PCRE=%{with pcre} PCRE2=%{with pcre2}
|
||||
: mod_ssl ENGINE support: %{with engine}
|
||||
|
||||
%build
|
||||
# forcibly prevent use of bundled apr, apr-util, pcre
|
||||
|
|
@ -722,7 +737,8 @@ exit $rv
|
|||
%dir %{_libexecdir}/initscripts/legacy-actions/httpd
|
||||
%{_libexecdir}/initscripts/legacy-actions/httpd/*
|
||||
|
||||
%{_sbindir}/ht*
|
||||
%{_sbindir}/httpd
|
||||
%{_sbindir}/htcacheclean
|
||||
%{_sbindir}/fcgistarter
|
||||
%{_sbindir}/apachectl
|
||||
%{_sbindir}/rotatelogs
|
||||
|
|
@ -775,7 +791,12 @@ exit $rv
|
|||
%{_sysusersdir}/httpd.conf
|
||||
|
||||
%files tools
|
||||
%{_bindir}/*
|
||||
%{_bindir}/ab
|
||||
%{_bindir}/htdbm
|
||||
%{_bindir}/htdigest
|
||||
%{_bindir}/httxt2dbm
|
||||
%{_bindir}/htpasswd
|
||||
%{_bindir}/logresolve
|
||||
%{_mandir}/man1/*
|
||||
%doc LICENSE NOTICE
|
||||
%exclude %{_bindir}/apxs
|
||||
|
|
@ -825,6 +846,81 @@ exit $rv
|
|||
%{_rpmconfigdir}/macros.d/macros.httpd
|
||||
|
||||
%changelog
|
||||
* Tue Dec 09 2025 Luboš Uhliarik <luhliari@redhat.com> - 2.4.66-1
|
||||
- new version 2.4.66
|
||||
|
||||
* Thu Nov 27 2025 Luboš Uhliarik <luhliari@redhat.com> - 2.4.65-5
|
||||
- Improve default httpd LogFormats for better support diagnostics
|
||||
|
||||
* Wed Nov 12 2025 Luboš Uhliarik <luhliari@redhat.com> - 2.4.65-3
|
||||
- mod_ssl: SSLVHostSNIPolicy - Fix handling of STRICT mode
|
||||
|
||||
* Tue Nov 04 2025 Luboš Uhliarik <luhliari@redhat.com> - 2.4.65-2
|
||||
- mod_ssl: Add SSLVHostSNIPolicy directive to set the compatibility level
|
||||
required for VirtualHost matching.
|
||||
|
||||
* Sat Oct 18 2025 Luboš Uhliarik <luhliari@redhat.com> - 2.4.65-1
|
||||
- new version 2.4.65
|
||||
- mod_proxy_hcheck: reschedule health checks after child process restart
|
||||
|
||||
* Mon Sep 08 2025 Luboš Uhliarik <luhliari@redhat.com> - 2.4.64-4
|
||||
- Add tmpfiles.d rules for /var directories (bootc compatibility)
|
||||
|
||||
* Thu Jul 24 2025 Fedora Release Engineering <releng@fedoraproject.org> - 2.4.64-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild
|
||||
|
||||
* Thu Jul 17 2025 Luboš Uhliarik <luhliari@redhat.com> - 2.4.64-2
|
||||
- Fix RewriteRule with inverted pattern and RewriteCond regression
|
||||
|
||||
* Fri Jul 11 2025 Luboš Uhliarik <luhliari@redhat.com> - 2.4.64-1
|
||||
- new version 2.4.64
|
||||
|
||||
* Tue Jun 24 2025 Joe Orton <jorton@redhat.com> - 2.4.63-4
|
||||
- mod_dav: add dav_get_base_path() API
|
||||
|
||||
* Mon Feb 10 2025 Joe Orton <jorton@redhat.com> - 2.4.63-3
|
||||
- sync default httpd.conf with upstream
|
||||
|
||||
* Sat Feb 01 2025 Björn Esser <besser82@fedoraproject.org> - 2.4.63-2
|
||||
- Add explicit BR: libxcrypt-devel
|
||||
|
||||
* Fri Jan 24 2025 Luboš Uhliarik <luhliari@redhat.com> - 2.4.63-1
|
||||
- new version 2.4.63
|
||||
|
||||
* Fri Jan 17 2025 Fedora Release Engineering <releng@fedoraproject.org> - 2.4.62-6
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild
|
||||
|
||||
* Sun Jan 12 2025 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 2.4.62-5
|
||||
- Rebuilt for the bin-sbin merge (2nd attempt)
|
||||
|
||||
* Fri Oct 11 2024 Luboš Uhliarik <luhliari@redhat.com> - 2.4.62-4
|
||||
- mod_rewrite: regression fixes
|
||||
|
||||
* Thu Aug 01 2024 Luboš Uhliarik <luhliari@redhat.com> - 2.4.62-3
|
||||
- Fix regression introduced by CVE-2024-38474 fix
|
||||
- added openldap-devel build dependency
|
||||
|
||||
* Fri Jul 19 2024 Luboš Uhliarik <luhliari@redhat.com> - 2.4.62-1
|
||||
- new version 2.4.62
|
||||
|
||||
* Thu Jul 18 2024 Fedora Release Engineering <releng@fedoraproject.org> - 2.4.61-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild
|
||||
|
||||
* Tue Jul 09 2024 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 2.4.61-2
|
||||
- Rebuilt for the bin-sbin merge
|
||||
|
||||
* Wed Jul 03 2024 Luboš Uhliarik <luhliari@redhat.com> - 2.4.61-1
|
||||
- new version 2.4.61
|
||||
|
||||
* Thu May 23 2024 Joe Orton <jorton@redhat.com> - 2.4.59-4
|
||||
- mod_ssl: add engine bcond, disable ENGINE support by default for F41+
|
||||
- mod_ssl: enable SSL_OP_NO_RENEGOTIATION (upstream PR#426)
|
||||
|
||||
* Fri May 3 2024 Joe Orton <jorton@redhat.com> - 2.4.59-3
|
||||
- apachectl(8): use BUG_REPORT_URL from /etc/os-release
|
||||
- apachectl(8): fix grammar (#2278748)
|
||||
- httpd.service.xml(8): mention ProtectSystem= setting
|
||||
|
||||
* Mon Apr 15 2024 Joe Orton <jorton@redhat.com> - 2.4.59-2
|
||||
- mod_ssl: add DH param handling fix (r1916863)
|
||||
|
||||
|
|
|
|||
|
|
@ -1,2 +1,9 @@
|
|||
d /run/httpd 710 root apache
|
||||
d /run/httpd/htcacheclean 700 apache apache
|
||||
d /var/log/httpd 700 root root -
|
||||
d /var/www 755 root root -
|
||||
d /var/www/html 755 root root -
|
||||
d /var/www/cgi-bin 755 root root -
|
||||
d /var/lib/httpd 700 apache apache -
|
||||
d /var/cache/httpd 700 apache apache -
|
||||
d /var/cache/httpd/proxy 700 apache apache -
|
||||
|
|
|
|||
|
|
@ -6,8 +6,8 @@ if [ $# -lt 1 ]; then
|
|||
fi
|
||||
|
||||
repo="https://svn.apache.org/repos/asf/httpd/httpd/trunk"
|
||||
#repo="https://svn.apache.org/repos/asf/httpd/httpd/branches/2.4.x"
|
||||
ver=2.4.59
|
||||
repo="https://svn.apache.org/repos/asf/httpd/httpd/branches/2.4.x"
|
||||
ver=$(rpm -q --specfile httpd.spec --qf '%{VERSION}\n' | sed 1q)
|
||||
prefix="httpd-${ver}"
|
||||
suffix="${SUFFIX:-r$1${2:++}}"
|
||||
fn="${prefix}-${suffix}.patch"
|
||||
|
|
@ -64,4 +64,3 @@ echo "+ git add ${fn}"
|
|||
git add "${fn}"
|
||||
echo "+ spec template:"
|
||||
echo "PatchN: ${fn}"
|
||||
echo "%patch -PN -p1 -b .${suffix}"
|
||||
|
|
|
|||
4
sources
4
sources
|
|
@ -1,3 +1,3 @@
|
|||
SHA512 (httpd-2.4.66.tar.bz2) = 49031a3465d956ee3b755e65810b6c35561ddd5fac2c624a273b733c238e115b914cd7b246837e5a3090ccfded6e0b8b3059bfd1f8ce4419081c805a38d05a4b
|
||||
SHA512 (httpd-2.4.66.tar.bz2.asc) = 3fc7a4c6c0705adc3f8223ed3d6ebc45f09b7a19ab63a8b4d359835d2b592cf11f0fd0438a40b5a43c0684b36602484bb908bf46b0c068dd22bacc2c194e7fbd
|
||||
SHA512 (KEYS) = 88c848b7ab9e4915d6625dcad3e8328673b0448f2ce76f2c44eecc612cf6afbce3287a4ee7219a44c6fcc61d5ecb2a1a8545456a4a16b90400263d7249cbf192
|
||||
SHA512 (httpd-2.4.59.tar.bz2) = 209da0bbac5e2564d4590302515b35495be6402273ff4024aa93e85e44554c95e053201d606383936425a41e1b5b97e6b40055dcbb385eb691a5029a6f3158c2
|
||||
SHA512 (httpd-2.4.59.tar.bz2.asc) = 85237e204e57d930e2b7a85a21f8d593e81895f96350c3a345978538a536f3c0614ba89256905c0aa558880fc6fb10608b8dd7cbd026af326b1d83601c267f2d
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue