#25601 [NEW]: PHP displays incorrect error messages when pages are accessed at the same time

2003-09-19 Thread leiter at ifup dot net
From: leiter at ifup dot net
Operating system: Linux
PHP version:  4.3.3
PHP Bug Type: Apache2 related
Bug description:  PHP displays incorrect error messages when pages are accessed at the 
same time

Description:

I'm running Apache 2.0.47 with prefork mpm under Linux.

If I access example.org and example.com at the same time I get this
errormessage:

Warning: Unknown(): open_basedir restriction in effect.
File(/var/www/example.com/index.php) is not within the allowed path(s):
(/var/www/example.org) in Unknown on line 0

Warning: Unknown(/var/www/example.com/index.php): failed to open stream:
Operation not permitted in Unknown on line 0

Warning: (null)(): Failed opening '/var/www/example.com/index.php' for
inclusion (include_path='.:/opt/php4/lib/php') in Unknown on line 0

Note that example.com gets the limits for example.org.

Reproduce code:
---
VirtualHost ip:80
DocumentRoot /var/www/example.com
ServerName example.com
ServerAlias www.example.com
RewriteEngine on
# some rewrite rules here. shouldn't matter
php_flag register_globals on
/VirtualHost

VirtualHost ip:80
DocumentRoot /var/www/example.org
ServerName www.example.org
ServerAlias example.org
php_flag register_globals on
php_admin_flag safe_mode on
php_admin_value safe_mode_exec_dir /opt/apache2/safemode_exec
php_admin_value open_basedir /var/www/example.org
/VirtualHost


Expected result:

example.com should not be affected by restrictions for example.org! This
only happens if the pages are requested at the same time, otherwise it
works. Looks like a race condition. I'm not sure if this is a PHP or
Apache2 bug.


-- 
Edit bug report at http://bugs.php.net/?id=25601edit=1
-- 
Try a CVS snapshot (php4):  http://bugs.php.net/fix.php?id=25601r=trysnapshot4
Try a CVS snapshot (php5):  http://bugs.php.net/fix.php?id=25601r=trysnapshot5
Fixed in CVS:   http://bugs.php.net/fix.php?id=25601r=fixedcvs
Fixed in release:   http://bugs.php.net/fix.php?id=25601r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=25601r=needtrace
Try newer version:  http://bugs.php.net/fix.php?id=25601r=oldversion
Not developer issue:http://bugs.php.net/fix.php?id=25601r=support
Expected behavior:  http://bugs.php.net/fix.php?id=25601r=notwrong
Not enough info:http://bugs.php.net/fix.php?id=25601r=notenoughinfo
Submitted twice:http://bugs.php.net/fix.php?id=25601r=submittedtwice
register_globals:   http://bugs.php.net/fix.php?id=25601r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=25601r=php3
Daylight Savings:   http://bugs.php.net/fix.php?id=25601r=dst
IIS Stability:  http://bugs.php.net/fix.php?id=25601r=isapi
Install GNU Sed:http://bugs.php.net/fix.php?id=25601r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=25601r=float


#25601 [Opn-Dup]: PHP displays incorrect error messages when pages are accessed at the same time

2003-09-19 Thread leiter at ifup dot net
 ID:   25601
 User updated by:  leiter at ifup dot net
 Reported By:  leiter at ifup dot net
-Status:   Open
+Status:   Duplicate
 Bug Type: Apache2 related
 Operating System: Linux
 PHP Version:  4.3.3
 New Comment:

Sorry, seems to be a duplicate of #25417.


Previous Comments:


[2003-09-19 05:02:06] leiter at ifup dot net

Description:

I'm running Apache 2.0.47 with prefork mpm under Linux.

If I access example.org and example.com at the same time I get this
errormessage:

Warning: Unknown(): open_basedir restriction in effect.
File(/var/www/example.com/index.php) is not within the allowed path(s):
(/var/www/example.org) in Unknown on line 0

Warning: Unknown(/var/www/example.com/index.php): failed to open
stream: Operation not permitted in Unknown on line 0

Warning: (null)(): Failed opening '/var/www/example.com/index.php' for
inclusion (include_path='.:/opt/php4/lib/php') in Unknown on line 0

Note that example.com gets the limits for example.org.

Reproduce code:
---
VirtualHost ip:80
DocumentRoot /var/www/example.com
ServerName example.com
ServerAlias www.example.com
RewriteEngine on
# some rewrite rules here. shouldn't matter
php_flag register_globals on
/VirtualHost

VirtualHost ip:80
DocumentRoot /var/www/example.org
ServerName www.example.org
ServerAlias example.org
php_flag register_globals on
php_admin_flag safe_mode on
php_admin_value safe_mode_exec_dir /opt/apache2/safemode_exec
php_admin_value open_basedir /var/www/example.org
/VirtualHost


Expected result:

example.com should not be affected by restrictions for example.org!
This only happens if the pages are requested at the same time,
otherwise it works. Looks like a race condition. I'm not sure if this
is a PHP or Apache2 bug.






-- 
Edit this bug report at http://bugs.php.net/?id=25601edit=1