php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #25047 Trailing / does not work after PHP scripts in URL
Submitted: 2003-08-11 17:17 UTC Modified: 2004-04-21 00:13 UTC
Votes:59
Avg. Score:4.6 ± 1.1
Reproduced:45 of 50 (90.0%)
Same Version:28 (62.2%)
Same OS:29 (64.4%)
From: phpbugs at mike2k dot com Assigned: shane (profile)
Status: No Feedback Package: CGI/CLI related
PHP Version: 4CVS, 5CVS OS: Redhat Linux 7.3
Private report: No CVE-ID: None
Have you experienced this issue?
Rate the importance of this bug to you:

 [2003-08-11 17:17 UTC] phpbugs at mike2k dot com
Description:
------------
For example: http://foo.bar.com/phpinfo.php/some/testing/path

Should report that path info in PATH_INFO and possibly REQUEST_URI among other things. however since php 4.3.2 i believe it seems that this does not seem to work - it always gives a "No input file specified" - but it *used* to work just fine.

This is a CGI binary compiled with:
./configure  --with-mysql=/usr/local/mysql --enable-track-vars --enable-shmop --with-zlib-dir=/usr --enable-inline-optimization --disable-rpath --disable-debug --disable-ipv6 --enable-cli --enable-fastcgi --with-gd --with-png-dir=/usr --with-jpeg-dir=/usr --without-pear --enable-xslt --with-xslt-sablot=/usr/local --with-msession

I have tried to use --disable-path-info-check as well as --enable-discard-path (some other people logged a variant of this bug/change in "feature") but I do not believe it was ever clearly stated if this is now supposed to function like this (i.e. removing parts of functionality that I had hoped to use.)

Running Zeus 4.2r2, PHP Accelerator 1.3.3r2, PHP versions 4.3.3RC1 and RC3, I believe I also compiled 4.3.2 and 4.2.3 and it changed after 4.2 (I think.)

If this "bug" is closed, please include why it was closed - otherwise I consider this a bug as functionality was lost and I see no reason why it cannot be "fixed" or reimplemented, or why the command line options seem to make it sound like you can turn this on.

--disable-path-info-check
"If this is disabled, paths such as /info.php/test?a=b will fail to work."

The double negatives are confusing. It doesn't work with or without this switch. It makes it sound like you CAN have it work by default and using this switch will disable it...

Reproduce code:
---------------
see above.

Expected result:
----------------
see above.

Actual result:
--------------
see above.

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2003-08-11 17:47 UTC] phpbugs at mike2k dot com
The error message is thrown around line 1508 of sapi/cgi/cgi_main.c

"if we are unable to open path_translated and we are not running from shell (so fp == NULL), then fail."

Code should be changed or a feature should be added so it overrides that behavior like it used to. It used to ignore everything past the actual file itself - and pass that all as PATH_INFO and such.
 [2003-08-12 08:47 UTC] sniper@php.net
Don't use --enable-discard-path and set cgi.fix_pathinfo=1
and it will work just fine. (tested within Apache)


 [2003-08-12 09:19 UTC] phpbugs at mike2k dot com
i put

cgi.fix_pathinfo = 1

in my php.ini file.

the configure string i used is:

'./configure' '--with-mysql=/usr/local/mysql' '--enable-track-vars' '--enable-shmop' '--with-zlib-dir=/usr' '--enable-inline-optimization' '--disable-rpath' '--disable-debug' '--disable-ipv6' '--enable-cli' '--enable-fastcgi' '--with-gd' '--with-png-dir=/usr' '--with-jpeg-dir=/usr' '--without-pear' '--enable-xslt' '--with-xslt-sablot=/usr/local' '--with-msession' '--disable-path-info-check'

will that disable-path-info-check mess with this?

should i be doing ANY --enable or --disable options to make this work from the configure script command line?

also remember, i am not running apache - i am running php via fastcgi on zeus webserver..
 [2003-08-12 09:19 UTC] phpbugs at mike2k dot com
i forgot to say in the note that it DID NOT work putting that in php.ini and restarting it.
 [2003-08-12 09:23 UTC] sniper@php.net
This fastcgi mess is for Shane to fix, pure CGI works fine.

 [2004-04-21 00:13 UTC] iliaa@php.net
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Open". Thank you.


 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Mar 29 10:01:28 2024 UTC