Critical Vulnerabilities in Node.js: Denial of Service and Arbitrary Code Execution
Summary
USN-6418-1: nodejs vulnerabilities. Affects nodejs versions < 8.10.0~dfsg-2ubuntu0.4+esm3. Fixed in 8.10.0~dfsg-2ubuntu0.4+esm3. How to fix ↓
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.
No signup required · Results in about 60 seconds
Background
Node.js is a popular open-source runtime environment that allows developers to execute JavaScript code server-side. It is widely used for building scalable network applications. However, recent vulnerabilities have been identified that could potentially compromise the security of applications built on this platform, specifically in versions 8.10.0 and 10.19.0.
Vulnerability Detail
Two significant vulnerabilities have been discovered in Node.js. The first, identified as CVE-2021-22883, allows a remote attacker to cause a denial of service by tricking users into opening specially crafted input files. The second vulnerability, CVE-2021-22884, could enable an attacker to execute arbitrary code under certain conditions. Both vulnerabilities stem from improper handling of inputs, posing serious risks to application integrity and availability.
How To Fix
Minimum fixed version
8.10.0~dfsg-2ubuntu0.4+esm3
This is the first release that contains the fix.
sudo apt-get install --only-upgrade nodejs
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 implementing input validation to mitigate the risks associated with these vulnerabilities. Ensure that your application does not process untrusted input files without proper checks.
Conclusion
In summary, critical vulnerabilities have been identified in Node.js that could lead to denial of service and arbitrary code execution. It is crucial for users to update their Node.js installations to the patched versions to ensure the security of their applications. Additionally, using tools like Vulert can help monitor and alert for such vulnerabilities in real-time.
See every vulnerability recorded for nodejs →
FAQ
The main vulnerabilities are CVE-2021-22883, which allows denial of service, and CVE-2021-22884, which enables arbitrary code execution.
You can use Vulert's playground at Vulert Scanner to check if your application is affected by these vulnerabilities without needing to sign up.
Node.js versions 8.10.0 and 10.19.0 are impacted by these vulnerabilities.
The fix for Ubuntu 20.04 LTS does not require a subscription, while the fix for Ubuntu 18.04 LTS is available with Ubuntu Pro.
Implement input validation as a temporary workaround to mitigate the risks associated with these vulnerabilities.
References
Related vulnerabilities
Recent vulnerabilities recorded for nodejs.