sshutdownow / mod-myvhost

Automatically exported from code.google.com/p/mod-myvhost
Apache License 2.0
5 stars 5 forks source link

FEATURE REQUEST: add config option for upload_tmp_dir, open_basedir; add prepend path to open_basedir #9

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
To fulfill my needs, I patched the 0.20 version to use some additional settings 
in addition to DBDocRoot:

MyVhostSetUploadDir Off    # Set upload_tmp_dir to $ROOT/.tmp if enabled and 
directory exists
MyVhostSetOpenBasedir On   # Set open_basedir if enabled
MyVhostSetOpenBasedirPath /var/www/common/bin:/tmp/php    # Prepend 
open_basedir with this path (if not used, please remove this line)

As I did not use the SVN version (and cannot checkin anyway), I attached my 
patch to this ticket. Maybe you'd like to add this functionality in the next 
version? 

Best regards,
Martin

Original issue reported on code.google.com by martin.3...@gmail.com on 29 Jun 2011 at 8:20

Attachments:

GoogleCodeExporter commented 9 years ago
I can't accept your patch to mainline as is.
But I think that it is can be usefull for someone to allow change open_basedir 
and upload via sql request. So I'll make changes to allow it. Presumably there 
will be also one parametr - PHPOpenBasedir, that is returned by SQL request, if 
not - old logic is used.

Original comment by iPop...@gmail.com on 30 Jun 2011 at 8:46

GoogleCodeExporter commented 9 years ago
Hi,

I have the same need.
The DocRoot I use is not the open_basedir.
I have something like :
/wwwroot/hostXXX_base_dir
/wwwroot/hostXXX_base_dir/docroot
/wwwroot/hostXXX_base_dir/tmp
/wwwroot/hostXXX_base_dir/phpinc
/wwwroot/hostXXX_base_dir/log

One fast solution is to ini_set custom php_admin after setting DocRoot, 
OpenBasedir and tmp, so we can just override them.
Well I still have to set some over Apache var like log path. (access and error, 
but one path)

You could treat, one columns = one apache variable to set, then, apply 
php_admin values
or maybe just have 2 columns, one for apaches values and one for php, handle 
both the same way.

Also, safe_mode is now deprecated, and turning it on without control is not 
cool :)

Thanks you !

Original comment by microAl...@gmail.com on 1 Jul 2011 at 9:38

GoogleCodeExporter commented 9 years ago
in version 0.21 overriding open_basedir and safe_mode is supported.  

Original comment by iPop...@gmail.com on 21 Mar 2012 at 5:54