Bug #66160 [Opn->Nab]: PHP file used to load CSS and JS (cached.php) on new site reveals source code
| From: | bjori@php.net | Date: | Sat, 23 Nov 2013 17:59:43 +0000 |
| Subject: | Bug #66160 [Opn->Nab]: PHP file used to load CSS and JS (cached.php) on new site reveals source code | ||
| References: | 1 | Groups: | php.webmaster |
| Request: | Send a blank email to php-webmaster+get-17230@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=66160&edit=1
ID: 66160
Updated by: bjori@php.net
Reported by: josiah at josiahkeller dot com
Summary: PHP file used to load CSS and JS (cached.php) on new
site reveals source code
-Status: Open
+Status: Not a bug
Type: Bug
Package: Website problem
Operating System: N/A
PHP Version: Irrelevant
Block user comment: N
Private report: N
New Comment:
There has always been a "view source" link on all our web pages.
We don't have any sensitive files on php.net, and all of them can be retrieved from rsync or
git.
Previous Comments:
------------------------------------------------------------------------
[2013-11-23 16:56:37] johannes@php.net
This seems to be limited to files in the webroot, all files there are public and accessible from our
git or rsync servers. Removing security flags so that the full web team can take a look and decide
whether extra checks make sense ...
------------------------------------------------------------------------
[2013-11-23 16:29:35] josiah at josiahkeller dot com
Description:
------------
In the new site redesign, a file called "cached.php" is used in the href for the
stylesheet <link> tags, and in the src for a few <script> tags. A GET parameter called
"f" determines what file is served. However, it looks like just about any path can be
manually passed in that parameter, and the script will output the contents of that file, even if
it's a PHP source code file. Not knowing what files are accessible this way, I thought this
should be reported, as for all I know there could be sensitive info that could be found out this
way.
Expected result:
----------------
It probably ought to reject requests to .php or .inc files.
Actual result:
--------------
It doesn't.
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=66160&edit=1