Vulnerabilities in pkg:npm/react-native-document-picker
PACKAGECVE-2024-25466 is a HIGH (CVSS 7.3) path traversal vulnerability (CWE-26: Path Traversal: '/dir/../filename') affecting React native document picker libraries in the npm ecosystem. The issue involves react native document picker directory traversal vulnerability. Remediation is available by upgrading affected packages to version 9.1.1, 8.2.2.
pkg:npm/react-native-document-picker
Vulnerability advisories affecting package pkg:npm/react-native-document-picker. Select an advisory below to view technical details or fixes.
| Advisory ID | CVE / NVD | Severity | Summary |
|---|---|---|---|
| GHSA-pmgm-h3cc-m4hj | CVE-2024-25466 | HIGH | React Native Document Picker Directory Traversal vulnerability |
CVE-2024-25466 at a Glance
Security Impact
CVSS: 7.3
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:L/I:H/A:H).
How to Fix CVE-2024-25466
To remediate this vulnerability, upgrade all affected React native document picker dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
npm install react-native-document-picker@9.1.1
npm install react-native-document-picker@8.2.2
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
npm ls react-native-document-picker
How to Check if You Are Affected
To determine whether your Node.js application is affected by CVE-2024-25466, inspect your project dependencies using npm:
npm ls react-native-document-picker
Analyze the terminal output to locate any version of React native document picker in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 9.1.1), your application is affected.
Note: The npm ls react-native-document-picker command inspects dependencies declared in your package.json and lockfile; it does not perform automated runtime dynamic scanning.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-26: Path Traversal: '/dir/../filename', where the product uses external input to construct a pathname that should be within a restricted directory, but it does not properly neutralize "/dir/../filename" sequences that can resolve to a location that is outside of that directory. In React native document picker, 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-2024-25466 Affected React native document picker Versions
2 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
react-native-document-picker
|
npm |
≥ 9.0.0
< 9.1.1
|
9.1.1
|
|
react-native-document-picker
|
npm |
< 8.2.2
|
8.2.2
|
References
Frequently Asked Questions
What is CVE-2024-25466?
Which React native document picker versions are affected?
What version fixes CVE-2024-25466?
Is react-native-document-picker affected?
What is the CVSS score of CVE-2024-25466?
What CWE is associated with CVE-2024-25466?
How can I check npm dependencies for CVE-2024-25466?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-pmgm-h3cc-m4hj",
"modified" : "2025-03-27T18:38:48Z",
"published" : "2024-02-16T09:30:26Z",
"aliases" : [ "CVE-2024-25466" ],
"summary" : "React Native Document Picker Directory Traversal vulnerability",
"details" : "Directory Traversal vulnerability in React Native Document Picker before 8.2.2 and 9.x before 9.1.1 allows a local attacker to execute arbitrary code via a crafted script to the Android library component.",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:L/I:H/A:H"
}, {
"type" : "CVSS_V4",
"score" : "CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:L/VI:H/VA:H/SC:N/SI:N/SA:N"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "npm",
"name" : "react-native-document-picker"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "9.0.0"
}, {
"fixed" : "9.1.1"
} ]
} ]
}, {
"package" : {
"ecosystem" : "npm",
"name" : "react-native-document-picker"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "8.2.2"
} ]
} ]
} ],
"references" : [ {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2024-25466"
}, {
"type" : "WEB",
"url" : "https://github.com/rnmods/react-native-document-picker/pull/698"
}, {
"type" : "WEB",
"url" : "https://github.com/rnmods/react-native-document-picker/commit/1ae7cb217d23a551bff86ad10c7ae6f5e074490f"
}, {
"type" : "WEB",
"url" : "https://github.com/rnmods/react-native-document-picker/commit/ad0b5e58252eba56a5a3b22311a66ffa5e65cffe"
}, {
"type" : "WEB",
"url" : "https://github.com/FixedOctocat/CVE-2024-25466/tree/main"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/rnmods/react-native-document-picker"
}, {
"type" : "WEB",
"url" : "https://github.com/rnmods/react-native-document-picker/blob/0be5a70c3b456e35c2454aaf4dc8c2d40eb2ab47/android/src/main/java/com/reactnativedocumentpicker/RNDocumentPickerModule.java"
}, {
"type" : "WEB",
"url" : "https://github.com/rnmods/react-native-document-picker/releases/tag/v8.2.2"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-26" ],
"severity" : "HIGH",
"github_reviewed" : true,
"github_reviewed_at" : "2024-02-16T23:37:06Z",
"nvd_published_at" : "2024-02-16T09:15:08Z"
}
}