CVE-2024-47166
One-level read path traversal in `/custom_component` in Gradio
CVE-2024-47166 is a low vulnerability (CVSS 2.3) in Gradio-app Gradio, published October 10, 2024. No source lists public exploit code. EPSS puts the chance of exploitation in the next 30 days at 0.44%, the 37th percentile. Fixed in gradio 4.44.0.
Gradio is an open-source Python package designed for quick prototyping. This vulnerability involves a one-level read path traversal in the /custom_component endpoint. Attackers can exploit this flaw to access and leak source code from custom Gradio components by manipulating the file path in the request. Although the traversal is limited to a single directory level, it could expose proprietary or sensitive code that developers intended to keep private. This impacts users who have developed custom Gradio components and are hosting them on publicly accessible servers. Users are advised to upgrade to gradio>=4.44 to address this issue. As a workaround, developers can sanitize the file paths and ensure that components are not stored in publicly accessible directories.
Attack profile
How easy it is to exploit
- Attack vector
- Network
- Complexity
- Low
- Privileges needed
- Low
- User interaction
- None
What an attacker can affect
- Confidentiality
- Low
- Integrity
- None
- Availability
- None
Exploit likelihood
What each source reports
CVE List Score used
2.3
One-level read path traversal in `/custom_component` in Gradio
Gradio is an open-source Python package designed for quick prototyping. This vulnerability involves a one-level read path traversal in the /custom_component endpoint. Attackers can exploit this flaw to access and leak source code from custom Gradio components by manipulating the file path in the request. Although the traversal is limited to a single directory level, it could expose proprietary or sensitive code that developers intended to keep private. This impacts users who have developed custom Gradio components and are hosting them on publicly accessible servers. Users are advised to upgrade to gradio>=4.44 to address this issue. As a workaround, developers can sanitize the file paths and ensure that components are not stored in publicly accessible directories.
- Record
CVE-2024-47166- CVSS 4.0
- 2.3 Low
CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:L/VI:N/VA:N/SC:N/SI:N/SA:N - Weakness
- CWE-22
- Updated
- 2026-11-02
EUVDEUVD-2024-0065
2.3
Gradio is an open-source Python package designed for quick prototyping. This vulnerability involves a one-level read path traversal in the /custom_component endpoint. Attackers can exploit this flaw to access and leak source code from custom Gradio components by manipulating the file path in the request. Although the traversal is limited to a single directory level, it could expose proprietary or sensitive code that developers intended to keep private. This impacts users who have developed custom Gradio components and are hosting them on publicly accessible servers. Users are advised to upgrade to gradio>=4.44 to address this issue. As a workaround, developers can sanitize the file paths and ensure that components are not stored in publicly accessible directories.
- Record
EUVD-2024-0065- CVSS 4.0
- 2.3 Low
CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:L/VI:N/VA:N/SC:N/SI:N/SA:N - Updated
- 2026-11-03
GitHub AdvisoriesGHSA-37qc-qgx6-9xjv
6.9
Gradio has a one-level read path traversal in `/custom_component`
Impact
What kind of vulnerability is it? Who is impacted?
This vulnerability involves a one-level read path traversal in the /custom_component endpoint. Attackers can exploit this flaw to access and leak source code from custom Gradio components by manipulating the file path in the request. Although the traversal is limited to a single directory level, it could expose proprietary or sensitive code that developers intended to keep private. This impacts users who have developed custom Gradio components and are hosting them on publicly accessible servers.
Patches
Yes, please upgrade to gradio>=4.44 to address this issue.
Workarounds
Is there a way for users to fix or remediate the vulnerability without upgrading?
As a workaround, developers can sanitize the file paths and ensure that components are not stored in publicly accessible directories.
- Record
GHSA-37qc-qgx6-9xjv- CVSS 4.0
- 6.9 Medium
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:L/VI:N/VA:N/SC:N/SI:N/SA:N/U:Green - CVSS 3.1
- 5.3 Medium
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:N - Weakness
- CWE-22
- Updated
- 2026-11-02
NVD
2.3
Gradio is an open-source Python package designed for quick prototyping. This vulnerability involves a one-level read path traversal in the /custom_component endpoint. Attackers can exploit this flaw to access and leak source code from custom Gradio components by manipulating the file path in the request. Although the traversal is limited to a single directory level, it could expose proprietary or sensitive code that developers intended to keep private. This impacts users who have developed custom Gradio components and are hosting them on publicly accessible servers. Users are advised to upgrade to gradio>=4.44 to address this issue. As a workaround, developers can sanitize the file paths and ensure that components are not stored in publicly accessible directories.
- Record
CVE-2024-47166- CVSS 4.0
- 2.3 Low
CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:L/VI:N/VA:N/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X - CVSS 3.1
- 5.3 Medium
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:N - Weakness
- CWE-22
- Updated
- 2026-11-02
OSV
2.3
One-level read path traversal in `/custom_component` in Gradio
Gradio is an open-source Python package designed for quick prototyping. This vulnerability involves a one-level read path traversal in the /custom_component endpoint. Attackers can exploit this flaw to access and leak source code from custom Gradio components by manipulating the file path in the request. Although the traversal is limited to a single directory level, it could expose proprietary or sensitive code that developers intended to keep private. This impacts users who have developed custom Gradio components and are hosting them on publicly accessible servers. Users are advised to upgrade to gradio>=4.44 to address this issue. As a workaround, developers can sanitize the file paths and ensure that components are not stored in publicly accessible directories.
- Record
CVE-2024-47166- CVSS 4.0
- 2.3 Low
CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:L/VI:N/VA:N/SC:N/SI:N/SA:N - Weakness
- CWE-22
- Updated
- 2026-11-02
OSVGHSA-37qc-qgx6-9xjv
6.9
Gradio has a one-level read path traversal in `/custom_component`
Impact
What kind of vulnerability is it? Who is impacted?
This vulnerability involves a one-level read path traversal in the /custom_component endpoint. Attackers can exploit this flaw to access and leak source code from custom Gradio components by manipulating the file path in the request. Although the traversal is limited to a single directory level, it could expose proprietary or sensitive code that developers intended to keep private. This impacts users who have developed custom Gradio components and are hosting them on publicly accessible servers.
Patches
Yes, please upgrade to gradio>=4.44 to address this issue.
Workarounds
Is there a way for users to fix or remediate the vulnerability without upgrading?
As a workaround, developers can sanitize the file paths and ensure that components are not stored in publicly accessible directories.
- Record
GHSA-37qc-qgx6-9xjv- CVSS 4.0
- 6.9 Medium
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:L/VI:N/VA:N/SC:N/SI:N/SA:N/U:Green - CVSS 3.1
- 5.3 Medium
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:N - Weakness
- CWE-22
- Updated
- 2026-11-02
OSVPYSEC-2024-197
5.3
Gradio is an open-source Python package designed for quick prototyping. This vulnerability involves a one-level read path traversal in the /custom_component endpoint. Attackers can exploit this flaw to access and leak source code from custom Gradio components by manipulating the file path in the request. Although the traversal is limited to a single directory level, it could expose proprietary or sensitive code that developers intended to keep private. This impacts users who have developed custom Gradio components and are hosting them on publicly accessible servers. Users are advised to upgrade to gradio>=4.44 to address this issue. As a workaround, developers can sanitize the file paths and ensure that components are not stored in publicly accessible directories.
- Record
PYSEC-2024-197- CVSS 3.1
- 5.3 Medium
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:N - Updated
- 2026-11-02
Affected products
Affected packages
| Package | Affected | Fixed |
|---|---|---|
gradioPyPI |
before 4.44.0 | 4.44.0 |
gradioPyPI |
before 4.44.0, plus listed versions 0.1.00.1.10.1.20.1.30.1.4 Show 45 moreShow less0.1.50.1.60.1.70.1.80.1.90.2.00.2.10.3.00.3.10.3.20.3.30.3.40.3.50.4.00.4.10.4.20.4.40.5.00.7.00.7.10.7.20.7.30.7.40.7.50.7.60.7.70.7.80.8.00.8.10.9.00.9.10.9.20.9.30.9.40.9.50.9.60.9.70.9.80.9.9.20.9.9.30.9.9.50.9.9.60.9.9.70.9.9.80.9.9.9 |
4.44.0 |
History
| When | Changed | Sources |
|---|---|---|
| 2026-11-03 | aliases | EUVD |
| 2026-11-02 | created | CVE List, GitHub Advisories, NVD, OSV |
References
github.com/gradio-app/gradio/security/advisories/GHSA-37qc-qgx6-9xjv
nvd.nist.gov/vuln/detail/CVE-2024-47166
github.com/pypa/advisory-database/tree/main/vulns/gradio/PYSEC-2024-197.yaml
github.com/advisories/GHSA-37qc-qgx6-9xjv
github.com/CVEProject/cvelistV5/tree/main/cves/2024/47xxx/CVE-2024-47166.json
github.com/gradio-app/gradio
Left out here: 495 versions. The JSON record has them.