Skip to content
HighVulnerability

CVE-2024-1561: Gradio local file read through /component_server endpoint

Identifier
CVE-2024-1561
Published
Record updated
View JSON
Affected
  • gradio < 4.13.0
Fixed in
4.13.0
  • released January 4, 2024, 102 days before disclosure
Known exploitation
Not listed in the CISA Known Exploited Vulnerabilities catalog at the last check.
EPSS
9.3%

Summary

The /component_server endpoint in gradio-app/gradio lets callers invoke any method on a Component class with attacker-controlled arguments. Using 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 then retrieve it, enabling unauthorized local file read. The flaw poses a significant risk when apps are exposed via launch(share=True), and gradio apps hosted on huggingface.co are also affected, potentially exposing API keys and credentials stored in environment variables.

Mitigation

The source does not state a fix yet. Check the original advisory for updates.