PHP up to 5.2.6 ftok path traversal

CVSS Meta Temp Score
CVSS is a standardized scoring system to determine possibilities of attacks. The Temp Score considers temporal factors like disclosure, exploit and countermeasures. The unique Meta Score calculates the average score of different sources to provide a normalized scoring system.
Current Exploit Price (≈)
Our analysts are monitoring exploit markets and are in contact with vulnerability brokers. The range indicates the observed or calculated exploit price to be seen on exploit markets. A good indicator to understand the monetary effort required for and the popularity of an attack.
CTI Interest Score
Our Cyber Threat Intelligence team is monitoring different web sites, mailing lists, exploit markets and social media networks. The CTI Interest Score identifies the interest of attackers and the security community for this specific vulnerability in real-time. A high score indicates an elevated risk to be targeted for this vulnerability.
4.8$0-$5k0.00

Summaryinfo

A vulnerability marked as problematic has been reported in PHP. The affected element is the function ftok. The manipulation leads to path traversal. This vulnerability is documented as CVE-2008-2666. Additionally, an exploit exists. It is suggested to upgrade the affected component.

Detailsinfo

A vulnerability, which was classified as problematic, has been found in PHP (Programming Language Software). This issue affects the function ftok. The manipulation with an unknown input leads to a path traversal vulnerability. Using CWE to declare the problem leads to CWE-22. The product uses external input to construct a pathname that is intended to identify a file or directory that is located underneath a restricted parent directory, but the product does not properly neutralize special elements within the pathname that can cause the pathname to resolve to a location that is outside of the restricted directory. Impacted is confidentiality. The summary by CVE is:

Multiple directory traversal vulnerabilities in PHP 5.2.6 and earlier allow context-dependent attackers to bypass safe_mode restrictions by creating a subdirectory named http: and then placing ../ (dot dot slash) sequences in an http URL argument to the (1) chdir or (2) ftok function.

The bug was discovered 06/17/2008. The weakness was released 06/19/2008 by Maksymilian Arciemowicz (Website). It is possible to read the advisory at us-cert.gov. The identification of this vulnerability is CVE-2008-2666 since 06/10/2008. The exploitation is known to be easy. The attack may be initiated remotely. No form of authentication is needed for a successful exploitation. Technical details as well as a public exploit are known. The attack technique deployed by this issue is T1006 according to MITRE ATT&CK.

The exploit is available at securityfocus.com. It is declared as proof-of-concept. The vulnerability was handled as a non-public zero-day exploit for at least 2 days. During that time the estimated underground price was around $5k-$25k. The vulnerability scanner Nessus provides a plugin with the ID 34089 (FreeBSD : php -- input validation error in safe_mode (ee6fa2bd-406a-11dd-936a-0015af872849)), which helps to determine the existence of the flaw in a target environment. It is assigned to the family FreeBSD Local Security Checks and running in the context l. The commercial vulnerability scanner Qualys is able to test this issue with plugin 185076 (HP-UX Running Apache Web Server Suite Multiple Vulnerabilities (HPSBUX02431)).

Upgrading eliminates this vulnerability. A possible mitigation has been published 3 days after the disclosure of the vulnerability.

The vulnerability is also documented in the databases at X-Force (43198), Exploit-DB (31937), Tenable (34089), SecurityFocus (BID 29796†) and OSVDB (46638†). Entries connected to this vulnerability are available at VDB-3978, VDB-23858, VDB-30376 and VDB-38768. Statistical analysis made it clear that VulDB provides the best quality for vulnerability data.

Productinfo

Type

Name

Version

License

Website

CPE 2.3info

CPE 2.2info

CVSSv4info

VulDB Vector: 🔍
VulDB Reliability: 🔍

CVSSv3info

VulDB Meta Base Score: 5.3
VulDB Meta Temp Score: 4.8

VulDB Base Score: 5.3
VulDB Temp Score: 4.8
VulDB Vector: 🔍
VulDB Reliability: 🔍

CVSSv2info

AVACAuCIA
💳💳💳💳💳💳
💳💳💳💳💳💳
💳💳💳💳💳💳
VectorComplexityAuthenticationConfidentialityIntegrityAvailability
UnlockUnlockUnlockUnlockUnlockUnlock
UnlockUnlockUnlockUnlockUnlockUnlock
UnlockUnlockUnlockUnlockUnlockUnlock

VulDB Base Score: 🔍
VulDB Temp Score: 🔍
VulDB Reliability: 🔍

NVD Base Score: 🔍

Exploitinginfo

Class: Path traversal
CWE: CWE-22
CAPEC: 🔍
ATT&CK: 🔍

Physical: No
Local: No
Remote: Yes

Availability: 🔍
Access: Public
Status: Proof-of-Concept
Download: 🔍

EPSS Score: 🔍
EPSS Percentile: 🔍

Price Prediction: 🔍
Current Price Estimation: 🔍

0-DayUnlockUnlockUnlockUnlock
TodayUnlockUnlockUnlockUnlock

Nessus ID: 34089
Nessus Name: FreeBSD : php -- input validation error in safe_mode (ee6fa2bd-406a-11dd-936a-0015af872849)
Nessus File: 🔍
Nessus Risk: 🔍
Nessus Family: 🔍
Nessus Context: 🔍

OpenVAS ID: 62847
OpenVAS Name: Slackware Advisory SSA:2008-339-01 php
OpenVAS File: 🔍
OpenVAS Family: 🔍

Qualys ID: 🔍
Qualys Name: 🔍

Exploit-DB: 🔍

Threat Intelligenceinfo

Interest: 🔍
Active Actors: 🔍
Active APT Groups: 🔍

Countermeasuresinfo

Recommended: Upgrade
Status: 🔍

Reaction Time: 🔍
0-Day Time: 🔍
Exposure Time: 🔍

Timelineinfo

06/10/2008 🔍
06/17/2008 +7 days 🔍
06/18/2008 +1 days 🔍
06/18/2008 +0 days 🔍
06/19/2008 +1 days 🔍
06/19/2008 +0 days 🔍
06/19/2008 +0 days 🔍
06/22/2008 +3 days 🔍
06/29/2008 +7 days 🔍
09/05/2008 +68 days 🔍
03/16/2015 +2383 days 🔍
03/01/2025 +3638 days 🔍

Sourcesinfo

Product: php.org

Advisory: us-cert.gov
Researcher: Maksymilian Arciemowicz
Status: Confirmed
Confirmation: 🔍

CVE: CVE-2008-2666 (🔍)
GCVE (CVE): GCVE-0-2008-2666
GCVE (VulDB): GCVE-100-42851
X-Force: 43198
SecurityFocus: 29796 - PHP 'chdir()' and 'ftok()' 'safe_mode' Multiple Security Bypass Vulnerabilities
Secunia: 32746
OSVDB: 46638 - PHP chdir and ftoc() security bypass
SecurityTracker: 1020328
Vulnerability Center: 18690 - PHP Directory Traversal Vulnerabilities Allow Remote Attackers to Bypass Security Restrictions, Medium
Vupen: ADV-2009-1297

scip Labs: https://www.scip.ch/en/?labs.20161013
See also: 🔍

Entryinfo

Created: 03/16/2015 17:00
Updated: 03/01/2025 08:37
Changes: 03/16/2015 17:00 (77), 08/12/2019 09:10 (12), 03/01/2025 08:37 (19)
Complete: 🔍
Cache ID: 216::103

Statistical analysis made it clear that VulDB provides the best quality for vulnerability data.

Discussion

No comments yet. Languages: en.

Please log in to comment.

Are you interested in using VulDB?

Download the whitepaper to learn more about our service!