CVE-2025-23042: Gradio: ACL bypass via path case manipulation
GHSA-j2jg-fq62-7c3h HIGH PoC AVAILABLE CISA: TRACK*Any Gradio deployment on Windows or macOS where sensitive files exist in the served directory is at risk of unauthorized file access with zero authentication required. Upgrade to Gradio 5.11.0 immediately—this is a network-exploitable, no-auth vulnerability affecting one of the most widely deployed ML UI frameworks. Audit all Gradio instances in your environment, especially internal AI demo servers that may expose API keys, model configs, or training data.
What is the risk?
High risk for organizations running Gradio on Windows or macOS servers. CVSS 7.5 with no privileges or user interaction required makes this trivially exploitable. The low EPSS (0.00099) and absence from CISA KEV suggest limited active exploitation at publication, but Gradio's massive adoption in AI/ML teams—including internal demo servers holding credentials and model artifacts—amplifies the blast radius significantly. Linux deployments are unaffected due to case-sensitive filesystems, but mixed environments and Windows-based AI workstations remain exposed.
What systems are affected?
How severe is it?
What is the attack surface?
What should I do?
5 steps-
PATCH
Upgrade Gradio to 5.11.0 immediately—no known workarounds exist per the advisory.
-
DETECT
Audit web server access logs for requests using mixed-case path variants targeting sensitive directories (e.g., /Config/, /Models/, /Secrets/).
-
ISOLATE
Run Gradio under a dedicated low-privilege service account with minimal filesystem scope.
-
CONTAIN
Deploy a reverse proxy (nginx, Caddy) that normalizes path case before forwarding to Gradio.
-
INVENTORY
Enumerate all Gradio deployments organization-wide, including developer machines and CI/CD demo environments hosting AI models.
What does CISA's SSVC say?
Source: CISA Vulnrichment (SSVC v2.0). Decision based on the CISA Coordinator decision tree.
How is it classified?
Which compliance frameworks are affected?
This CVE is relevant to:
Frequently Asked Questions
What is CVE-2025-23042?
Any Gradio deployment on Windows or macOS where sensitive files exist in the served directory is at risk of unauthorized file access with zero authentication required. Upgrade to Gradio 5.11.0 immediately—this is a network-exploitable, no-auth vulnerability affecting one of the most widely deployed ML UI frameworks. Audit all Gradio instances in your environment, especially internal AI demo servers that may expose API keys, model configs, or training data.
Is CVE-2025-23042 actively exploited?
Proof-of-concept exploit code is publicly available for CVE-2025-23042, increasing the risk of exploitation.
How to fix CVE-2025-23042?
1. PATCH: Upgrade Gradio to 5.11.0 immediately—no known workarounds exist per the advisory. 2. DETECT: Audit web server access logs for requests using mixed-case path variants targeting sensitive directories (e.g., /Config/, /Models/, /Secrets/). 3. ISOLATE: Run Gradio under a dedicated low-privilege service account with minimal filesystem scope. 4. CONTAIN: Deploy a reverse proxy (nginx, Caddy) that normalizes path case before forwarding to Gradio. 5. INVENTORY: Enumerate all Gradio deployments organization-wide, including developer machines and CI/CD demo environments hosting AI models.
What systems are affected by CVE-2025-23042?
This vulnerability affects the following AI/ML architecture patterns: model serving, ml_ui, agent frameworks, training pipelines.
What is the CVSS score for CVE-2025-23042?
CVE-2025-23042 has a CVSS v3.1 base score of 7.5 (HIGH). The EPSS exploitation probability is 0.84%.
What is the AI security impact?
Affected AI Architectures
MITRE ATLAS Techniques
AML.T0025 Exfiltration via Cyber Means AML.T0037 Data from Local System AML.T0049 Exploit Public-Facing Application AML.T0107 Exploitation for Defense Evasion Compliance Controls Affected
What are the technical details?
Original Advisory
Gradio is an open-source Python package that allows quick building of demos and web application for machine learning models, API, or any arbitrary Python function. Gradio's Access Control List (ACL) for file paths can be bypassed by altering the letter case of a blocked file or directory path. This vulnerability arises due to the lack of case normalization in the file path validation logic. On case-insensitive file systems, such as those used by Windows and macOS, this flaw enables attackers to circumvent security restrictions and access sensitive files that should be protected. This issue can lead to unauthorized data access, exposing sensitive information and undermining the integrity of Gradio's security model. Given Gradio's popularity for building web applications, particularly in machine learning and AI, this vulnerability may pose a substantial threat if exploited in production environments. This issue has been addressed in release version 5.6.0. Users are advised to upgrade. There are no known workarounds for this vulnerability.
Exploitation Scenario
An adversary identifies a publicly accessible Gradio ML demo running on a Windows server behind a corporate reverse proxy. The application has ACL rules blocking '/config/secrets.env' containing an Anthropic API key used to back the inference endpoint. The attacker sends a GET request to '/Config/Secrets.env'—Gradio's validation logic fails to match the blocked lowercase path due to missing case normalization, while the Windows NTFS filesystem serves the file normally. The attacker extracts the API key in seconds, enabling unauthorized LLM API usage and potential further lateral movement into cloud AI infrastructure.
Weaknesses (CWE)
CWE-178 Improper Handling of Case Sensitivity
Primary
CWE-285 Improper Authorization
Primary
CWE-285 Improper Authorization CWE-178 — Improper Handling of Case Sensitivity: The product does not properly account for differences in case sensitivity when accessing or determining the properties of a resource, leading to inconsistent results.
- [Architecture and Design] Avoid making decisions based on names of resources (e.g. files) if those resources can have alternate names.
- [Implementation] Assume all input is malicious. Use an "accept known good" input validation strategy, i.e., use a list of acceptable inputs that strictly conform to specifications. Reject any input that does not strictly conform to specifications, or transform it into something that does. When performing input validation, consider all potentially relevant properties, including length, type of input, the full range of acceptable values, missing or extra inputs, syntax, consistency across related fields, and conformance to business rules. As an example of business rule logic, "boat" may be syntactically valid because it only contains alphanumeric characters, but it is not valid if the input is only expected to contain colors such as "red" or "blue." Do not rely exclusively on looking for malicious or malformed inputs. This is likely to miss at least one undesirable input, especially if the code's environment changes. This can give attackers enough room to bypass the intended validation. However, denylis
Source: MITRE CWE corpus.
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N References
- github.com/advisories/GHSA-j2jg-fq62-7c3h
- github.com/gradio-app/gradio/commit/6b63fdec441b5c9bf910f910a2505d8defbb6bf8
- github.com/gradio-app/gradio/releases/tag/gradio%405.11.0
- nvd.nist.gov/vuln/detail/CVE-2025-23042
- github.com/gradio-app/gradio/security/advisories/GHSA-j2jg-fq62-7c3h Exploit Mitigation 3rd Party
- github.com/rahg0/python-intentionally-vuln-package Exploit
- github.com/rahg0/python-weather-app Exploit
- github.com/rahg0/python-weather-app-with-pipenv Exploit
Timeline
Related Vulnerabilities
CVE-2024-47167 9.8 Gradio: unauthenticated SSRF in /queue/join, internal pivot
Same package: gradio CVE-2024-39236 9.8 Gradio: code injection via component metadata (CVSS 9.8)
Same package: gradio CVE-2023-25823 9.8 Gradio: hardcoded SSH key leaks via share=True demos
Same package: gradio CVE-2024-0964 9.4 Gradio: unauthenticated LFI exposes full server filesystem
Same package: gradio CVE-2023-34239 9.1 Gradio: path traversal + SSRF exposes model files & infra
Same package: gradio