GradioApplication · Gradio Project

CVE-2024-47084

HIGH · 8.3 CVSS v3.1 Published 2024-10-10
Fix available
A fix is available. Upgrade to 4.44.0 or later.
See remediation →
90/100
Remediation priority · Urgent
Remotely reachable No privileges

Official description Straight from the sourceThe vendor's or NVD's own wording, published unedited. Authoritative, but often terse — it says what broke, rarely what to do.

NVD · unedited
Gradio is an open-source Python package designed for quick prototyping. This vulnerability is related to **CORS origin validation**, where the Gradio server fails to validate the request origin when a cookie is present. This allows an attacker’s website to make unauthorized requests to a local Gradio server. Potentially, attackers can upload files, steal authentication tokens, and access user data if the victim visits a malicious website while logged into Gradio. This impacts users who have deployed Gradio locally and use basic authentication. Users are advised to upgrade to `gradio>4.44` to address this issue. As a workaround, users can manually enforce stricter CORS origin validation by modifying the `CustomCORSMiddleware` class in their local Gradio server code. Specifically, they can bypass the condition that skips CORS validation for requests containing cookies to prevent potential exploitation.

Technical summary Written by usOur analysis, written from the advisory, the CVSS vector and the affected-version data. It adds context the advisory leaves out, and never invents facts that are not in the source.

dbcve analysis · high confidence

Gradio's CORS origin validation fails when a cookie is present in the request, causing the server to skip origin checks entirely. This allows malicious websites to make authenticated requests to local Gradio servers, enabling file uploads, token theft, and unauthorized data access.

MitigationUpgrade to Gradio version >4.44, or manually modify CustomCORSMiddleware to enforce origin validation even when cookies are present.

Verify against the referenced sources before acting — the references below are authoritative for this CVE, this summary is not.

Affected products & versions What the vendor confirmedThe version ranges the vendor confirmed as vulnerable. If your version sits inside a range here, treat yourself as exposed until you have upgraded.

NVD · CPE data
GradioApplication
Affected:< 4.44.0

CVSS breakdown How the score is builtThe industry scoring standard. It rates how the flaw is reached, what it takes to exploit, and what an attacker gains — the score is derived from those, not the other way round.

From the vector
Attack vector
Network
Complexity
Low
Privileges
None
User interaction
Required
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
Low

CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:L

Am I affected? How to checkSteps we derive from the advisory and the affected-version data, so you can decide whether this CVE reaches your setup. They are a guide, not a scan — your own configuration is the authority.

dbcve checks

Work through these to decide whether this CVE applies to you.

  1. Check installed Gradio version
    Run 'pip show gradio' or 'pip list | grep gradio' to find the installed version number
    Affected if The version displayed is less than 4.44.0 (e.g., 4.40.0, 4.36.0, etc.)
  2. Identify if cookie-based authentication is in use
    Search your Gradio application code for 'cookie', 'session', 'auth', or similar token-based authentication patterns. Check for any app.launch() parameters or middleware that set cookies
    Affected if Your Gradio app sets, reads, or relies on cookies for authentication or session management
  3. Inspect CORS configuration
    Search your codebase for CustomCORSMiddleware usage or CORS-related parameters in your Gradio app (e.g., cors_allowed_origins, allowed_origins). Check if Gradio's default CORS handling is in use
    Affected if CORS is configured but allows any origins, or the default Gradio CORS behavior is in use without custom middleware that enforces origin validation
  4. Verify if requests with cookies reach the Gradio server
    Review your application's access logs or proxy configuration to confirm whether incoming requests from browsers include Cookie headers. Check if the server processes requests that carry cookies from client browsers
    Affected if Your Gradio server processes HTTP requests that contain Cookie headers from client browsers

You are affected if you run Gradio version below 4.44.0 AND your application handles requests that include cookies, which bypasses the CORS origin validation entirely.

Generated from the published advisory. Verify against your own configuration.

Check your environment

Paste your version and any relevant configuration and it will be compared against the affected criteria above. Do not include secrets or credentials.

AI-assisted, checked against the advisory. Informational, not a guarantee.

Remediation Closing itWhat it takes to close this. Where a vendor fix exists we point at it; where none exists we say so plainly, and can build one. Effort estimates are scoped from the advisory, not from your codebase.

dbcve · scoped
Upgrade available Upgrade to 4.44.0 or later
Fixed in 4.44.0
Interim mitigation

Upgrade to Gradio version >4.44, or manually modify CustomCORSMiddleware to enforce origin validation even when cookies are present.

Recommended fix High confidence

gradio>=4.44.0

  1. 1. Upgrade Gradio to version 4.44.0 or later by running: pip install --upgrade gradio
  2. 2. Verify the installed version with: pip show gradio | grep Version
  3. 3. Restart any running Gradio servers to load the updated package
  4. 4. (Alternative if upgrade is not possible) Locate the CustomCORSMiddleware class in the Gradio source code and modify it to perform CORS origin validation even when cookies are present in the request, removing the condition that skips validation for cookie-containing requests

Generated from the published advisory — verify against the referenced sources before acting.

Fix this in Gradio Scoped from the published advisory
  • Consultation2.0 h
  • Implementation4.0 h
  • Testing2.0 h
  • Review / QA1.0 h
9.0 hours of engineering $1,600
Get the upgrade done

An estimate, not a bill — we confirm scope with you before any work starts. Need it this week? Rush from $2,560.

Scan for this in your stack

Free · runs locally
dbcve dependency scanner

Check whether your project pulls in CVE-2024-47084 — or any other known-vulnerable package — straight from your lock files. Free and open source; it runs locally and uploads nothing.

References Go to the primary sourcePrimary sources — vendor advisories, patches and trackers. Where our summary and a reference disagree, the reference wins.

Primary sources

Practitioner notes

Contributed

Peer-ranked notes from engineers who’ve handled CVE-2024-47084 in production — separate from our analysis above.

No notes yet

Be the first to add a field note for this CVE — a mitigation you’ve verified, a version caveat, or a link to a working fix. Sign in above to contribute.

What this is

A place for practitioners to share what actually worked: a mitigation you’ve tested, a configuration change, a version- or environment-specific caveat, or a link to a verified patch. The most useful notes rise to the top as peers upvote them, so the signal stays high.

What belongs here
  • Verified mitigations, workarounds, and config changes
  • Version or environment caveats, and links to real fixes
  • No weaponised exploit code, or anything meant to cause harm
  • No spam, self-promotion, credentials, or personal data