---
title: "CVE-2009-3557\n    | Ubuntu"
description: Ubuntu is an open source software operating system that runs from the
  desktop, to the cloud, to all your internet connected things.
url: https://ubuntu.com/security/CVE-2009-3557?format=md
keywords: index, follow
---

# CVE-2009-3557

Publication date 23 November 2009

Last updated 24 July 2024

---

Ubuntu priority

**Low**

[Why this priority?](https://ubuntu.com/security/cves/about#priority )

Toggle side navigation

## Description

The tempnam function in ext/standard/file.c in PHP before 5.2.12 and 5.3.x
before 5.3.1 allows context-dependent attackers to bypass safe\_mode
restrictions, and create files in group-writable or world-writable
directories, via the dir and prefix arguments.

[Read the notes from the security team](https://ubuntu.com/security/CVE-2009-3557?format=md#notes)

## Status

Show unmaintained releases

| Package | Ubuntu Release | Status |
| --- | --- | --- |
| php5 | 9.10 karmic | Fixed 5.2.10.dfsg.1-2ubuntu6.3 |
| 9.04 jaunty | Fixed 5.2.6.dfsg.1-3ubuntu4.4 |
| 8.10 intrepid | Fixed 5.2.6-2ubuntu4.5 |
| 8.04 LTS hardy | Fixed 5.2.4-2ubuntu5.9 |
| 6.06 LTS dapper | Fixed 5.1.2-1ubuntu3.17 |

---

* [How can I get the fixes?](https://ubuntu.com/security/cves/about#security)
* [What do statuses mean?](https://ubuntu.com/security/cves/about#statuses)
* [Patch details](https://ubuntu.com/security/CVE-2009-3557?format=md#patch-details)

## Notes

---

### [mdeslaur](https://launchpad.net/~mdeslaur)

safe\_mode is not supported

### Patch details

For informational purposes only. We recommend not to cherry-pick updates. [How can I get the fixes?](https://ubuntu.com/security/cves/about#security)

| Package | Patch details |
| --- | --- |
| php5 | * Upstream:   <http://svn.php.net/viewvc?view=revision&revision=288945> |

## References

* [MITRE](https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2009-3557)
* [NVD](https://nvd.nist.gov/vuln/detail/CVE-2009-3557)
* [Launchpad](https://launchpad.net/bugs/cve/CVE-2009-3557)
* [Debian](https://security-tracker.debian.org/tracker/CVE-2009-3557)

### Related Ubuntu Security Notices (USN)

+ [USN-862-1](https://usn.ubuntu.com/USN-862-1)
+ PHP vulnerabilities
+ 26 November 2009

### Other references

* <http://securityreason.com/securityalert/6601>
* <https://www.cve.org/CVERecord?id=CVE-2009-3557>
