Critical Vulnerabilities in PHP Packages: php5 and php7.0

php5 Updated 03 Oct 2025

Summary

13/07/2021
N/A
Yes i
Unrated
Not published

USN-5006-2: php5, php7.0 vulnerabilities. Affects php5 versions < 5.5.9+dfsg-1ubuntu4.29+esm14. Fixed in 5.5.9+dfsg-1ubuntu4.29+esm14. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Devnack Your last release was probably never penetration tested Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

PHP is a widely-used open-source scripting language designed for web development but also used as a general-purpose programming language. It is known for its ease of use, flexibility, and integration capabilities with various databases. The packages php5 and php7.0 are essential components in many web applications, providing the core functionalities required to run PHP scripts. However, recent vulnerabilities have been discovered that could potentially compromise the security of applications relying on these packages.

Vulnerability Detail

The vulnerabilities identified in PHP include issues with handling PHAR files, parsing URLs with passwords, and processing malformed XML data in the SOAP extension. These vulnerabilities could allow remote attackers to cause PHP to crash, leading to denial of service, or to manipulate data, potentially resulting in sensitive information exposure or server-side request forgery attacks. Specifically, the vulnerabilities are tracked under CVE-2020-7068, CVE-2020-7071, CVE-2021-21702, CVE-2021-21704, and CVE-2021-21705.

How To Fix

Minimum fixed version

5.5.9+dfsg-1ubuntu4.29+esm14

This is the first release that contains the fix.

sudo apt-get install --only-upgrade php5

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

If immediate patching is not feasible, consider disabling the use of PHAR files and restricting URL parsing in your PHP configuration as a temporary workaround. This can be done by modifying the php.ini file:

; Disable PHAR phar.readonly = On

; Restrict URL parsing allow_url_fopen = Off allow_url_include = Off

Conclusion

The vulnerabilities identified in the PHP packages php5 and php7.0 pose significant risks to web applications. It is crucial for developers and system administrators to promptly update their PHP installations to the patched versions to mitigate these risks. Utilizing tools like Vulert can help monitor and alert for open-source vulnerabilities in real-time.

See every vulnerability recorded for php5 →

Share this vulnerability

FAQ

The main vulnerabilities include issues with PHAR file handling, URL parsing, and XML data processing, which can lead to denial of service and data exposure.

You can use Vulert's playground at Vulert Scanner to check if your application is affected by these vulnerabilities without needing to sign up.

If you cannot update immediately, consider applying temporary workarounds such as disabling PHAR files and restricting URL parsing in your PHP configuration.

While specific exploits may not be publicly available, the vulnerabilities could potentially be exploited by attackers to cause service disruptions or data breaches.

It is recommended to regularly check for vulnerabilities, ideally on a weekly basis, and to stay updated with security advisories related to your software dependencies.

Related vulnerabilities

Recent vulnerabilities recorded for php5.

How To Fix

Minimum fixed version

5.5.9+dfsg-1ubuntu4.29+esm14

This is the first release that contains the fix.

sudo apt-get install --only-upgrade php5

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback