Malicious code in basecrypt (npm)

basecrypt Updated 02 Oct 2025

Summary

25/06/2024
CRITICAL
No i
Critical
Not published

MAL-2024-1813: Malicious code in basecrypt (npm). Affects basecrypt versions 3.1.0. 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 basecrypt package is an npm package used for cryptographic operations. It provides functions for encrypting and decrypting data using various encryption algorithms. The package is widely used in JavaScript applications for securing sensitive information. However, a vulnerability has been discovered in the basecrypt package that allows the execution of malicious code.

Vulnerability Detail

The vulnerability in basecrypt (npm) is due to the presence of malicious code in the package. This code can be exploited by an attacker to execute arbitrary commands on the affected system. The malicious code is injected into the package during the build process, making it difficult to detect. Once the package is installed and used in an application, the attacker can gain unauthorized access to the system and potentially compromise sensitive data. The impact of this vulnerability can be severe, leading to data breaches and unauthorized access to systems.

How To Fix

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

npm uninstall basecrypt

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 known workaround for this vulnerability. It is crucial to update the package to the latest version as soon as possible to mitigate the risk of exploitation.

Conclusion

The basecrypt package has been found to contain malicious code, which can be exploited by attackers to execute arbitrary commands on the affected system. To mitigate this vulnerability, users should update the package to the latest version (3.1.1) that removes the malicious code. It is important to stay vigilant and keep software dependencies up to date to ensure the security of applications.

See every vulnerability recorded for basecrypt →

Share this vulnerability

FAQ

Basecrypt is an npm package used for cryptographic operations in JavaScript applications. It provides functions for encrypting and decrypting data using various encryption algorithms.

The vulnerability in basecrypt is caused by the presence of malicious code in the package. This code is injected during the build process and can be exploited by an attacker to execute arbitrary commands on the affected system.

The impact of this vulnerability can be severe. An attacker can gain unauthorized access to the system and potentially compromise sensitive data. This can lead to data breaches and unauthorized access to systems.

To fix the vulnerability, it is recommended to update the basecrypt package to the latest version (3.1.1) that removes the malicious code. Update your package.json file and run the package manager's update command to install the updated package.

There is no known workaround for this vulnerability. It is crucial to update the package to the latest version to mitigate the risk of exploitation.

How To Fix

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

npm uninstall basecrypt

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