Current location: Hot Scripts Forums » Programming Languages » PHP » PHP Security alert: PHP mail() Function Lets Remote Users Inject E-mail Headers


PHP Security alert: PHP mail() Function Lets Remote Users Inject E-mail Headers

Reply
  #1 (permalink)  
Old 04-24-07, 05:18 AM
darkerstar's Avatar
darkerstar darkerstar is offline
Newbie Coder
 
Join Date: Apr 2007
Location: London
Posts: 24
Thanks: 0
Thanked 0 Times in 0 Posts
PHP Security alert: PHP mail() Function Lets Remote Users Inject E-mail Headers

PHP mail() Function Lets Remote Users Inject E-mail Headers

A flaw was discovered in the way PHP's mail() function processed header
data. If a script sent mail using a Subject header containing a string from
an untrusted source, a remote attacker could send bulk e-mail to unintended
recipients. (CVE-2007-1718)

See http://securitytracker.com/alerts/2007/Apr/1017947.html
__________________
Read Tiaon Lab blog
PHP + Delphi programming
http://www.tiaon.com/wordpress/
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiShare on FacebookShare on Stumble UponShare on Twitter
Reply With Quote
  #2 (permalink)  
Old 04-24-07, 05:38 AM
UnrealEd's Avatar
UnrealEd UnrealEd is offline
Community Liaison
 
Join Date: May 2005
Location: Antwerp, Belgium
Posts: 3,165
Thanks: 4
Thanked 25 Times in 25 Posts
this bug is known for a very longtime
__________________
"Good judgement comes from experience, and experience comes from bad judgement." - Fred Brooks

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiShare on FacebookShare on Stumble UponShare on Twitter
Reply With Quote
  #3 (permalink)  
Old 04-24-07, 07:37 AM
mab's Avatar
mab mab is offline
Community VIP
 
Join Date: Oct 2005
Location: Denver, Co. USA
Posts: 2,674
Thanks: 0
Thanked 0 Times in 0 Posts
The information in that link is out of date, despite the recent date it has on it. It basically shows upgrading to PHP 5.1.6. However, that recommendation is not even current. The current version of PHP is 5.2.1. In fact that link is only reposting information from another source.

I guess the recommendation would be to not post information you happen to come across, unless you have first hand knowledge of its relevance and accuracy or it is information that you researched yourself and you are the source of the information. Posting second hand/third hand, unverified information, is not helpful. Research things yourself, instead of taking it at face value.
__________________
Error checking, error reporting, and error recovery. If your code does not have these to get it to tell you why it is not working, what makes you think someone in a programming forum will be able to tell you why it is not working???
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiShare on FacebookShare on Stumble UponShare on Twitter
Reply With Quote
  #4 (permalink)  
Old 04-28-07, 07:30 AM
Keith's Avatar
Keith Keith is offline
Community Liaison
 
Join Date: Feb 2004
Posts: 1,232
Thanks: 1
Thanked 11 Times in 11 Posts


Properly validate and format your freaking input and you have nothing to worry about. Lazy programmers want everything handled for them.
__________________
The toxic ZCE
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiShare on FacebookShare on Stumble UponShare on Twitter
Reply With Quote
  #5 (permalink)  
Old 04-29-07, 08:14 PM
wirehopper's Avatar
wirehopper wirehopper is offline
-
 
Join Date: Feb 2006
Posts: 2,516
Thanks: 20
Thanked 109 Times in 106 Posts
Check for to:, cc:, and bcc: in the input, or if you're really lazy - just reject any input with a colon.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiShare on FacebookShare on Stumble UponShare on Twitter
Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
PHP mail function with AOL IDs on Linux jeephp PHP 2 04-24-06 09:26 AM
PHP mail function and Gmail strings6 PHP 8 12-29-05 08:58 AM
PHP mail function and sending php content. strings6 PHP 4 12-27-05 09:03 AM
FYI: Shout goes out over PHP security bugs nugensoftware PHP 0 11-02-05 12:43 AM
a question concerning mail function in php? timorthy PHP 6 05-29-05 08:02 PM


All times are GMT -5. The time now is 11:11 AM.
vBulletin® Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.