Skip to main content
ExploitedNot in CISA KEV yetFix available

CVE-2024-1561

Exploitation confirmed. First attested on 2024-09-18 by GCVE · kevintel, GCVE · shadowserver.

  • Published2024-04-16
  • Fixed in4.13.0
  • WeaknessCWE-29

Am I affected?

With a domain, we read the version its public headers and pages expose. A distribution build can carry the fix under an older number.

Description

An issue was discovered in gradio-app/gradio, where the `/component_server` endpoint improperly allows the invocation of any method on a `Component` class with attacker-controlled arguments. Specifically, by exploiting the `move_resource_to_block_cache()` method of the `Block` class, an attacker can copy any file on the filesystem to a temporary directory and subsequently retrieve it. This vulnerability enables unauthorized local file read access, posing a significant risk especially when the application is exposed to the internet via `launch(share=True)`, thereby allowing remote attackers to read files on the host machine. Furthermore, gradio apps hosted on `huggingface.co` are also affected, potentially leading to the exposure of sensitive information such as API keys and credentials stored in environment variables.

Timeline

dates in UTC
  1. 2024-04-1600:15CVE publishedNVD
  2. 2024-09-1808:57Listed as exploited by GCVEGCVE
  3. 2024-09-1808:57Exploitation first reportedGCVE

Versions per branch

NVD · OSV · CISA-ADP
Gradio project gradio
BranchAffectedFixed in
4.x≥ 4.12.0, < 4.13.04.13.0
4.13< 4.13.04.13.0
4.12= 4.12.0no fix published

as publishedRanges as NVD and OSV publish them; a distribution’s build can be fixed under an older number.

Products declared by the CNA1 product

As @huntr_ai, the CNA that assigned this CVE, declared them in the CVE record; versions as written.

  • gradio-app/gradio
    Affected
    • < 4.13.0fixed in 4.13.0custom

Source: the CNA record (CVE Program), © The MITRE Corporation,CVE Terms of UseCVE recordupdated 2024-05-10

Fix

  1. Update Gradio project gradio to 4.13.0

Advisories and patches

Detection

read 2026-11-01 01:02 UTC
Nuclei template
available
ProjectDiscovery
Exploit-DB
no entry
Exploit-DB
Metasploit modules
none listed
Metasploit Framework

Sources

Identifiers

Technical details

CVSS v3 Vector
CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N
Published
2024-04-16
Last Modified
2026-06-17
NVD status
Analyzed
GitHub Advisory
GHSA-g9cj-cfpp-4g2x

Frequently asked questions

What is CVE-2024-1561?

An issue was discovered in gradio-app/gradio, where the `/component_server` endpoint improperly allows the invocation of any method on a `Component` class with attacker-controlled arguments. Specifically, by exploiting the `move_resource_to_block_cache()` method of the `Block` class, an attacker can copy any file on the filesystem to a temporary directory and subsequently retrieve it. This vulnerability enables unauthorized local file read access, posing a significant risk especially when the application is exposed to the internet via `launch(share=True)`, thereby allowing remote attackers to read files on the host machine. Furthermore, gradio apps hosted on `huggingface.co` are also affected, potentially leading to the exposure of sensitive information such as API keys and credentials stored in environment variables.

Is CVE-2024-1561 actively exploited?

A proof-of-concept exploit exists for CVE-2024-1561, but active exploitation has not been confirmed at this time.

What is the CVSS score for CVE-2024-1561?

CVE-2024-1561 has a CVSS v3 base score of 7.5 (HIGH severity), with vector string CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N.

Running gradio? Hear about its next vulnerability

Surveillance reads the versions in your stack — a domain, a lockfile or a list — checks each CVE against the ranges its sources publish, and alerts you when one you run is exploited or enters CISA KEV. A version it cannot read stays « version not verified ».

No credit card required · No monthly cap on website lookups · 250 API requests/month

Sources for this record