CVEReports
CVEReports

Automated vulnerability intelligence platform. Comprehensive reports for high-severity CVEs generated by AI.

Product

  • Home
  • Sitemap
  • RSS Feed

Company

  • About
  • Contact
  • Privacy Policy
  • Terms of Service

© 2026 CVEReports. All rights reserved.

Made with love by Amit Schendel & Alon Barad



CVE-2026-28416

Implicit Trust in Remote Configuration Leads to SSRF in Gradio

Alon Barad
Alon Barad
Software Engineer

Mar 1, 2026·6 min read·37 visits

Executive Summary (TL;DR)

Gradio versions prior to 6.6.0 are vulnerable to SSRF when loading untrusted Spaces via `gr.load()`. Malicious configurations can whitelist arbitrary internal URLs, allowing attackers to access cloud metadata or local services through the application's proxy endpoint.

A high-severity Server-Side Request Forgery (SSRF) vulnerability exists in the Gradio machine learning framework due to improper validation of remote configurations. When a user utilizes the `gr.load()` function to import a remote Hugging Face Space, the local Gradio instance ingests the remote `config.json` file. In vulnerable versions, the application implicitly trusts the `proxy_url` parameters defined within this configuration, adding them to the local application's proxy allowlist. This allows a malicious Space to inject arbitrary internal URLs—such as cloud metadata endpoints or local network services—into the allowlist. Consequently, an attacker can leverage the victim's `/proxy` endpoint to exfiltrate sensitive internal data.

Vulnerability Overview

Gradio is a popular Python library used for creating machine learning demos and web applications. A core feature of the library is its ability to compose applications by loading other existing Gradio apps, typically hosted on Hugging Face Spaces, using the gr.load() function. This function retrieves the configuration and interface definition of the upstream Space to replicate it locally.

In affected versions, a critical trust boundary violation occurs during this loading process. The gr.load() function fetches the config.json file from the target Space and processes its components. If the remote configuration specifies proxy_url values for its components, the local Gradio instance blindly accepts these values and adds them to its own internal allowlist for the /proxy route. This behavior creates a Server-Side Request Forgery (SSRF) condition where the trust placed in the remote configuration allows the remote author to dictate which network resources the local server is permitted to access.

The vulnerability is classified under CWE-918 (Server-Side Request Forgery). It is particularly dangerous in cloud environments (AWS, GCP, Azure), where accessing the link-local metadata service (e.g., 169.254.169.254) often yields temporary credentials capable of compromising the entire cloud account.

Root Cause Analysis

The root cause of CVE-2026-28416 lies in the unvalidated ingestion of the proxy_url property within gradio/blocks.py. When gr.load() initializes, it calls Blocks.from_config(). This method iterates through the components defined in the downloaded JSON configuration.

Prior to the patch, the code logic extracted the proxy_url from any component props and directly appended it to self.proxy_urls. This set, self.proxy_urls, serves as the authoritative allowlist for the application's reverse proxy functionality located at the /proxy endpoint. The logic failed to verify whether the proxy_url pointed to a legitimate Hugging Face resource or an arbitrary internal target.

Because the config.json is controlled by the owner of the loaded Space, a malicious actor can craft a Space definition that includes sensitive internal URLs. Once the victim loads this Space, the validation logic in gradio/routes.py—which checks if a requested URL exists in self.proxy_urls—passes successfully for the attacker-injected URLs. This effectively bypasses the intended security controls of the proxy mechanism, turning the Gradio server into an open gateway to the specified targets.

Code Analysis

The vulnerability existed in the gradio.blocks.Blocks class during the configuration parsing phase. The following snippet illustrates the flawed logic in the from_config method where URLs were blindly trusted.

Vulnerable Code (gradio/blocks.py):

# Inside Blocks.from_config method
for component_config in config.get("components", []):
    # ... component instantiation ...
    if "proxy_url" in props:
        # VULNERABILITY: Arbitrary URL from remote config added to allowlist
        blocks.proxy_urls.add(props["proxy_url"])

The fix, introduced in version 6.6.0, implements strict validation. It ensures that any proxy_url ingested from a configuration file must belong to the trusted .hf.space domain. This restriction aligns with the intended use case of proxying requests to other Hugging Face Spaces while blocking access to arbitrary network endpoints.

Patched Code (gradio/blocks.py & gradio/routes.py):

# Validates that the URL host ends with .hf.space
def is_valid_proxy_url(url: str) -> bool:
    from urllib.parse import urlparse
    parsed = urlparse(url)
    # STRICT CHECK: Only allow huggingface spaces
    return parsed.netloc.endswith(".hf.space")
 
