# MAL-2026-10215: Malicious code in fast-dotenv (PyPI)


- **Type:** Malicious package
- **Package:** `fast-dotenv` (PyPI)
- **Published:** 12 Jul 2026

## What is MAL-2026-10215?

MAL-2026-10215 is a malicious package in fast-dotenv, published on 12 Jul 2026. 

### Official description

The package presents itself as a.env loader but on load()/config() spawns a background thread that, after a 72–96 hour activation delay jittered by hostname hash, decodes base64-obfuscated dead-drop URLs (a GitHub gist under opensource-crypto and a GitLab snippet under devtool-labs/config-snippets) to retrieve a JSON C2 configuration (host, port, path, fallback) and POSTs collected data to https://{c2}:{port}{path}. Data collected includes host/environment identity, environment variables whose names contain key/secret/token/password/auth/private/wallet/seed/mnemonic, and an enumeration of ~/.ssh/ (id_rsa, id_ed25519, id_ecdsa, config, known_hosts). The C2 URLs are stored as base64 literals in _CONFIG_SOURCES with cover comments describing them as documentation examples, hiding the network destinations from plain-text inspection. The long dormancy, remote-configurable destination, base64-obfuscated dead drops, and cover comments together are the shape of a staged supply-chain credential stealer.

When using the library, it schedules a delayed malware activation. Malicious code contacts remote URLs to get C2 location, then performs machine fingerprinting, including looking for sensitive environmental variables and SSH keys. The code seems not to exfiltrate their content in the analyzed version. Additionally, the embeded configuration URLs did not exist, but they led to related C2 configurations from the same GitHub account, which also seems to have created repositories with similar malicious code in other languages.

---

Category: MALICIOUS - The campaign has clearly malicious intent, like infostealers.

Campaign: 2026-07-fast-dotenv

Reasons (based on the campaign):

 - The package contains code to exfiltrate basic data from the system, like IP or username. It has a limited risk.

 - exfiltration-env-variables

 - exfiltration-ssh-keys

 - action-hidden-in-lib-usage

## What should I do about MAL-2026-10215?

Remove the package from your dependencies and lockfiles, then rotate any secrets on machines where it was installed.

## Fix prompt for AI coding agents

```text
MAL-2026-10215 is a malicious package: fast-dotenv (PyPI). Every version was published to cause harm.

Task:
1. Search this repository's dependency manifests and lockfiles for the package, including transitive dependencies.
2. If it is present, remove it, regenerate the lockfile with the project's package manager, and replace whatever it was used for.
3. List any CI runners, developer machines or containers that installed it, so their secrets can be rotated.
4. If the package is not used anywhere, say so and change nothing.

Reference: https://insights.sbomify.com/MAL-2026-10215/ (Markdown: https://insights.sbomify.com/MAL-2026-10215/index.md)
```

## Sources

- OSV: https://osv.dev/vulnerability/MAL-2026-10215

---
From sbomify Insights: https://insights.sbomify.com/MAL-2026-10215/
Summaries are generated and may contain mistakes; the official description above is the record.
