Bug 1248077 - PHP-FPM incorrectly defines the SCRIPT_NAME variable when using Apache
PHP-FPM incorrectly defines the SCRIPT_NAME variable when using Apache
Status: NEW
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: php (Show other bugs)
7.3
All All
unspecified Severity medium
: rc
: ---
Assigned To: Web Stack Team
BaseOS QE - Apps
:
Depends On:
Blocks: 1295396 1473612
  Show dependency treegraph
 
Reported: 2015-07-29 10:34 EDT by Ward
Modified: 2017-11-02 06:58 EDT (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed:
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
CentOS 7562 None None None Never
PHP Bug Tracker 65641 None None None Never

  None (edit)
Description Ward 2015-07-29 10:34:45 EDT
Description of problem:

When using Apache + PHP_FPM, the SCRIPT_NAME variable is incorrectly set. For 
example, accessing "http://127.0.0.1/sample/test.php/a/b/c", results in:

ORIG_SCRIPT_NAME: 
SCRIPT_NAME: /sample/test.php/a/b/c
ORIG_SCRIPT_FILENAME: //tmp/sample/test.php/a/b/c
SCRIPT_FILENAME: //tmp/sample/test.php
PATH_INFO: /a/b/c
ORIG_PATH_INFO: 

While when using mod_php, the values are:

SCRIPT_NAME: /sample/test.php
SCRIPT_FILENAME: /tmp/sample/test.php
PATH_INFO: /a/b/c

This is a PHP bug and is fixed in PHP 5.5.18: https://bugs.php.net/bug.php?id=65641
Please backport the fix. The popular package owncloud cannot be used with apache + php-fpm because of this issue: https://github.com/owncloud/core/issues/7719


Version-Release number of selected component (if applicable):
< PHP 5.5.18

How reproducible:
100%

Steps to Reproduce:
1. See example above: access "http://127.0.0.1/sample/test.php/a/b/c" with apache 2.4 and php-fpm.

Actual results:
ORIG_SCRIPT_NAME: 
SCRIPT_NAME: /sample/test.php/a/b/c
ORIG_SCRIPT_FILENAME: //tmp/sample/test.php/a/b/c
SCRIPT_FILENAME: //tmp/sample/test.php
PATH_INFO: /a/b/c
ORIG_PATH_INFO: 

Expected results:
SCRIPT_NAME: /sample/test.php
SCRIPT_FILENAME: /tmp/sample/test.php
PATH_INFO: /a/b/c
Comment 4 Remi Collet 2016-06-29 03:41:21 EDT
This look like a duplicate of bug #1138563

Note You need to log in before you can comment on or make changes to this bug.