#VU58331 Input validation error in PHP


Published: 2021-11-23 | Updated: 2023-10-27

Vulnerability identifier: #VU58331

Vulnerability risk: Medium

CVSSv3.1: 5.7 [CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:N/E:U/RL:O/RC:C]

CVE-ID: CVE-2021-21707

CWE-ID: CWE-20

Exploitation vector: Network

Exploit availability: No

Vulnerable software:
PHP
Universal components / Libraries / Scripting languages

Vendor: PHP Group

Description

The vulnerability allows a remote attacker to inject arbitrary XML code.

The vulnerability exists due to insufficient validation of user-supplied input within the simplexml_load_file() PHP function when processing NULL byte character (e.g. %00). A remote attacker can pass specially crafted URL to the application and bypass implemented security restrictions.

Mitigation
Install updates from vendor's website.

Vulnerable software versions

PHP: 8.0.0 - 8.0.12, 7.4 - 7.4.25, 7.3 - 7.3.32


External links
http://www.php.net/ChangeLog-8.php#8.0.13
http://www.php.net/ChangeLog-7.php#7.4.26
http://www.php.net/ChangeLog-7.php#7.3.33
http://bugs.php.net/bug.php?id=79971


Q & A

Can this vulnerability be exploited remotely?

Yes. This vulnerability can be exploited by a remote non-authenticated attacker via the Internet.

Is there known malware, which exploits this vulnerability?

No. We are not aware of malware exploiting this vulnerability.


Latest bulletins with this vulnerability