PEAR is archived and read-only

This mirror preserves historical PEAR package releases and metadata so existing references remain available.

Home » Mail » Mail » Bug #6033

sendmail.php fails if open_basedir is set

Details

Submitted2005-11-22 05:16 UTC
Fromphyre at rogers dot com
Assignedchagenbu
StatusClosed
PackageMail
PHP Version5.0.5
OSLinux (Debian 3.1)
Roadmaps(Not assigned)

Comments

[2005-11-22 05:16 UTC] phyre at rogers dot com

Description:
------------
The is_file on line 121 fails if open_basedir is set. The actual popen works as expected for sendmail (which is actually a bit strange), however the is_file fails as long as it's not in open_basedir.

Expected result:
----------------
This should really work, as including the PEAR repository folder should be enough... especially in shared environments when giving access to /usr/lib or /usr/sbin isn't ideal.

Actual result:
--------------
is_file returns false and the code does not execute, even though without the is_file test, it does (and would) execute perfectly.

The solution is probably to find a better way to check if sendmail exists at the path specified, as is_file clearly isn't the solution.

[2005-11-22 19:13 UTC] chagenbu at php dot net

Please try this patch:
http://cvs.php.net/diff.php/pear/Mail/Mail/sendmail.php?r1=1.12&r2=1.13&ty=u

[2005-11-22 20:29 UTC] phyre at rogers dot com

That patch did the trick (although I applied it manually against 1.11, though it did fix the issue.

I'd say this is worthy of pending and closing this bug.

[2005-11-23 03:11 UTC] chagenbu at php dot net

This bug has been fixed in CVS.

If this was a documentation problem, the fix will appear on pear.php.net by the end of next Sunday (CET).

If this was a problem with the pear.php.net website, the change should be live shortly.

Otherwise, the fix will appear in the package's next release.

Thank you for the report and for helping us make PEAR better.