From nobody Wed Jun 15 07:28:33 2022 X-Original-To: freebsd-stable@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 CB17F8523AF for ; Wed, 15 Jun 2022 07:28:45 +0000 (UTC) (envelope-from wma@semihalf.com) Received: from mail-yb1-xb35.google.com (mail-yb1-xb35.google.com [IPv6:2607:f8b0:4864:20::b35]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1D4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4LNH3d0nZKz4lwR for ; Wed, 15 Jun 2022 07:28:45 +0000 (UTC) (envelope-from wma@semihalf.com) Received: by mail-yb1-xb35.google.com with SMTP id r82so18953583ybc.13 for ; Wed, 15 Jun 2022 00:28:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=semihalf.com; s=google; h=mime-version:from:date:message-id:subject:to; bh=eMTOWGhT3VuEqBgoRMjo1qHNidwx2Ir80Q05rvH7En8=; b=nLMjJuPW+gYxYH94FVlP13aqCXVCKPLIhU7i7ZtmlLxvB0TdH0u0+CoZdPJ72hs3A8 H6+5j1LBdZfuDHm3Ki3yfTptu1HJS3uD0DbPW5BGNw40pixVR1nrQBD20xm0pJEIgFRa fn5XJrHtB9HC7IZ2NuinMTz1N9n4QnXOch2Isan8tQnJJpaSK5r3omzmC2JHuY1anhze BS/MOM92Jzg0e/p9Lj9fYvWMj/XSOse5y/kDKAAkxsGIlWZaAXxs9XMX2dD2tz9M6AJu dDO7Achvn24QpcTQWU/qWsjt/eoYjs7R1xL0R0942dVoPDa4OmFuQCKrYkisaKCyzTpy DGFA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=eMTOWGhT3VuEqBgoRMjo1qHNidwx2Ir80Q05rvH7En8=; b=Q0H8iXUkIDFQdaItaLV1TDYc7Bl3kjEvXq78q1zcUveYxvr8rvA2Rb1dYfZZRFzUfd +zbztVw67GlkHVDG0MkJ3QbvymxvilANUkSHtx8herwduB3nAAMZJJAx73rYaT+E7nMd cNio8c8yYnMytnhpWPmbaXHZLRjAUNWzx+Wr5qOnl/cnauwV0PJSX/lWgRKnNJfW4awo +D5FdcCXTdxqeDEK9n/JshiCJCLV5K/K5qh65LrvtkMSFatmp8mIJbw9ex+lU+rfjAR6 kCqvg0F4QoPFVDvWertBaSCp9xYsIfBWRuZiI/jrTHkp2t9NQVC2SN1BH9SPDq4Zxblw Bxcw== X-Gm-Message-State: AJIora8xe6AiNMEgosOShfoQLcWQ/kmlG7fnsRgWGPgdVEyBFMjZ52s0 4tmBmnjxqnhRSxwMr/qIgkom2/7ItC4hZeHUcO3n8nZ0Fj3KJA== X-Google-Smtp-Source: AGRyM1slq7BwYlz/oO+GNk7Z554Qh1jhkrOA1k9ACoov5IynPgh8NWAvOA+8mj6D0ZjQIXYnAYbuOpbUBkxp+cQ8LgU= X-Received: by 2002:a05:6902:4e9:b0:65c:d03b:571d with SMTP id w9-20020a05690204e900b0065cd03b571dmr8923314ybs.326.1655278124478; Wed, 15 Jun 2022 00:28:44 -0700 (PDT) List-Id: Production branch of FreeBSD source code List-Archive: https://lists.freebsd.org/archives/freebsd-stable List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-stable@freebsd.org X-BeenThere: freebsd-stable@freebsd.org MIME-Version: 1.0 From: Wojciech Macek Date: Wed, 15 Jun 2022 09:28:33 +0200 Message-ID: Subject: Re: Issue with php81-extensions and aslr FreeBSD To: freebsd-stable@freebsd.org Content-Type: multipart/alternative; boundary="0000000000009d4b4705e1777804" X-Rspamd-Queue-Id: 4LNH3d0nZKz4lwR X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=semihalf.com header.s=google header.b=nLMjJuPW; dmarc=none; spf=pass (mx1.freebsd.org: domain of wma@semihalf.com designates 2607:f8b0:4864:20::b35 as permitted sender) smtp.mailfrom=wma@semihalf.com X-Spamd-Result: default: False [-2.49 / 15.00]; ARC_NA(0.00)[]; FAKE_REPLY(1.00)[]; R_DKIM_ALLOW(-0.20)[semihalf.com:s=google]; FREEFALL_USER(0.00)[wma]; FROM_HAS_DN(0.00)[]; R_SPF_ALLOW(-0.20)[+ip6:2607:f8b0:4000::/36:c]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-stable@freebsd.org]; TO_DN_NONE(0.00)[]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-1.00)[-1.000]; DMARC_NA(0.00)[semihalf.com]; DKIM_TRACE(0.00)[semihalf.com:+]; NEURAL_HAM_SHORT(-0.99)[-0.993]; RCVD_IN_DNSWL_NONE(0.00)[2607:f8b0:4864:20::b35:from]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; MLMMJ_DEST(0.00)[freebsd-stable]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+,1:+,2:~]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; RCVD_COUNT_TWO(0.00)[2]; RCVD_TLS_ALL(0.00)[] X-ThisMailContainsUnwantedMimeParts: N --0000000000009d4b4705e1777804 Content-Type: text/plain; charset="UTF-8" Hi, I confirm that it happens on my setup as well. Have you tried to build official PHP-8.1.6 instead using the one from ports? It seems it works. I tried with freebsd:~/php-src # git status HEAD detached at origin/PHP-8.1.6 nothing to commit, working tree clean freebsd:~/php-src # freebsd:~/php-src # ./buildconf freebsd:~/php-src # ./configure --without-iconv --enable-shared --with-apxs2 freebsd:~/php-src # make -j4 freebsd:~/php-src # make install Regards, Wojtek >>>>> Running 13.1-RELEASE with everything installed from packages and aslr enabled, apache24 will core dump on a graceful restart after installing php81-extensions. Start with apache24, php81 and mod_php81 installed /usr/local/etc/rc.d/apache24 start apache is running /usr/local/etc/rc.d/apache24 graceful apache is still running Then install php81-extensions: /usr/local/etc/rc.d/apache24 stop pkg install php81-extensions /usr/local/etc/rc.d/apache24 start apache is running /usr/local/etc/rc.d/apache24 graceful kernel: pid 2122 (httpd), jid 0, uid 0: exited on signal 11 (core dumped) This is with using all the default conf files. If I disable aslr it works fine. I'm enabling aslr by adding these lines to /etc/sysctl.conf and rebooting. kern.elf32.aslr.enable=1 kern.elf32.aslr.pie_enable=1 kern.elf32.aslr.honor_sbrk=0 kern.elf64.aslr.enable=1 kern.elf64.aslr.pie_enable=1 kern.elf64.aslr.honor_sbrk=0 This is the first time I've tried enabling aslr so maybe I'm doing something wrong. --0000000000009d4b4705e1777804 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hi,=C2=A0

I confirm that it = happens=C2=A0on my setup as well.
Have you tried to build officia= l PHP-8.1.6 instead=C2=A0using the one from ports? It seems it works.
=

I tried=C2=A0with

freebsd:~/php-src # git status
HEAD detached at=C2=A0origin/PHP-8.1.6
nothing to commit, working= tree clean
freebsd:~/php-src #
freebsd:~/php-src #=C2=A0./buildconf
freebsd:~/php-src #=C2=A0= ./configure --without-iconv --enable-share= d --with-apxs2
freebsd:~/php-src #=C2=A0make -j4
freebsd:~/php-src #=C2=A0make install


Reg= ards,
Wojtek


>>>>&= gt;
Running 13.1-RELEASE with everything installed from =
packages and aslr
enabled, apache24 will core dump on a graceful restart after installing
php81-extensions.

Start with apache24, php81 and mod_php81 installed
/usr/local/etc/rc.d/apache24 start
apache is running
/usr/local/etc/rc.d/apache24 graceful
apache is still running

Then install php81-extensions:

/usr/local/etc/rc.d/apache24 stop
pkg install php81-extensions
/usr/local/etc/rc.d/apache24 start
apache is running
/usr/local/etc/rc.d/apache24 graceful
kernel: pid 2122 (httpd), jid 0, uid 0: exited on signal 11 (core dumped)

This is with using all the default conf files.  If I disable aslr it works
fine.  I'm enabling aslr by adding these lines to /etc/sysctl.conf and
rebooting.

kern.elf32.aslr.enable=3D1
kern.elf32.aslr.pie_enable=3D1
kern.elf32.aslr.honor_sbrk=3D0
kern.elf64.aslr.enable=3D1
kern.elf64.aslr.pie_enable=3D1
kern.elf64.aslr.honor_sbrk=3D0

This is the first time I've tried enabling aslr so maybe I'm doing =
something
wrong.
--0000000000009d4b4705e1777804--