Exim4 and PHP and PHP-CGI mail() function using incorrect From: and applying Sender: headers.

If you’re using Exim4 and PHP as a module or as a CGI with suexec. You may have noticed some issues with your mail. Specifically you would have noticed that either the “From:” header was using “nobody@machinename” or “user@machine name, its also possibly that you had an additional header called “Sender:”. There are two things you need to do to fix this. You first need to make sure that your “php.ini” has the following value “sendmail_path = /usr/sbin/sendmail -t -i”. Which is the default, double check this variable as it might be set to something else.

If you’re using Exim4 and PHP as a module or as a CGI with suexec. You may have noticed some issues with your mail. Specifically you would have noticed that either the “From:” header was using “nobody@machinename” or “user@machine name, its also possibly that you had an additional header called “Sender:”.

There are two things you need to do to fix this. You first need to make sure that your “php.ini” has the following value “sendmail_path = /usr/sbin/sendmail -t -i”. Which is the default, double check this variable as it might be set to something else.

Next you want to make sure that you have Exim4 configued properly, if you use Debian Etch then you should be fine. However if you change the default configs or have a different setup. Then make sure you have set “local_from_check = false” inside “exim4.conf.template” for Debian Etch and if you don’t use Debian then check the exim configs.


Did you like this article?


0 Shares:
You May Also Like

Thunderbird still has potential to fly despite developers leaving the nest

Thunderbird is a pretty great open sourced mail client that is available on multiple platforms and for free. From the beginning its development has been mostly be shadowed by FireFox. The two core developers of Thunderbird have left Mozilla, which is a big blow to the ongoing development of Thunderbird. Will Thunderbird not longer get as many updates or new features? Will development complete stop? Only time will tell.
Read More

QuickPwn Released for Mac OS X

The iphone-dev.org crew has released QuickPwn for Mac OS X, there is a an official torrent for the release.
Here is the long awaited “QuickPwn” for Mac OS X. You’ll see a similarity to the user-interface of PwnageTool, this is because of the great feedback we’ve had since we moved to that interface with PwnageTool 2.x.
Read More

Official Jailbreak for iPhone 2.1 Firmware Released OSX Only

There is now an official iphone-dev.org version of QuickPwn that supports the 2.1 firmware released by Apple on friday.
Some of the popular press and blogs have been backing the opposition. :-) While criticism and competition is fine it should be reported correctly, with all the facts. and certainly minus the FUD. Do you guys think we are “less and less relevant with each passing day” ? We don’t think so, and we certainly prefer our hacks to theirs. ;-) Though even if the world deems us irrelevant, the iPhone family of devices is still fun to hack!
Read More

Hard times for hard drives: US may ban popular imports

This could be a damaging blow to quite a few companies within the United States. For instance, take a dedicated server hosting company that relies on one of many hardware vendors like Dell or HP (Hewlett-Packard). Its possible that said vendor will have stock pile of hard drives. Put lets put this into perspective. If you read the entire article you will see a similar situation that ended with Broadcom filing a complaint against Qualcomm. The International Trade Commission banned Qualcomm from shipping any new chips and hardware into the United Sates, and any chips that were already being shipped to the United States could continue. The ban lasted for 45 days, until an appeal by Qualcomm was successful and then the ban was lifted.
Read More