# Inside Blocks.from_config
if "proxy_url" in props:
    proxy_url = props["proxy_url"]
    if is_valid_proxy_url(proxy_url):
        blocks.proxy_urls.add(proxy_url)

Furthermore, a secondary check was added to gradio/routes.py in the reverse_proxy handler. Even if a URL somehow enters the proxy_urls set, the handler now re-verifies that the target host matches the allowlist criteria (ending in .hf.space). This defense-in-depth approach ensures that even if the configuration ingestion logic is bypassed, the routing logic will still reject the SSRF attempt.

Exploitation Scenario

To exploit this vulnerability, an attacker must first create a malicious Gradio Space (or host a compatible configuration file). The attacker modifies the config.json to include a proxy_url pointing to the target internal resource. For example, targeting AWS EC2 metadata.

Step 1: Malicious Configuration

The attacker hosts a config.json similar to the following:

{
  "components": [
    {
      "id": 1,
      "type": "textbox",
      "props": {
        "proxy_url": "http://169.254.169.254/latest/meta-data/iam/security-credentials/"
      }
    }
  ],
  "mode": "blocks"
}

Step 2: Triggering the Vulnerability

The victim, intended to be a developer or a deployment pipeline, runs the following Python code:

import gradio as gr
# Victim loads the attacker's space
gr.load("attacker-username/malicious-space")

Step 3: Execution

Upon execution, the victim's application starts and whitelists the AWS metadata URL. The attacker (or the malicious space's frontend logic) then sends a request to the victim's application:

GET /proxy=http://169.254.169.254/latest/meta-data/iam/security-credentials/

The victim's server proxies this request to the link-local address and returns the AWS credentials to the attacker.

Impact Assessment

The impact of this vulnerability is critical for deployments in cloud environments or corporate intranets. The ability to coerce the server into making arbitrary GET requests allows for significant information disclosure.

Confidentiality Impact (High): Attackers can access cloud instance metadata services (IMDSv1) on AWS, GCP, and Azure. This often results in the theft of temporary IAM credentials, which may grant extensive access to the victim's cloud infrastructure (e.g., S3 buckets, databases, compute resources). Additionally, attackers can probe internal dashboards, monitoring systems (e.g., Prometheus, Grafana), or source code repositories that are not exposed to the public internet but are accessible to the Gradio server.

Integrity Impact (Low): While SSRF is primarily a read-primitive, it can facilitate integrity violations if internal services expose unauthenticated APIs that change state via GET requests (violating REST principles) or if the attacker can chain the SSRF with other vulnerabilities to perform Command Injection on internal services.

Availability Impact (None): The vulnerability does not inherently lead to denial of service, though an attacker could potentially overload internal services by using the Gradio instance as a proxy for high-volume traffic.

Mitigation & Remediation

The primary remediation is to upgrade to Gradio version 6.6.0 or later immediately. This version introduces strictly typed validation for proxy URLs, ensuring they match the expected .hf.space pattern.

If upgrading is not immediately feasible, the following mitigations are recommended:

  1. Avoid Untrusted Spaces: Strictly prohibit the use of gr.load() with Spaces maintained by unknown or untrusted third parties. Review the source code and configuration of any Space before loading it.
  2. Network Segmentation (Egress Filtering): Configure firewall rules or Security Groups to restrict the Gradio server's outbound traffic. Block access to 169.254.169.254 (Cloud Metadata) and private IP ranges (RFC1918) unless explicitly required.
  3. IMDSv2 Enforcement: In AWS environments, enforce the use of IMDSv2 (Instance Metadata Service Version 2). IMDSv2 requires a PUT request to retrieve a session token before accessing metadata, which mitigates many SSRF attacks that rely on simple GET requests.

Official Patches

GradioFix commit implementing proxy URL validation
GitHubOfficial GHSA Advisory

Fix Analysis (1)

Technical Appendix

CVSS Score
8.2/ 10
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:L/A:N
EPSS Probability
0.03%
Top 92% most exploited

Affected Systems

Gradio < 6.6.0Gradio Client (Python)Applications using gr.load() with untrusted sources

Affected Versions Detail

Product
Affected Versions
Fixed Version
Gradio
Gradio
< 6.6.06.6.0
AttributeDetail
CWE IDCWE-918
Attack VectorNetwork (Remote)
CVSS Score8.2 (High)
EPSS Score0.00030
ImpactInformation Disclosure / Internal Network Access
Exploit StatusProof of Concept Available

MITRE ATT&CK Mapping

T1190Exploit Public-Facing Application
Initial Access
T1552.005Unsecured Credentials: Cloud Instance Metadata API
Credential Access
CWE-918
Server-Side Request Forgery (SSRF)

