Your message dated Tue, 24 Mar 2020 03:54:36 +0000
with message-id <e1jgaec-0001il...@fasolo.debian.org>
and subject line Bug#954779: Removed package(s) from unstable
has caused the Debian Bug report #918743,
regarding php-fpm.conf: Shouldn't pass URLs for missing files to PHP-FPM
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact ow...@bugs.debian.org
immediately.)


-- 
918743: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=918743
Debian Bug Tracking System
Contact ow...@bugs.debian.org with problems
--- Begin Message ---
Package: php7.3-fpm
Version: 7.3.0-2
Severity: minor
Tags: patch

Dear Maintainer,

The current behavior of php-fpm.conf is to pass URLs for files which
match ".+\.ph(ar|p|tml)$" to PHP-FPM regardless of whether the file
exists.  This causes a few issues:

- It prevents Apache error handling (e.g. ErrorDocument).
- It adds unnecessary load to PHP-FPM.
- It adds unnecessary request overhead for the request.
- It causes "AH01071: Got error 'Primary script unknown'" to be logged
  to the Apache error log for each request.

This can be avoided by using an <If> directive around SetHandler, as
done on the PHP-FPM page on the Apache Wiki.[1]  I have attached a patch
which does this.

Thanks for considering,
Kevin

1.  https://wiki.apache.org/httpd/PHP-FPM


-- System Information:
Debian Release: buster/sid
  APT prefers testing
  APT policy: (990, 'testing'), (500, 'unstable'), (101, 'experimental')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 4.20.0 (SMP w/4 CPU cores)
Locale: LANG=en_US.utf8, LC_CTYPE=en_US.utf8 (charmap=UTF-8), 
LANGUAGE=en_US.utf8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)

Versions of packages php7.3-fpm depends on:
ii  libapparmor1    2.13.2-3
ii  libargon2-1     0~20171227-0.1
ii  libc6           2.28-2
ii  libmagic1       1:5.34-2
ii  libpcre2-8-0    10.32-3
ii  libsodium23     1.0.16-2
ii  libssl1.1       1.1.1a-1
ii  libsystemd0     240-2
ii  libxml2         2.9.4+dfsg1-7+b3
ii  mime-support    3.61
ii  php7.3-cli      7.3.0-2
ii  php7.3-common   7.3.0-2
ii  php7.3-json     7.3.0-2
ii  php7.3-opcache  7.3.0-2
ii  tzdata          2018i-1
ii  ucf             3.0038+nmu1
ii  zlib1g          1:1.2.11.dfsg-1

php7.3-fpm recommends no packages.

Versions of packages php7.3-fpm suggests:
ii  php-pear  1:1.10.6+submodules+notgz-1

Versions of packages php7.3-common depends on:
ii  libc6       2.28-2
ii  libssl1.1   1.1.1a-1
ii  php-common  2:69
ii  ucf         3.0038+nmu1

-- Configuration Files:
/etc/apache2/conf-available/php7.3-fpm.conf changed [not included]

-- no debconf information
>From 2d80e7bd564cce570b8725614e3b73ccd8b74a11 Mon Sep 17 00:00:00 2001
Message-Id: 
<2d80e7bd564cce570b8725614e3b73ccd8b74a11.1546987306.git.ke...@kevinlocke.name>
From: Kevin Locke <ke...@kevinlocke.name>
Date: Tue, 8 Jan 2019 15:32:19 -0700
Subject: [PATCH] Don't pass URLs for missing files to PHP-FPM

When there is no file matching a request URL ending in a matched PHP
extension, passing it to PHP-FPM doesn't make sense.  It adds
unnecessary PHP-FPM load and request overhead, prevents Apache error
handling (e.g.  ErrorDocument), and causes `AH01071: Got error 'Primary
script unknown'` to be logged.

Avoid this by using an <If> directive to only configure SetHandler if
the requested file exists, as documented on [PHP-FPM] on the Apache
Wiki.

[PHP-FPM]: https://wiki.apache.org/httpd/PHP-FPM

Signed-off-by: Kevin Locke <ke...@kevinlocke.name>
---
 debian/php-fpm.conf | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/debian/php-fpm.conf b/debian/php-fpm.conf
index 3fc2f80c0..1d78fbb48 100644
--- a/debian/php-fpm.conf
+++ b/debian/php-fpm.conf
@@ -7,7 +7,9 @@
     </IfModule>
 
     <FilesMatch ".+\.ph(ar|p|tml)$">
-        SetHandler 
"proxy:unix:/run/php/php@php_vers...@-fpm.sock|fcgi://localhost"
+        <If "-f %{REQUEST_FILENAME}">
+            SetHandler 
"proxy:unix:/run/php/php@php_vers...@-fpm.sock|fcgi://localhost"
+        </If>
     </FilesMatch>
     <FilesMatch ".+\.phps$">
         # Deny access to raw php sources by default
-- 
2.20.1


--- End Message ---
--- Begin Message ---
Version: 7.3.15-3+rm

Dear submitter,

as the package php7.3 has just been removed from the Debian archive
unstable we hereby close the associated bug reports.  We are sorry
that we couldn't deal with your issue properly.

For details on the removal, please see https://bugs.debian.org/954779

The version of this package that was in Debian prior to this removal
can still be found using http://snapshot.debian.org/.

Please note that the changes have been done on the master archive and
will not propagate to any mirrors until the next dinstall run at the
earliest.

This message was generated automatically; if you believe that there is
a problem with it please contact the archive administrators by mailing
ftpmas...@ftp-master.debian.org.

Debian distribution maintenance software
pp.
Scott Kitterman (the ftpmaster behind the curtain)

--- End Message ---

Reply via email to