ID:               28454
 Updated by:       [EMAIL PROTECTED]
 Reported By:      bugs dot php dot net at phoenixdigital dot com
-Status:           Open
+Status:           Bogus
 Bug Type:         *Configuration Issues
 Operating System: Freebsd 4.9 Stable
 PHP Version:      4.3.4
 New Comment:

This is not a bug, but meant to work like this due to security reasons.
(Ie, we don't want people to be able to configure their own sendmail
path in .htaccess files).

The correct way of doing what you want is to use the php_admin_value
mail.force_extra_parameters setting, which is configurable per vhost..
unfortunately that only works in PHP 5 (dev).

If you are comfortable patching, you can apply the following patch to
php 4.3.6 (it should also apply to 4.3.4):

Index: main/main.c
===================================================================
RCS file: /repository/php-src/main/main.c,v
retrieving revision 1.512.2.53
diff -u -p -r1.512.2.53 main.c
--- main/main.c 9 Feb 2004 04:05:56 -0000       1.512.2.53
+++ main/main.c 20 May 2004 10:26:04 -0000
@@ -356,7 +356,7 @@ PHP_INI_BEGIN()
 #endif
        PHP_INI_ENTRY("precision",                                     
"14",           PHP_INI_ALL,            OnSetPrecision)
        PHP_INI_ENTRY("sendmail_from",                          NULL,  
        PHP_INI_ALL,            NULL)
-       PHP_INI_ENTRY("sendmail_path",  DEFAULT_SENDMAIL_PATH, 
PHP_INI_SYSTEM,         NULL)
+       PHP_INI_ENTRY("sendmail_path",  DEFAULT_SENDMAIL_PATH, 
PHP_INI_SYSTEM|PHP_INI_PERDIR,          NULL)
        PHP_INI_ENTRY("disable_functions",                      "",    
                PHP_INI_SYSTEM,         NULL)
        PHP_INI_ENTRY("disable_classes",                        "",    
                PHP_INI_SYSTEM,         NULL)


But make sure to use php_admin_value sendmail_path "your command"  so
that it can't be overridden from .htaccess files.


Previous Comments:
------------------------------------------------------------------------

[2004-05-20 09:08:44] bugs dot php dot net at phoenixdigital dot com

if possible can you please adjust the email address in my bug report to
be a non real domain as I don't want my email to be trawled from this
bug report.

please change it to
php_value sendmail_path '/usr/sbin/sendmail -t -i -f
[EMAIL PROTECTED]'


Thanks

------------------------------------------------------------------------

[2004-05-20 09:04:22] bugs dot php dot net at phoenixdigital dot com

Description:
------------
Hi,

We are having trouble getting emails sent from php to set the
return-path header in messages. This is important as we host many sites
from our servers and want bounces to go to the hosted sites address
rather than our system address.

adding this line to the virtual host section in the apache conf.

php_value sendmail_path '/usr/sbin/sendmail -t -i -f
[EMAIL PROTECTED]'

then checking the a page with phpinfo() in it the change is not
visible.

We can set this value in the php.ini file perfectly but however we
cannot set it on a site by site basis in the virtual hosts directive.




------------------------------------------------------------------------


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

Reply via email to