From nobody Thu Oct 26 11:02:25 2023 X-Original-To: dev-commits-ports-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4SGNDL0dvzz4xfj4; Thu, 26 Oct 2023 11:02:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4SGNDL0B5Kz3Tdp; Thu, 26 Oct 2023 11:02:26 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1698318146; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=HCslXnm4fB04pmK12hYPukbX2LGbhAkYoyrkibHFhts=; b=E52ezdOjE4WYWN092TSTksyqoKdDaW2iAmU8sFl2x15m3a9lUoqUhxnZPvcwTF/tF7tggP YW1IaT4nzhkcinB7/VQd4d+0AuLrxXl+RQHR90qel8NBVMMR9wYXK65kzYfXUiyQm2rwdG HwO7V2k6CqvSfEN5CgJxbRs49GB5zYIcXKhFDlaUWyT2hgRbW35Ino+K/dcXFNd6PNARE5 GhKgAdxm2TnXyz2cFGSJf06dchBtcBAvdezTJ/avxH8oiPL5iW3Exj8arYWb//Hh45WD8d zx8End+hyZixOcok2pyDw+r+IOfUk22ggYwe4/QqBNG+yKHSlZJpm+djaVCSmw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1698318146; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=HCslXnm4fB04pmK12hYPukbX2LGbhAkYoyrkibHFhts=; b=iIxpObEPFHZgKoUZBOXqDWlci982bdZzDDus82PykZ2rBe0WAuNOPTIrxqkbXMwE2nHHya yfms9HkkTDjMQiNFo6qMrQeVhxLCaDEc+/o2KiHYF1M0p5WSJWl2mAXDJ9kWz33Aiigu3O rhXzhqtrrV5FwR3DCdaP7y49fLDc+2E7HkBF0s/ukTV/QNrPaLdu7SBDrOZur/84eg+7GE C/N8Zv9NGKxPUXs0pGQuqMVJMIXzy3ocqPFYakPEQ9V+LOk75drBNp7Ek6pPyfgUbQzbQC hio1naPajd4EgsgTFATEa1Ap7DBDJ+CoJ3C7O3YUtOX+kKwy2ciBghlQQjRSAA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1698318146; a=rsa-sha256; cv=none; b=X+AZZpBzbeQsH9UWQYPYnibM9re7tacaJmYA8slCEo1kyWffZSRmqf1M1R9HwG9chISWMp eU+rzoBaRPCBIUTxNZmtJO7wQhEEnptuq47U6sH9NdPBnxm7Ht+Lx37GT9gAv3wV5NoDo3 uer2CvZhUDvQPF42bSxJnJOTFhq3H1kzQFjs7FbJ52HfDfLyeXgmTY9TUkPgQavKCKDan4 HNc6b3WHajLM4cqGs8ZUNtXK3JLTu6mYhx8EJXz2TGX9PkbfAIG0WbJo65VZtxhjmMglPd PPXnF/pNl6rRstohwNRFCpeXAntIgijX6kz9j2I+rLQGHLB/D+9yj83ylXd4Ww== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4SGNDK6MPCzTsN; Thu, 26 Oct 2023 11:02:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 39QB2Pjm037896; Thu, 26 Oct 2023 11:02:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 39QB2Pej037893; Thu, 26 Oct 2023 11:02:25 GMT (envelope-from git) Date: Thu, 26 Oct 2023 11:02:25 GMT Message-Id: <202310261102.39QB2Pej037893@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-branches@FreeBSD.org From: Vladimir Druzenko Subject: git: deef0db3f363 - 2023Q4 - www/apache24: workaround for bug "opcache + ASLR turned on crashes Apache if used www/mod_php8{0,1,2,3}" List-Id: Commit messages for all branches of the ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-ports-all@freebsd.org X-BeenThere: dev-commits-ports-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: vvd X-Git-Repository: ports X-Git-Refname: refs/heads/2023Q4 X-Git-Reftype: branch X-Git-Commit: deef0db3f36352c1fa22fd9eb168cb4621623a42 Auto-Submitted: auto-generated The branch 2023Q4 has been updated by vvd: URL: https://cgit.FreeBSD.org/ports/commit/?id=deef0db3f36352c1fa22fd9eb168cb4621623a42 commit deef0db3f36352c1fa22fd9eb168cb4621623a42 Author: Vladimir Druzenko AuthorDate: 2023-10-26 10:55:24 +0000 Commit: Vladimir Druzenko CommitDate: 2023-10-26 11:02:16 +0000 www/apache24: workaround for bug "opcache + ASLR turned on crashes Apache if used www/mod_php8{0,1,2,3}" PR: 268318 Approved by: joneum (apache@), tcberner (mentor) MFH: 2023Q4 (cherry picked from commit 688bfd0c38351f28306d7bca5a8ceb280bee53d9) --- www/apache24/Makefile | 1 + www/apache24/files/apache24.in | 12 ++++++++++++ 2 files changed, 13 insertions(+) diff --git a/www/apache24/Makefile b/www/apache24/Makefile index d6ef3d1fb496..f82c2f351055 100644 --- a/www/apache24/Makefile +++ b/www/apache24/Makefile @@ -1,5 +1,6 @@ PORTNAME= apache24 PORTVERSION= 2.4.58 +PORTREVISION= 1 CATEGORIES= www MASTER_SITES= APACHE_HTTPD DISTNAME= httpd-${PORTVERSION} diff --git a/www/apache24/files/apache24.in b/www/apache24/files/apache24.in index a6693381211b..0b9c4bd55ba6 100644 --- a/www/apache24/files/apache24.in +++ b/www/apache24/files/apache24.in @@ -22,6 +22,8 @@ # module on start up and load if not loaded. # apache24_fib (str): Set an altered default network view for apache # apache24_configcheck_disable (bool): Set to "YES" to disable sanity check on startup +# apache24_aslr_disable (bool): Set to "YES" to disable ASLR (Address Space Layout +# Randomization): workaround for PR#268318 . /etc/rc.subr @@ -46,6 +48,7 @@ envvars="%%PREFIX%%/sbin/envvars" [ -z "$apache24limits_args" ] && apache24limits_args="-e -C daemon" [ -z "$apache24_http_accept_enable" ] && apache24_http_accept_enable="NO" [ -z "$apache24_configcheck_disable" ] && apache24_configcheck_disable="NO" +[ -z "$apache24_aslr_disable" ] && apache24_aslr_disable="NO" apache24_accf() { @@ -76,6 +79,7 @@ if [ -n "$2" ]; then eval apache24limits_args="\${apache24limits_${profile}_args:-${apache24limits_args}}" eval apache24_fib="\${apache24_${profile}_fib:-${apache24_fib}}" eval apache24_configcheck_disable="\${apache24_${profile}_configcheck_disable:-${apache24_configcheck_disable}}" + eval apache24_aslr_disable="\${apache24_${profile}_aslr_disable:-${apache24_aslr_disable}}" eval command="\${apache24_${profile}_command:-${command}}" eval pidfile="\${apache24_${profile}_pidfile:-${pidfile}}" eval apache24_envvars="\${apache24_${profile}_envvars:-${envvars}}" @@ -189,6 +193,13 @@ apache24_precmd() } +apache24_checkalsr () { + if checkyesno apache24_aslr_disable + then + command="/usr/bin/proccontrol -m aslr -s disable ${command}" + fi +} + apache24_checkfib () { if command -v check_namevarlist > /dev/null 2>&1; then check_namevarlist fib && return 0 @@ -206,6 +217,7 @@ apache24_checkfib () { } apache24_prestart() { + apache24_checkalsr apache24_checkfib apache24_precmd }