Server-Side Request Forgery (SSRF) occurs when a web application is fetching a remote resource without validating the user-supplied URL. It allows an attacker to coerce the application to send a crafted request to an unexpected destination.

Known Exploits & Detection

GitHub Security AdvisoryAdvisory containing reproduction steps and conceptual PoC

Vulnerability Timeline

Fix commit pushed to repository
2026-02-17
Security Advisory (GHSA) published
2026-02-27
CVE-2026-28416 Assigned
2026-02-27

References & Sources

  • [1]NVD Entry for CVE-2026-28416
  • [2]Gradio Security Advisory

Attack Flow Diagram

Press enter or space to select a node. You can then use the arrow keys to move the node around. Press delete to remove it and escape to cancel.
Press enter or space to select an edge. You can then press delete to remove it or escape to cancel.

More Reports

•about 5 hours ago•CVE-2024-29203
4.3

CVE-2024-29203: Client-Side Cross-Site Scripting via Unsandboxed Iframes and Legacy Embed Elements in TinyMCE

CVE-2024-29203 identifies a cross-site scripting (XSS) vulnerability in the content ingestion and parsing mechanics of TinyMCE rich text editor. Due to a failure to enforce sandbox attributes on dynamic iframe elements and safely handle legacy embed objects, unauthenticated attackers can inject malicious elements that execute scripts within the context of the parent application session.

Amit Schendel
Amit Schendel
5 views•5 min read
•about 7 hours ago•CVE-2026-9277
8.1

CVE-2026-9277: OS Command Injection in shell-quote via Object-Token Line Terminator Parsing Defect

A technical breakdown of the OS command injection vulnerability in the shell-quote NPM package (CVE-2026-9277 / GHSA-w7jw-789q-3m8p). The bug resides in the character-by-character backslash-escaping logic applied to the .op field of object-tokens within the quote() function, which fails to match and escape line terminators due to a regex matching oversight in JavaScript. This allows unauthenticated remote attackers to execute arbitrary shell commands if they can control inputs processed by this library.

Alon Barad
Alon Barad
10 views•6 min read
•about 8 hours ago•CVE-2026-11645
8.8

CVE-2026-11645: Out-of-Bounds Memory Access in Google Chrome V8 Engine

A high-severity memory corruption vulnerability exists in the V8 JavaScript engine of Google Chrome before versions 149.0.7827.102/103. The flaw arises from an incorrect bounds-check elimination during JIT compilation by the TurboFan optimizer, allowing remote attackers to achieve out-of-bounds read and write access inside the sandboxed renderer process.

Amit Schendel
Amit Schendel
24 views•6 min read
•about 17 hours ago•CVE-2026-50751
9.3

CVE-2026-50751: Authentication Bypass in Check Point Security Gateway IKEv1 Legacy Validation

An improper authentication vulnerability (CWE-287) exists in the legacy, deprecated Internet Key Exchange version 1 (IKEv1) key exchange protocol implementation in Check Point Security Gateways. The vulnerability is caused by a logic flow weakness during the certificate validation process for Remote Access VPN and Mobile Access (SSL VPN) connections. An unauthenticated remote attacker can exploit this weakness to bypass user authentication entirely, establishing a fully functional Remote Access VPN connection without a valid password.

Alon Barad
Alon Barad
69 views•6 min read
•1 day ago•CVE-2026-39922
6.3

CVE-2026-39922: Server-Side Request Forgery in GeoNode Service Registration Endpoint

GeoNode versions prior to 4.4.5 and 5.0.2 are vulnerable to Server-Side Request Forgery (SSRF) in the service registration endpoint. Authenticated attackers with low privileges can exploit insufficient input validation in the Web Map Service (WMS) registration module to force the application server to make outbound network queries to loopback addresses, private RFC1918 subnets, link-local scopes, and cloud metadata endpoints. This technical report details the mechanics of the vulnerability, the underlying architectural flaw, and how to effectively remediate and mitigate the associated security risks.

Alon Barad
Alon Barad
4 views•7 min read
•1 day ago•CVE-2022-0492
7.8

CVE-2022-0492: Privilege Escalation and Container Escape via cgroups v1 release_agent

CVE-2022-0492 is a high-severity missing authorization vulnerability in the Linux kernel's Control Groups (cgroups) v1 implementation. The flaw resides within the cgroup_release_agent_write function in kernel/cgroup/cgroup-v1.c, where the kernel fails to validate if the process writing to the release_agent file possesses administrative capabilities in the initial user namespace. This allows a local attacker inside a container with root privileges (UID 0) to abuse user namespaces, mount a cgroups v1 directory, modify the release_agent parameter, and execute arbitrary commands on the host system as host root, effectively achieving a complete container escape.

Amit Schendel
Amit Schendel
12 views•7 min read