Malicious Code Vulnerability in react-query-core-utils Package
Summary
MAL-2026-1837: Malicious code in react-query-core-utils (npm). Affects react-query-core-utils versions 4.4.1 – 4.5.3. 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 react-query-core-utils package is a utility library designed to enhance the functionality of React Query, a popular data-fetching library for React applications. It provides various helper functions and utilities that streamline the management of server state in React applications. However, certain versions of this package have been found to contain malicious code, posing a significant security risk to applications that rely on it.
Vulnerability Detail
The vulnerability in the react-query-core-utils package stems from the inclusion of malicious code that can compromise the security of applications utilizing this library. This code may lead to unauthorized access, data leakage, or other harmful actions within the application. The affected versions include 4.4.1 through 4.5.3, which were identified as containing this malicious code. The origin of this vulnerability is linked to a malicious actor who has injected harmful scripts into the package, which can execute when the package is installed or used in a project.
How To Fix
This package is malicious. Remove it and rotate any credentials it could have accessed.
npm uninstall react-query-core-utils
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
If immediate updating is not feasible, consider removing the react-query-core-utils package from your project and replacing its functionality with alternative libraries or custom implementations until a safe version can be installed.
Conclusion
The react-query-core-utils package has been found to contain malicious code in certain versions, posing a significant security risk. It is crucial for developers using this package to update to the latest patched version to mitigate potential threats. Utilizing tools like Vulert can help monitor for such vulnerabilities in real-time.
See every vulnerability recorded for react-query-core-utils →
FAQ
The affected versions include 4.4.1 through 4.5.3.
You can use the Vulert platform to monitor and alert for open-source vulnerabilities in your software. Visit Vulert Scanner to check if your application is affected without requiring any signup.
Using an affected version may lead to unauthorized access, data leakage, or other harmful actions within your application, compromising its security.
Yes, you can temporarily remove the react-query-core-utils package and replace its functionality with alternative libraries or custom code until you can update to a safe version.
The vulnerability was identified by ReversingLabs, a cybersecurity firm specializing in threat intelligence.