Publish GHSA-77xq-6g77-h274

This commit is contained in:
advisory-database[bot]
2024-10-10 21:28:53 +00:00
parent 758a480843
commit 3d29e133fc
@@ -0,0 +1,65 @@
{
"schema_version": "1.4.0",
"id": "GHSA-77xq-6g77-h274",
"modified": "2024-10-10T21:27:47Z",
"published": "2024-10-10T21:27:47Z",
"aliases": [
"CVE-2024-47164"
],
"summary": "Gradio's `is_in_or_equal` function may be bypassed",
"details": "### Impact\n**What kind of vulnerability is it? Who is impacted?**\n\nThis vulnerability relates to the **bypass of directory traversal checks** within the `is_in_or_equal` function. This function, intended to check if a file resides within a given directory, can be bypassed with certain payloads that manipulate file paths using `..` (parent directory) sequences. Attackers could potentially access restricted files if they are able to exploit this flaw, although the difficulty is high. This primarily impacts users relying on Gradios blocklist or directory access validation, particularly when handling file uploads.\n\n### Patches\nYes, please upgrade to `gradio>=5.0` to address this issue.\n\n### Workarounds\n**Is there a way for users to fix or remediate the vulnerability without upgrading?**\n\nAs a workaround, users can manually sanitize and normalize file paths in their Gradio deployment before passing them to the `is_in_or_equal` function. Ensuring that all file paths are properly resolved and absolute can help mitigate the bypass vulnerabilities caused by the improper handling of `..` sequences or malformed paths.",
"severity": [
{
"type": "CVSS_V3",
"score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:N"
},
{
"type": "CVSS_V4",
"score": "CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:L/VI:L/VA:N/SC:N/SI:N/SA:N"
}
],
"affected": [
{
"package": {
"ecosystem": "PyPI",
"name": "gradio"
},
"ranges": [
{
"type": "ECOSYSTEM",
"events": [
{
"introduced": "0"
},
{
"fixed": "5.0.0"
}
]
}
]
}
],
"references": [
{
"type": "WEB",
"url": "https://github.com/gradio-app/gradio/security/advisories/GHSA-77xq-6g77-h274"
},
{
"type": "WEB",
"url": "https://github.com/gradio-app/gradio/commit/08b51590163b306fd874f543f6fcaf23ac7d2646"
},
{
"type": "PACKAGE",
"url": "https://github.com/gradio-app/gradio"
}
],
"database_specific": {
"cwe_ids": [
"CWE-22"
],
"severity": "MODERATE",
"github_reviewed": true,
"github_reviewed_at": "2024-10-10T21:27:47Z",
"nvd_published_at": null
}
}