2160 : PHP mail Function CRLF Injection
Printer | http://osvdb.org/2160 | Email This | Edit Vulnerability

Views This Week Views All Time Added to OSVDB Last Modified Modified (since 2008) Percent Complete
8 909 over 8 years ago about 1 year ago 2 times 65%

Timeline

Discovery Date Disclosure Date Exploit Publish Date
2003-09-09 2003-09-09 2003-09-09

Description

A flaw exists in PHP which may allow an attacker to add arbitrary data to headers constructed by PHP when remote resources are referenced using these functions. In this way, a PHP script which uses the vulnerable function with the allow_url_fopen() directive enabled may be turned into a proxy, since the attacker is able to construct an arbitrary header to be sent with the request. This may be accomplished by building an arbitrary header using CRLF injection.

Classification

Unknown or Incomplete

Solution

It is possible to mitigate this issue by disabling the "allow_url_fopen" directive in the PHP configuration. It is also possible to sanitize variables used as URLs in the vulnerable functions using the following regular expression:

$var = preg_replace('/\s+/', ', $var);

The vendor has made a source code fix available via the CVS repository.

Mandrake has released a new security advisory, (MDKSA-2003:082). Information on obtaining and applying fixes can be found in the referenced advisory.

OpenPKG has released a new security advisory, OpenPKG-SA-2003.032. Information on obtaining and applying fixes can be found in the referenced advisory.

Conectiva has released an advisory (CLA-2002:545) which contains fixes for this issue. Please see the attached advisory for further details on obtaining fixes.

RedHat has released a security advisory, RHSA-2002:213-06. Information on obtaining and applying fixes can be found in the referenced advisory.

HP has released an advisory for HP Secure OS, and has advised users to upgrade using the packages listed in Red Hat Security Advisory RHSA-2002:213-06.

Products

PHP Group
Watch-list
PHP
Watch-list
3.0
4.0.3
4.0.4
4.0.5
4.0.6
4.0.7
4.1.1
4.1.2
4.2.0
4.2.1
4.2.2
4.2.3

References

Tools & Filters

11050 11444 12326 15005
1476 1481

Credit

Unknown or Incomplete

CVSSv2 Score

CVSSv2 Base Score = 5.0
Source: nvd.nist.gov | Generated: 2003-12-31 | Disagree?

Access_vector_2 Access_complexity_2 Authentication_2 Confidentiality_impact_0 Integrity_impact_1 Availability_impact_0

Blogs

This section lists the latest news and blogs found via the daylife API (and for older items, the technorati API), which mention or otherwise discuss this vulnerability.

None found at this time

Comments

No Comments.

The database information may change without any notice. Use of the information constitutes acceptance for use in an AS IS condition, and there are NO warranties, implied or otherwise, with regard to this information or its use. Any use of this information is at the user's risk. In no event shall the copyright holder or distributor (OSVDB or OSF) be held liable for any damages whatsoever arising out of or in connection with the use or spread of this information.

© Copyright 2012 Open Source Vulnerability Database (OSVDB), All Rights Reserved.
Privacy Statement - Terms of Use