Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 96296 - eAccelerator shouldn't have world-writable cache directory
Summary: eAccelerator shouldn't have world-writable cache directory
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: PHP Bugs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-06-16 11:09 UTC by awk
Modified: 2005-07-01 22:42 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description awk 2005-06-16 11:09:32 UTC
I just switched from a local ebuild to gentoo's eaccelerator 0.9.3 ebuild. The world-writable cache dir 
makes me a bit nervous. I'd rather see something like the following:

        keepdir $EACCELERATOR_CACHEDIR
        fowners apache:apache $EACCELERATOR_CACHEDIR
        fperms 750 $EACCELERATOR_CACHEDIR

Since the eaccelerator FAQ specifically states:

  Q: Is eAccelerator working with php-cgi or php-cli ?
  A: This is not yet supported and it won't be supported in the near future.

You might also want to put this at the end of src_install():

        # won't work with these versions, so don't bother installing the .ini's
        rm ${D}/etc/php/{cli,cgi}-*/php.ini

I'm not sure if there are other versions that should use eAccelerator, yet don't run as apache, but this 
matches what the FAQ says.

Reproducible: Always
Steps to Reproduce:
Comment 1 Thomas Seifert 2005-06-18 11:31:33 UTC
Please don't keep the eaccelerator stuff out of the php-cgi/php.ini.
It works fine with fastcgi-php which is what the php-cgi is responsible for too.
Comment 2 awk 2005-06-19 19:22:52 UTC
(In reply to comment #1)
> Please don't keep the eaccelerator stuff out of the php-cgi/php.ini.

I dunno, if the eAccelerator folks say it isn't supported, then maybe Gentoo shouldn't set it up by 
default. To me "not supported" means they might break it in a future version or otherwise cause 
problems.

But as long as php-cgi runs as the apache user (does it?), it's still safe to change the perms on the 
cache dir.
Comment 3 Sebastian Bergmann (RETIRED) gentoo-dev 2005-07-01 22:42:35 UTC
dev-php/eaccelerator-0.9.3-r1 is in the tree now. It calls

  fowners ${HTTPD_USER}:${HTTPD_GROUP} "${EACCELERATOR_CACHEDIR}"
  fperms 750 "${EACCELERATOR_CACHEDIR}"

to make the cache directory not world-writable.