Denial of Service Vulnerability in php-phpseclib3: CVE-2023-49316

php-phpseclib3 Updated 02 Oct 2025

Summary

27/11/2023
N/A
No i
High
7.5

UBUNTU-CVE-2023-49316: In Math/BinaryField.php in phpseclib 3 before 3.0.34, excessively large degrees can lead to a denial of service. Affects php-phpseclib3 versions 3.0.10-1 – 3.0.9-1. No fix is published. 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 Mobile apps built by Devnack Design, build and launch iOS and Android apps with a senior product team. From idea to store release Start a project

Background

php-phpseclib3 is a popular library for secure communications in PHP, providing cryptographic functions and protocols. It is widely used in various applications for tasks such as encryption, decryption, and secure data transmission. The library is designed to be easy to use and integrate into PHP projects, making it a go-to choice for developers needing secure functionality. However, it has been identified to have a vulnerability that can lead to denial of service under certain conditions.

Vulnerability Detail

The vulnerability, identified as CVE-2023-49316, exists in the Math/BinaryField.php file of phpseclib 3 versions prior to 3.0.34. It allows attackers to exploit excessively large degrees, which can result in a denial of service. This means that an attacker could potentially cause the application to become unresponsive or crash, impacting the availability of the service. The issue arises from improper handling of input values that exceed expected limits, leading to resource exhaustion.

How To Fix

No fixed version is published for this vulnerability.

Tip — Not sure whether your app is affected? Vulert can check the versions your app actually runs. Scan free →

Workaround

If updating the package is not immediately possible, consider implementing input validation to restrict the size of degrees being processed. This can help mitigate the risk of denial of service by ensuring that excessively large inputs are not accepted by the application.

Conclusion

CVE-2023-49316 is a significant vulnerability in the php-phpseclib3 library that can lead to denial of service. It is crucial for developers using this library to update to the latest version to ensure their applications remain secure. Monitoring tools like Vulert can assist in identifying vulnerabilities in your software.

See every vulnerability recorded for php-phpseclib3 →

Share this vulnerability

FAQ

CVE-2023-49316 is a vulnerability in the php-phpseclib3 library that can lead to denial of service due to excessively large degrees.

Versions of php-phpseclib3 prior to 3.0.34 are affected by this vulnerability.

You can use Vulert to monitor and alert for open-source vulnerabilities in your software. Visit Vulert Scanner to check if your application is affected without any signup.

The main consequence is denial of service, which can make your application unresponsive or crash, affecting user access and functionality.

The best protection is to update to the latest patched version of php-phpseclib3. Additionally, implementing input validation can help mitigate risks.

Related vulnerabilities

Recent vulnerabilities recorded for php-phpseclib3.

How To Fix

No fixed version is published for this vulnerability.

Tip — Not sure whether your app is affected? Vulert can check the versions your app actually runs. 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