Ticket #396 (new defect)

Opened 6 months ago

Last modified 2 weeks ago

open_basedir issues when including/requiring files

Reported by: max246 Assigned to: somebody
Priority: critical Milestone: 0.9.6
Component: eAccelerator Version: 0.9.6.1
Keywords: open basedir Cc:

Description

I installed the eaccellerator but when setting up the php.ini all website not work.

The error: Fatal error: Can't load /var/c******/info.php, open_basedir restriction. in Unknown on line 0

Attachments

eaccelerator.c.patch (508 bytes) - added by kjoe on 02/04/10 13:47:20.
bugfix patch

Change History

01/28/10 11:26:54 changed by hans

What is open_basedir set to? Are you using safe mode? what is the full path of the file you are trying to open? what are your eaccelerator settings? what version of php do you run? what webserver do you run?

01/31/10 16:47:46 changed by spdj

The same here. We don't use safe_mode but open_basedir.

PHP 5.2.11 with Suhosin-Patch 0.9.7 (cli) (built: Sep 24 2009 12:37:34) Copyright (c) 1997-2009 The PHP Group Zend Engine v2.2.0, Copyright (c) 1998-2009 Zend Technologies

with eAccelerator v0.9.6-rc2, Copyright (c) 2004-2010 eAccelerator, by eAccelerator with Suhosin v0.9.29, Copyright (c) 2007, by SektionEins? GmbH

apache2-2.2.10

zend_extension="/usr/lib/php5/extensions/eaccelerator.so" eaccelerator.shm_size="64" eaccelerator.cache_dir="/srv/www/cache" eaccelerator.enable="1" eaccelerator.optimizer="0" eaccelerator.check_mtime="1" eaccelerator.debug="0" eaccelerator.filter="" eaccelerator.shm_max="0" eaccelerator.shm_ttl="0" eaccelerator.shm_prune_period="0" eaccelerator.shm_only="0" eaccelerator.compress="1" eaccelerator.compress_level="9" eaccelerator.log_file = "/var/log/apache2/eaccelerator.log"

02/03/10 12:55:49 changed by katalonec

same (Release-0.9.6-rc2) some time everithing was ok after installation. then - open_basedir error for all php.

02/04/10 13:47:20 changed by kjoe

  • attachment eaccelerator.c.patch added.

bugfix patch

(follow-up: ↓ 5 ) 02/06/10 13:19:14 changed by spdj

The patch works for me.

(in reply to: ↑ 4 ) 02/07/10 16:26:54 changed by ilihai

  • version changed from 0.9.5 to 0.9.6.

Replying to spdj:

The patch works for me.

Works for me too. PHP 5.3.1

02/23/10 07:39:30 changed by sim

decoration Changed 1 year ago by admin

bathtub Changed 1 year ago by admin

solar system Changed 1 year ago by admin

stair parts Changed 1 year ago by admin

solar supply Changed 1 year ago by admin

02/24/10 11:00:00 changed by sim

decoration Changed 1 year ago by admin

bathtub Changed 1 year ago by admin

solar system Changed 1 year ago by admin

stair parts Changed 1 year ago by admin

solar supply Changed 1 year ago by admin

05/12/10 23:42:35 changed by AaronDM

I can confirm this. Running: FreeBSD 7 Apache 2 PHP 5.3.2

Installed eAccelerator 0.9.6 from the pors repository http://www.freebsd.org/cgi/cvsweb.cgi/ports/www/eaccelerator/

When open_basedir is used, I get the same error as max246. This has not been fixed.

05/25/10 16:06:29 changed by bascorp

07/01/10 19:27:58 changed by leandrofviana

I am using eaccelerator 0.9.6 on Mandriva 2009.1 and is experiencing the same error found as max246.

The error: Fatal error: Can't load /var/c******/info.php, open_basedir restriction. in Unknown on line 0

07/13/10 01:35:37 changed by mwestfall

  • priority changed from major to critical.
  • version changed from 0.9.6 to 0.9.6.1.

Is it possible that this could get rolled into a .2 release soon?

cPanel uses eAccelerator and every time you compile it downloads and overwrites with the newest version, which of course has this problem in it!

Most people are using open_basedir so it seems like a pretty important thing to get fixed.

Thanks, Matt

07/13/10 02:04:09 changed by mwestfall

Wow, I don't know what code you guys are looking at, but the line numbers on that patch, and the code itself are completely wrong.

This is from the 0.9.6.1 source I just downloaded

[code] EACCELERATOR_PROTECT();

if (p != NULL && p->op_array != NULL) {

/* only restore file when open_basedir allows it */ if (php_check_open_basedir(realname TSRMLS_CC)) {

return NULL;

/code

any ideas?

07/13/10 04:07:11 changed by mwestfall

  • summary changed from Opendir error to open_basedir issues when including/requiring files.

Also, it doesn't look like anyone has 'claimed' this ticket/issue.

Is it possible someone could take ownership of this to investigate further and fix once and for all?

Thanks, Matt

07/13/10 05:04:02 changed by iainlbc

Just downloaded and compiled from source and am experiencing this problem as well. I downloaded from: bart.eaccelerator.net/source/0.9.6.1/eacclerator-0.9.6.1.zip

I have the same code in eaccelerator.c as mwestfell

07/13/10 05:33:20 changed by iainlbc

php 5.3.1, eaccelerator-0.9.6-rc1 works fine

but according to the release notes: "Changes in this version:

  • The encoder is removed
  • The optimizer is removed
  • The user cache function are removed
  • The minimal PHP version supported is no 5.1
  • Some internal refactoring to clean the code up
  • Fixed some bugs (and probably added some) "

So im loosing out on alot of functionality just to use eacclerator with open_basedir on PHP 5.3x

=(