{"id":"CVE-2021-43831","published":"2021-12-15T19:50:10Z","modified":"2024-08-04T04:10:15Z","title":"Files on the host computer can be accessed from the Gradio interface","vendor":"gradio-app","product":"gradio","tier":"tail","description":{"text":"Gradio is an open source framework for building interactive machine learning models and demos. In versions prior to 2.5.0 there is a vulnerability that affects anyone who creates and publicly shares Gradio interfaces. File paths are not restricted and users who receive a Gradio link can access any files on the host computer if they know the file names or file paths. This is limited only by the host operating system. Paths are opened in read only mode. The problem has been patched in gradio 2.5.0.","provenance":"source","from":"CVE.org"},"cvss":{"score":7.7,"severity":"HIGH","version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:N/A:N","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.03837,"percentile":0.90368,"provenance":"source"},"cwes":[{"id":"CWE-22","name":"Improper Limitation of a Pathname to a Restricted Directory"}],"references":[{"url":"https://github.com/gradio-app/gradio/security/advisories/GHSA-rhq2-3vr9-6mcr","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/gradio-app/gradio/commit/41bd3645bdb616e1248b2167ca83636a2653f781","tags":["x_refsource_MISC"]}],"priority":{"score":28.5,"factors":[{"name":"EPSS percentile","points":18.07},{"name":"Public exploit code","points":5.0},{"name":"CVSS severity","points":5.39}]},"exploitSources":{"nuclei":[{"id":"CVE-2021-43831","name":"Gradio < 2.5.0 - Arbitrary File Read","severity":"high","path":"http/cves/2021/CVE-2021-43831.yaml","url":"https://github.com/projectdiscovery/nuclei-templates/blob/main/http/cves/2021/CVE-2021-43831.yaml"}],"provenance":"source"},"vendorSlug":"gradio-app","affectedVersions":[{"vendor":"gradio-app","product":"gradio","versions":["< 2.5.0"]}],"affected":[{"ecosystem":"PyPI","package":"gradio","vulnerableRanges":["<2.5.0"],"patched":["2.5.0"],"from":["GHSA-rhq2-3vr9-6mcr","PYSEC-2021-873"],"provenance":"source"}],"summary":{"text":"A path-traversal flaw in the Gradio framework's interface file handling, affecting versions before 2.5.0, lets anyone with a shared Gradio link read files from the host computer because file paths are not restricted to an allowed directory. An attacker needs only a link to a publicly shared interface and knowledge of the target file names or paths, with access limited only by the host operating system's permissions and files being opened read-only.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-21T04:18:16Z"},"euvd":{"id":"EUVD-2021-0095","exploited":false,"provenance":"source"},"lineage":{"packageHistory":[{"cve":"CVE-2021-43831","published":"2021-12-15","fixed":"2.5.0","kev":false},{"cve":"CVE-2022-24770","published":"2022-03-17","fixed":"2.8.11","kev":false,"link":{"from":"CVE-2021-43831","to":"CVE-2022-24770","relation":"successor","confidence":"low","kind":"sequence","evidence":[{"kind":"version-step","provenance":"source","package":"PyPI:gradio","fromFixed":"2.5.0","toFixed":"2.8.11","daysApart":92}]}},{"cve":"CVE-2023-25823","published":"2023-02-23","fixed":"3.13.1","kev":false},{"cve":"CVE-2023-34239","published":"2023-06-07","fixed":"3.34.0","kev":false}],"package":"PyPI:gradio"}}