Vulnerabilities in pkg:pypi/docarray
PACKAGECVE-2025-5150 is a MODERATE (CVSS 6.3) docarray prototype pollution vulnerability (CWE-1321: Improperly Controlled Modification of Object Prototype Attributes ('Prototype Pollution')) affecting Docarray libraries in the PyPI ecosystem. The issue involves docarray prototype pollution. Remediation is available in the latest vendor maintenance releases.
pkg:pypi/docarray
Vulnerability advisories affecting package pkg:pypi/docarray. Select an advisory below to view technical details or fixes.
| Advisory ID | CVE / NVD | Severity | Summary |
|---|---|---|---|
| GHSA-j9wp-865g-rf48 | CVE-2025-5150 | MODERATE | docarray prototype pollution |
CVE-2025-5150 at a Glance
Security Impact
CVSS: 6.3
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:L).
How to Fix CVE-2025-5150
To remediate this vulnerability, upgrade all affected Docarray dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
pip install docarray>=Latest secure release
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
pip show docarray
How to Check if You Are Affected
To determine whether your Python environment is affected by CVE-2025-5150, inspect your installed packages using pip:
pip show docarray
Analyze the terminal output to locate any version of Docarray in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than the patched release), your application is affected.
Note: The pip show docarray command checks currently installed packages in your active Python environment.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-1321: Improperly Controlled Modification of Object Prototype Attributes ('Prototype Pollution'), where the product receives input from an upstream component that specifies attributes that are to be initialized or updated in an object, but it does not properly control modifications of attributes of the object prototype. In Docarray, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
CVE-2025-5150 Affected Docarray Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
docarray
|
PyPI |
≤ 0.40.1
|
|
References
Frequently Asked Questions
What is CVE-2025-5150?
Which Docarray versions are affected?
What version fixes CVE-2025-5150?
Is docarray affected?
What is the CVSS score of CVE-2025-5150?
What CWE is associated with CVE-2025-5150?
How can I check PyPI dependencies for CVE-2025-5150?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-j9wp-865g-rf48",
"modified" : "2025-06-04T20:52:34Z",
"published" : "2025-05-25T15:30:32Z",
"aliases" : [ "CVE-2025-5150" ],
"summary" : "docarray prototype pollution",
"details" : "A vulnerability was found in docarray up to 0.40.1. It has been rated as critical. Affected by this issue is the function __getitem__ of the file /docarray/data/torch_dataset.py of the component Web API. The manipulation leads to improperly controlled modification of object prototype attributes ('prototype pollution'). The attack may be launched remotely. The exploit has been disclosed to the public and may be used. The vendor was contacted early about this disclosure but did not respond in any way.",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:L"
}, {
"type" : "CVSS_V4",
"score" : "CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:L/VI:L/VA:L/SC:N/SI:N/SA:N"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "PyPI",
"name" : "docarray"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"last_affected" : "0.40.1"
} ]
} ]
} ],
"references" : [ {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2025-5150"
}, {
"type" : "WEB",
"url" : "https://gist.github.com/superboy-zjc/56502343bcb12eb653081b426debf2c8"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/docarray/docarray"
}, {
"type" : "WEB",
"url" : "https://vuldb.com/?ctiid.310238"
}, {
"type" : "WEB",
"url" : "https://vuldb.com/?id.310238"
}, {
"type" : "WEB",
"url" : "https://vuldb.com/?submit.574696"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-1321", "CWE-94" ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2025-05-27T19:54:33Z",
"nvd_published_at" : "2025-05-25T15:15:22Z"
}
}