MAL-2026-5295

See a problem?
Import Source
https://github.com/ossf/malicious-packages/blob/main/osv/malicious/pypi/coolbox/MAL-2026-5295.json
JSON Data
https://api.osv.dev/v1/vulns/MAL-2026-5295
Aliases
Published
2026-06-06T06:13:57Z
Modified
2026-06-29T21:11:30.547740309Z
Summary
Malicious code in coolbox (PyPI)
Details

-= Per source details. Do not edit below this line.=-

Source: amazon-inspector (c55bfdad112134e980af7568a9138be1e4b940f7bfbeebad2b0f85d9337a0f44)

The wheel installs coolbox-setup.pth, a Python path-configuration file that Python auto-loads at every interpreter startup (any python invocation system-wide, not just import coolbox). The.pth uses exec() on an obfuscated string that downloads the Bun JavaScript runtime from https://github.com/oven-sh/bun/releases/download/bun-v1.3.13/bun-{platform}-{arch}.zip to /tmp/b/bun, chmods it executable, and runs a glob-located _index.js sibling under it. A .bun_ran sentinel file gates one-shot execution. CoolBox is advertised as a Python genomics/Jupyter visualization library (GangCaoLab, BMC Bioinformatics 2021) and has no legitimate need to install or execute a JavaScript runtime. The release also shows hijack fingerprints: coolbox/__init__.py declares __version__ = '0.4.0' while the dist-info METADATA declares Version: 0.4.1, and RECORD additively references the prior coolbox-0.4.0.dist-info/ alongside the new coolbox-setup.pth — consistent with a malicious republish layered on top of the legitimate prior release. The _index.js payload is not listed in RECORD, indicating it is staged from another source. Installer harm: any system that installs this wheel will execute attacker-controlled JavaScript under the Bun runtime on every subsequent python startup, with the user's privileges.

Source: kam193 (5c2dc2f03691017c67f2ef9805c4974416d935298b4748b033bfb7f487ede251)

Versions 0.4.1, 0.4.2 were compromised.

Compromised packages start an obfuscated infostealer. The infostealer is a heavily obfuscated JavaScript code executed using Bun runtime on Python startup. It collectes all kinds of sensitive data, including API keys, credentials to package repositories, cryptocurrency assets, password manager data. Infostealer actively queries online services to collect additional secrets as well as attempts to gain persistence and spread further by publishing infected packages using collected credentials. Data are exfiltrated likely using Github. The code seems to threaten to wipe the user's data if it detects invalid GitHub tokens. Cleanup should be done with caution.

It seems to be related to the recent Mini Shai Hulud campaign.


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

Campaign: 2026-06-compr-woodpecker

Reasons (based on the campaign):

  • compromised-package

  • exfiltration-env-variables

  • exfiltration-cloud-tokens

  • exfiltration-credentials

  • abuses-pth

  • obfuscation

  • infostealer

  • The package contains code to detect if it is running in a sandbox environment.

  • exfiltration-crypto

  • files-exfiltration

  • destructive-actions

Database specific
{
    "malicious-packages-origins": [
        {
            "versions": [
                "0.4.1",
                "0.4.2"
            ],
            "sha256": "5c2dc2f03691017c67f2ef9805c4974416d935298b4748b033bfb7f487ede251",
            "source": "kam193",
            "modified_time": "2026-06-06T06:13:57Z",
            "import_time": "2026-06-07T15:57:34.745836928Z",
            "id": "pypi/2026-06-compr-woodpecker/coolbox"
        },
        {
            "versions": [
                "0.4.1",
                "0.4.2"
            ],
            "sha256": "f0d5fde6bb63a9bdd47ede4cdf19e54d636016848ad9e780a0db4d96138c2d6f",
            "modified_time": "2026-06-06T06:13:57Z",
            "source": "kam193",
            "id": "pypi/2026-06-compr-woodpecker/coolbox",
            "import_time": "2026-06-08T11:41:02.516930226Z"
        },
        {
            "versions": [
                "0.4.1",
                "0.4.2"
            ],
            "sha256": "6120318ad0beb72f5fe01fbceb6a2bb29b2c93c277b4a5fe2b5d7f148bcd30d8",
            "source": "kam193",
            "modified_time": "2026-06-07T15:36:23Z",
            "import_time": "2026-06-08T19:19:19.173271277Z",
            "id": "pypi/2026-06-compr-woodpecker/coolbox"
        },
        {
            "versions": [
                "0.4.1",
                "0.4.2"
            ],
            "sha256": "da9448cdfb3593bc9434cbc09686ea2d8bc73f5b531e45d13229949e14aadbf8",
            "modified_time": "2026-06-07T15:36:23Z",
            "source": "kam193",
            "import_time": "2026-06-09T07:48:29.633986211Z",
            "id": "pypi/2026-06-compr-woodpecker/coolbox"
        },
        {
            "versions": [
                "0.4.1"
            ],
            "sha256": "c55bfdad112134e980af7568a9138be1e4b940f7bfbeebad2b0f85d9337a0f44",
            "modified_time": "2026-06-12T19:02:16Z",
            "source": "amazon-inspector",
            "id": "IN-MAL-2026-005804",
            "import_time": "2026-06-12T19:43:35.178454373Z"
        }
    ]
}
References
Credits

Affected packages

PyPI / coolbox

Package

Affected ranges

Affected versions

0.*
0.4.1
0.4.2

Database specific

indicators
{
    "package_integrity": [
        {
            "filename": "coolbox-0.4.1-py3-none-any.whl",
            "hashes": {
                "sha256": "676713804352b10f813c3371abffaac2ae670a53dbd924ebaae2e3b190b91eae",
                "md5": "5ca17f568e14c68bbd1df8357fbe8964",
                "blake2b_256": "9f02a14a518d8d7732b6cf4b6bf3eb6c0e9f047cfc1596ef56a15541d6350206"
            }
        }
    ],
    "evidence_files": [
        {
            "sha256": "c539766062555d47716f8432e73adbe3a0c0c954a0b6c4005017a668975e275c",
            "path": "coolbox-setup.pth",
            "tlsh": "4911c02e429385b0d975d646830b19f4afdb8ce28fc79506c8d8d4c1a7b2e50e3b7684"
        },
        {
            "sha256": "5a956a1a5bd6e3f07f3c148daba57974d2e6a7a4b2d7c008770eb45399cd6343",
            "path": "coolbox-0.4.1.dist-info/RECORD",
            "tlsh": "6bf1e999695ae08e37830a92ab414bb53f654617f0c3345cab008739f3cd7fad93e646"
        }
    ]
}
source
"https://github.com/ossf/malicious-packages/blob/main/osv/malicious/pypi/coolbox/MAL-2026-5295.json"
cwes
[
    {
        "description": "The product contains code that appears to be malicious in nature.",
        "name": "Embedded Malicious Code",
        "cweId": "CWE-506"
    }
]