PHP 4.0.5 through 4.1.0 in safe mode does not properly cleanse the 5th parameter to the mail() function, which allows local users and possibly remote attackers to execute arbitrary commands via shell metacharacters.
https://euvd.enisa.europa.eu/vulnerability/EUVD-2001-1227
http://www.securityfocus.com/bid/2954
http://www.redhat.com/support/errata/RHSA-2003-159.html
http://www.redhat.com/support/errata/RHSA-2002-129.html
http://www.redhat.com/support/errata/RHSA-2002-102.html
http://www.php.net/do_download.php?download_file=php-4.1.2.tar.gz