MAL-2026-7021

See a problem?
Import Source
https://github.com/ossf/malicious-packages/blob/main/osv/malicious/npm/@vite-js/ui/MAL-2026-7021.json
JSON Data
https://api.test.osv.dev/v1/vulns/MAL-2026-7021
Aliases
  • GHSA-x4cp-w826-x466
Published
2026-07-08T20:37:36Z
Modified
2026-07-20T01:04:40.606932665Z
Summary
Malicious code in @vite-js/ui (npm)
Details

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

Source: amazon-inspector (476576198de86a58304788ac79ac3c8ca21b5029d9e824e3ffab41f539146c3b)

Package @vite-js/ui impersonates the official vite package: package.json declares author 'Evan You', homepage 'https://vitejs.dev', ships an unmodified Vite README and a near-verbatim Vite dist/ tree, and exposes bin.vite pointing at bin/vite.js — so any developer who installs this and runs the documented vite command executes this package's CLI. Appended to the legitimate Vite bin code in bin/vite.js is a heavily obfuscated IIFE that reconstructs strings from a packed blob via a custom shuffler (keyed by 4606094, with %/#1/#0 substitutions) to hide the identifiers http, child_process, JSON, eval, and spawn. At runtime it issues a JSON-RPC HTTP fetch, XOR-decodes the response using a key derived from a remote field, passes the decoded buffer to eval(r), and then calls child_process.spawn with {detached:true, stdio:..., windowsHide:true} on a second fetched-and-decoded payload — a hidden, detached process that outlives the CLI invocation and provides a persistent execution channel. A short time-gate throttles re-trigger. Legitimate Vite has no such bootstrap; the custom string-array obfuscator covers only the network/eval/spawn surface, which is the canonical dropper-plus-backdoor shape.

Source: ghsa-malware (2a50c8b2f094ae17cba108b06050cbe0f67744af814caa7a3e834e5f6653aaee)

Any computer that has this package installed or running should be considered fully compromised. All secrets and keys stored on that computer should be rotated immediately from a different computer. The package should be removed, but as full control of the computer may have been given to an outside entity, there is no guarantee that removing the package will remove all malicious software resulting from installing it.

Database specific
{
    "malicious-packages-origins": [
        {
            "modified_time": "2026-07-08T20:37:36Z",
            "sha256": "914257e4d1eecae3fc48e98c8a2a406ed8021ed159c4a43a96c57453d0a1f320",
            "import_time": "2026-07-08T21:27:50.06242356Z",
            "id": "IN-MAL-2026-008609",
            "source": "amazon-inspector",
            "versions": [
                "7.15.16"
            ]
        },
        {
            "modified_time": "2026-07-14T03:33:24Z",
            "versions": [
                "7.15.10"
            ],
            "sha256": "476576198de86a58304788ac79ac3c8ca21b5029d9e824e3ffab41f539146c3b",
            "id": "IN-MAL-2026-010363",
            "source": "amazon-inspector",
            "import_time": "2026-07-14T04:31:58.959303925Z"
        },
        {
            "import_time": "2026-07-20T00:57:10.771536244Z",
            "ranges": [
                {
                    "events": [
                        {
                            "introduced": "0"
                        }
                    ],
                    "type": "SEMVER"
                }
            ],
            "sha256": "2a50c8b2f094ae17cba108b06050cbe0f67744af814caa7a3e834e5f6653aaee",
            "id": "GHSA-x4cp-w826-x466",
            "source": "ghsa-malware",
            "modified_time": "2026-07-20T00:19:28Z"
        }
    ]
}
References
Credits

Affected packages

npm / @vite-js/ui

Package

Affected ranges

Type
SEMVER
Events
Introduced
0Unknown introduced version / All previous versions are affected

Affected versions

7.*
7.15.10
7.15.16

Database specific

indicators
{
    "package_integrity": [
        {
            "filename": "ui-7.15.16.tgz",
            "hashes": {
                "sha1": "8950e9cff4e641854d7e736213fe7b934b132d99",
                "sha512_sri": "sha512-EUmASs+yOowDRmiuBystWtkyYL8w3h2oyBoFitr5ogAcWuFzLZDnfPCXjMAiWwDaKl8Up8i3t5li1yg5wavnaA=="
            }
        }
    ],
    "evidence_files": [
        {
            "tlsh": "89e15c41e1dcb8561ba0b59ab49e49096c799423ef4cc984f3bcf2506fdb12852850f9",
            "sha256": "16ac3a574bd4bd9836918033852cc1528a50ac2fc9231ab9605bc2b20e8bea7b",
            "path": "bin/vite.js"
        },
        {
            "tlsh": "c9a1bc21cea88da31ad424e9ec790142f13485578e65fc18339d57ad0f4d26f327ebae",
            "sha256": "af314d461d5ac49b9133bac01746842996e7f4636a6fa2e3d6541eadf67f391b",
            "path": "package.json"
        }
    ]
}
cwes
[
    {
        "description": "The product contains code that appears to be malicious in nature.",
        "name": "Embedded Malicious Code",
        "cweId": "CWE-506"
    },
    {
        "description": "The product contains code that appears to be malicious in nature.",
        "name": "Embedded Malicious Code",
        "cweId": "CWE-506"
    },
    {
        "description": "The product contains code that appears to be malicious in nature.",
        "name": "Embedded Malicious Code",
        "cweId": "CWE-506"
    }
]
source
"https://github.com/ossf/malicious-packages/blob/main/osv/malicious/npm/@vite-js/ui/MAL-2026-7021.json"