CVE-2006-5178
Race condition in the symlink function in PHP 5.1.6 and earlier allows local users to bypass the open_basedir restriction by using a…
- 6.2MediumCVSS base score
- 0.66%Exploitation in 30 daysEPSS · top 48% of all CVEs
- NoKnown exploitednot in CISA's KEV catalog
- 1Public exploitsMetasploit, Nuclei and Exploit-DB
Description
Race condition in the symlink function in PHP 5.1.6 and earlier allows local users to bypass the open_basedir restriction by using a combination of symlink, mkdir, and unlink functions to change the file path after the open_basedir check and before the file is opened by the underlying system, as demonstrated by symlinking a symlink into a subdirectory, to point to a parent directory via .. (dot dot) sequences, and then unlinking the resulting symlink.
Public exploit
An exploit or proof of concept is public: anyone can try it against an unpatched system. The public collections list an Exploit-DB entry for it.
Show the exploits1
Exploit-DB1 entry
- PHP 5.2.12/5.3.1 - 'symlink()' open_basedir Bypass (Exploit-DB entry) (opens in a new tab)
EDB-ID 10557local, phppublished 19 Dec 2009Verified
Modules, templates and exploits as listed by the Metasploit Framework (BSD-3-Clause), ProjectDiscovery's Nuclei templates (MIT) and the Exploit Database (GPLv2), read once a day. Where the data comes from
Timeline
ID reserved
By mitre
- 1 day later
· 1 day later
Published
- 18 years later
· 18 years later
Record updated
Changes after publication (a new score, a public exploit, EPSS crossing 1, 10 or 50 %, leaving KEV) are kept since November 2026; earlier ones are not known.
Scores
| Scored by | CVSS | Score | Vector |
|---|---|---|---|
| NVDNVD · Modified | 2.0 | Medium6.2 | AV:L/AC:H/Au:N/C:C/I:C/A:C |
- EPSS (exploitation in 30 days)
- 0.66% · top 48% of all CVEs (10 Nov 2026)
The list uses the assigner's score when there is one, then CISA's, then NVD's: Medium 6.2.
Affected products
n/a
- affected n/a
References
15
- 20061003 Advisory 08/2006: PHP open_basedir Race Condition Vulnerability (opens in a new tab)mailing-listx_refsource_FULLDISCx_transferred
- OpenPKG-SA-2006.023 (opens in a new tab)vendor-advisoryx_refsource_OPENPKGx_transferred
- 20061003 Advisory 08/2006: PHP open_basedir Race Condition Vulnerability (opens in a new tab)mailing-listx_refsource_BUGTRAQx_transferred
- TLSA-2006-38 (opens in a new tab)vendor-advisoryx_refsource_TURBOx_transferred
- 20326 (opens in a new tab)vdb-entryx_refsource_BIDx_transferred
- 1692 (opens in a new tab)third-party-advisoryx_refsource_SREASONx_transferred
- http://www.neosecurityteam.net/index.php?action=advisories&id=26 (opens in a new tab)x_refsource_MISCx_transferred
- 22235 (opens in a new tab)third-party-advisoryx_refsource_SECUNIAx_transferred
- 20061009 PHP open_basedir with symlink() function Race Condition PoC exploit (opens in a new tab)mailing-listx_refsource_BUGTRAQx_transferred
- ADV-2006-3901 (opens in a new tab)vdb-entryx_refsource_VUPENx_transferred
- php-openbasedir-security-bypass(29340) (opens in a new tab)vdb-entryx_refsource_XFx_transferred
- MDKSA-2006:185 (opens in a new tab)vendor-advisoryx_refsource_MANDRIVAx_transferred
- http://www.hardened-php.net/advisory_082006.132.html (opens in a new tab)x_refsource_MISCx_transferred
- 1016977 (opens in a new tab)vdb-entryx_refsource_SECTRACKx_transferred
- 22424 (opens in a new tab)third-party-advisoryx_refsource_SECUNIAx_transferred
Sources
The same CVE in the primary databases and aggregators, to check against.
- CVE.org record (opens in a new tab)
- CVE List JSON (GitHub) (opens in a new tab)
- NVD (opens in a new tab)
- FIRST EPSS (opens in a new tab)
- EUVD EUVD-2006-5163 (opens in a new tab)
- OSV.dev (opens in a new tab)
- GitHub Advisories (opens in a new tab)
- CIRCL Vulnerability-Lookup (opens in a new tab)
Badge for a README or a ticket
[](https://cveledger.app/cve/CVE-2006-5178)Record last updated .