CVE-2022-6471: Malicious code in test-code-01x (npm)

test-code-01x Updated 02 Oct 2025

Summary

20/06/2022
CRITICAL
No i
Critical
Not published

MAL-2022-6471: Malicious code in test-code-01x (npm). Affected versions are not published. 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 Penetration testing for web, API and mobile Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

The test-code-01x package is an npm package used for testing purposes. It is designed to provide developers with a set of tools and utilities to facilitate the testing of their code. The package is widely used in the npm ecosystem and is typically installed as a development dependency in projects. However, the package has been found to contain malicious code, which poses a significant security risk to any computer that has it installed or running.

Vulnerability Detail

The test-code-01x package has been compromised and contains malicious code. This code can give full control of the affected computer to an outside entity, compromising the security of the system. Any secrets and keys stored on the computer should be rotated immediately from a different computer to prevent unauthorized access. While removing the package is recommended, it may not guarantee the removal of all malicious software resulting from its installation.

How To Fix

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

npm uninstall test-code-01x

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

There is no specific workaround mentioned for this vulnerability. It is recommended to follow the steps outlined in the 'how_to_fix' section to mitigate the risk and ensure the security of the system.

Conclusion

The test-code-01x package has been found to contain malicious code, posing a significant security risk to any computer that has it installed or running. It is crucial to take immediate action to mitigate the risk, including rotating secrets and keys, removing the package, and performing a thorough security audit. For further support on vulnerability remediation, please contact DevNack.com.

See every vulnerability recorded for test-code-01x →

Share this vulnerability

FAQ

The impact of this vulnerability is severe as it can give full control of the affected computer to an outside entity. This can lead to unauthorized access to sensitive information, compromise of security measures, and potential misuse of the compromised system.

You can use the Vulert Playground (https://vulert.com/scanner) to check if your application is affected by this vulnerability. Simply provide the package-lock.json file of your project, and Vulert will analyze it in real-time to identify any open-source vulnerabilities, including this one.

Yes, the recommended fix for this vulnerability is to rotate all secrets and keys stored on the affected computer from a different, secure computer, remove the test-code-01x package, and perform a thorough security audit to identify any potential unauthorized access or compromise resulting from the presence of the malicious code.

While removing the test-code-01x package is recommended, it may not guarantee the removal of all malicious software resulting from its installation. It is crucial to rotate all secrets and keys stored on the affected computer and perform a thorough security audit to ensure the overall security of the system.

If you find any unauthorized access or compromise resulting from this vulnerability, it is crucial to take immediate action. This includes isolating the affected system from the network, investigating the extent of the compromise, and implementing appropriate security measures to prevent further unauthorized access or damage.

How To Fix

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

npm uninstall test-code-01x

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