Critical Malicious Code Vulnerability in recaptcha-cors Package
Summary
MAL-2026-397: Malicious code in recaptcha-cors (npm). Affected versions are not published. No fix is published. 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
The recaptcha-cors package is an npm library designed to facilitate cross-origin requests for Google's reCAPTCHA service. It is commonly used in web applications to enhance security by preventing automated abuse. However, this package has been compromised, introducing malicious code that poses significant security risks to any system utilizing it.
Vulnerability Detail
The vulnerability stems from the presence of embedded malicious code within the recaptcha-cors package. This code can fully compromise any computer that has the package installed or running, allowing unauthorized access to sensitive information such as secrets and keys. The malicious nature of the code has been confirmed by security researchers, and it is classified under CWE-506, indicating that the product contains code that appears to be malicious in nature. Users are advised to treat any system with this package as fully compromised.
How To Fix
This package is malicious. Remove it and rotate any credentials it could have accessed.
npm uninstall recaptcha-cors
If it arrived as a transitive dependency, remove the package that pulled it in, then reinstall.
Tip — Not sure whether your app is affected? Vulert can check the versions your app actually runs. Scan free →
Workaround
Currently, there are no effective workarounds to mitigate the risks posed by the malicious code in the recaptcha-cors package. The only recommended action is to uninstall the package and secure your system.
Conclusion
The recaptcha-cors package has been identified as containing malicious code, posing a severe risk to any systems using it. Immediate action is required to remove the package and secure any sensitive information. Users are encouraged to utilize tools like Vulert for ongoing vulnerability monitoring.
See every vulnerability recorded for recaptcha-cors →
FAQ
recaptcha-cors is an npm package used to facilitate cross-origin requests for Google's reCAPTCHA service, enhancing web application security.
The malicious code can compromise your system, allowing unauthorized access to sensitive information and potentially leading to further exploitation.
You should immediately uninstall the recaptcha-cors package and rotate any secrets or keys stored on the affected machine.
No, there is currently no patched version available for the recaptcha-cors package, making removal the only option.
You can use Vulert, which monitors and alerts in real-time for open-source vulnerabilities using just the package-lock.json file. You can also check your application for vulnerabilities using the Vulert playground without any signup.