{"schemaVersion":1,"url":"https://cve.openhack.com/cve/CVE-2024-1561","id":"CVE-2024-1561","title":"Arbitrary Local File Read via Component Method Invocation in gradio-app/gradio","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 vulnera","descriptionLong":"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.","published":"2024-04-16T00:00:15.906Z","updated":"2026-11-09T10:45:23.594995909Z","reserved":"2024-02-15T19:12:58.336Z","status":"Analyzed","rejected":false,"assigner":"@huntr_ai","metric":{"version":"3.0","score":7.5,"vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N","rating":"high","source":"@huntr_ai"},"metrics":[{"version":"3.0","score":7.5,"vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N","rating":"high","source":"@huntr_ai"},{"version":"3.0","score":7.5,"vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N","rating":"high","source":"huntr.dev"},{"version":"3.0","score":7.5,"vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N","rating":"high","source":"OSV"},{"version":"3.0","score":7.5,"vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N","rating":"high","source":"GitHub"}],"rating":"high","products":["gradio-app/gradio"],"affectedProducts":[{"vendor":"gradio-app","product":"gradio-app/gradio","defaultStatus":null,"versions":[{"version":"unspecified","lessThan":"4.13.0","status":"affected","versionType":"custom"}],"platforms":[]}],"packages":[{"ecosystem":"PyPI","name":"gradio","purl":"pkg:pypi/gradio","ranges":["<4.13.0"],"fixed":["4.13.0"],"advisory":"GHSA-g9cj-cfpp-4g2x"}],"cwes":["CWE-29"],"aliases":["GHSA-g9cj-cfpp-4g2x","PYSEC-2026-1415"],"references":[{"url":"https://huntr.com/bounties/4acf584e-2fe8-490e-878d-2d9bf2698338","tags":["x_transferred","Exploit","Third Party Advisory","web"]},{"url":"https://github.com/gradio-app/gradio/commit/24a583688046867ca8b8b02959c441818bdb34a2","tags":["x_transferred","Patch","fix","web"]},{"url":"https://www.gradio.app/changelog#4-13-0","tags":["x_transferred","Release Notes","web"]},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2024/1xxx/CVE-2024-1561.json","tags":["advisory"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2024-1561","tags":["advisory"]},{"url":"https://github.com/gradio-app/gradio","tags":["package"]},{"url":"https://pypi.org/project/gradio","tags":["package"]},{"url":"https://github.com/advisories/GHSA-g9cj-cfpp-4g2x","tags":["advisory"]}],"patchReferenced":true,"fixAvailable":true,"exploitReferenced":true,"kev":false,"kevAdded":null,"kevDue":null,"kevEntry":null,"ssvc":{"exploitation":"poc","automatable":"yes","technicalImpact":"partial"},"epss":0.09314,"epssPercentile":0.95475,"sources":[{"name":"CVE List","url":"https://www.cve.org/CVERecord?id=CVE-2024-1561","ok":true},{"name":"NVD","url":"https://nvd.nist.gov/vuln/detail/CVE-2024-1561","ok":true,"note":"Analyzed"},{"name":"OSV","url":"https://osv.dev/vulnerability/CVE-2024-1561","ok":true,"note":"1 package"},{"name":"GitHub Advisory","url":"https://github.com/advisories/GHSA-g9cj-cfpp-4g2x","ok":true,"note":"GHSA-g9cj-cfpp-4g2x"},{"name":"CISA KEV","url":"https://www.cisa.gov/known-exploited-vulnerabilities-catalog","ok":true,"note":"not listed"},{"name":"EPSS","url":"https://api.first.org/data/v1/epss?cve=CVE-2024-1561","ok":true,"note":"scored 2026-11-18"}],"aiTitle":false,"tech":[],"critical":[],"attention":null}