Denial of Service Vulnerability in Node-Semver Package

node-semver Updated 02 Oct 2025

Summary

23/01/2017
N/A
Yes i
Unrated
Not published

DEBIAN-CVE-2015-8855: The semver package before 4.3.2 for Node.js allows attackers to cause a denial of service (CPU consumption) via a long version string, aka a "regular expression denial of service (ReDoS).". Affects node-semver versions < 5.3.0-1. Fixed in 5.3.0-1. 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 MarkAI Find prospects already talking about the problem you solve AI watches the communities your customers use to find qualified prospects, then alerts you when a conversation is worth joining. See MarkAI

Background

The node-semver package is a widely used library in Node.js environments that provides semantic versioning utilities. It allows developers to manage version numbers in a consistent manner, ensuring compatibility and proper dependency management. However, prior to version 4.3.2, the package was susceptible to a vulnerability that could lead to denial of service attacks due to inefficient handling of long version strings.

Vulnerability Detail

The vulnerability identified as DEBIAN-CVE-2015-8855 affects the node-semver package versions before 4.3.2. It allows attackers to exploit the package by providing excessively long version strings, which can lead to significant CPU consumption, effectively causing a denial of service (DoS). This is categorized as a regular expression denial of service (ReDoS) attack, where the regular expressions used in the package can be manipulated to consume resources disproportionately, impacting the performance of applications relying on this package.

How To Fix

Minimum fixed version

5.3.0-1

This is the first release that contains the fix.

sudo apt-get install --only-upgrade node-semver

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

Workaround

If immediate updating is not feasible, consider validating version strings before processing them to ensure they do not exceed reasonable lengths, thereby mitigating the risk of triggering the vulnerability.

Conclusion

The node-semver package has a known vulnerability that can lead to denial of service attacks through improper handling of version strings. It is crucial to update to the patched version to mitigate this risk. Additionally, using tools like Vulert can help in monitoring and managing vulnerabilities in your software dependencies effectively.

See every vulnerability recorded for node-semver →

Share this vulnerability

FAQ

The vulnerability allows for denial of service attacks through excessive CPU consumption caused by long version strings.

Versions prior to 4.3.2 are affected by this vulnerability.

You can use the Vulert playground at Vulert Scanner to check if your application is affected by this vulnerability without needing to sign up.

Implement input validation for version strings to limit their length and reduce the risk of triggering the vulnerability.

Yes, Vulert can monitor and alert you in real-time for open-source vulnerabilities using just a manifest file like package-lock.json.

Related vulnerabilities

Recent vulnerabilities recorded for node-semver.

How To Fix

Minimum fixed version

5.3.0-1

This is the first release that contains the fix.

sudo apt-get install --only-upgrade node-semver

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