Critical Malicious Code Vulnerability in react-qr-image Package

react-qr-image Updated 25 Nov 2025

Summary

24/11/2025
CRITICAL
No i
Critical
Not published

MAL-2025-191007: Malicious code in react-qr-image (npm). Affects react-qr-image versions 1.1.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

The react-qr-image package is a popular npm library used for generating QR codes in React applications. It allows developers to easily integrate QR code functionality into their projects, providing a seamless user experience. However, recent findings have revealed that this package has been compromised, containing malicious code that poses significant security risks to users and their systems.

Vulnerability Detail

The vulnerability originates from the discovery of malicious code embedded within the react-qr-image package. This code can compromise any computer that has the package installed, potentially allowing unauthorized access to sensitive information, including secrets and keys stored on the affected system. The malicious code can lead to a complete takeover of the computer, making it imperative for users to act swiftly to mitigate the risks associated with this vulnerability.

How To Fix

This package is malicious. Remove it and rotate any credentials it could have accessed.

npm uninstall react-qr-image

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

As a workaround, users should immediately rotate any secrets and keys stored on the affected computer from a different, secure machine. Additionally, consider using alternative libraries for QR code generation that are known to be secure and free from malicious code.

Conclusion

The react-qr-image package has been found to contain malicious code, posing serious security risks to users. It is essential to uninstall the package immediately and take necessary precautions to secure sensitive information. Users are encouraged to explore alternative libraries for QR code generation and utilize tools like Vulert for ongoing vulnerability monitoring.

See every vulnerability recorded for react-qr-image →

Share this vulnerability

FAQ

react-qr-image is an npm package that allows developers to generate QR codes in React applications easily.

The malicious code was identified through security assessments conducted by Amazon Inspector and reported by the GHSA.

If you have react-qr-image installed, you should immediately uninstall it and rotate any sensitive information stored on your system.

Yes, you can use Vulert, which monitors and alerts for open-source vulnerabilities using just your package-lock.json file. You can check your application at Vulert Scanner without needing to sign up.

Yes, consider using other QR code generation libraries that are verified to be secure, such as 'qrcode.react' or 'react-qr-code'.

How To Fix

This package is malicious. Remove it and rotate any credentials it could have accessed.

npm uninstall react-qr-image

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 →

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