All vulnerabilities

Servers and applications

CVE-2004-1020

The addslashes function in PHP 4.3.9 does not properly escape a NULL (/0) character, which may allow remote attackers to read arbitrary files in PHP applications that contain a directory traversal vulnerability in require or include statements, but are otherwise protected by the magic_quotes_gpc mechanism. NOTE: this issue was originally REJECTed by its CNA before publication, but that decision…

Severity
Medium 5.0
Published
10 Jan 2005
Last changed
16 Jun 2026
Added to UpHeron
14 Oct 2026
Exploit chance
7.1% in the next 30 daysHigher than 94% of CVEs. EPSS by FIRST, 12 Nov 2026
Attack
Over the network · No login needed
Attacker can
Read some data
CVSS vector
AV:N/AC:L/Au:N/C:P/I:N/A:N
Sources
NVD

Description

The addslashes function in PHP 4.3.9 does not properly escape a NULL (/0) character, which may allow remote attackers to read arbitrary files in PHP applications that contain a directory traversal vulnerability in require or include statements, but are otherwise protected by the magic_quotes_gpc mechanism. NOTE: this issue was originally REJECTed by its CNA before publication, but that decision is in active dispute. This candidate may change significantly in the future as a result of further discussion.

From NVD.

Affected software

SoftwareAffected versions
PHPServers and applications · cpe:a:php:php
  • Version 5.0.2
  • Version 5.0.1
  • Version 5.0.0
  • Version 5.0-rc3
All 10 release lines
  • Version 4.3.6
  • Version 4.3.7
  • Version 4.3.8
  • Version 4.3.9
  • Version 5.0-rc1
  • Version 5.0-rc2
  • Version 5.0-rc3
  • Version 5.0.0
  • Version 5.0.1
  • Version 5.0.2

References

  • NVD https://nvd.nist.gov/vuln/detail/CVE-2004-1020
  • CVE.org https://www.cve.org/CVERecord?id=CVE-2004-1020