CVE-2026-35526: strawberry-graphql Denial of Service Vulnerability

HIGH
Advisory Identifier: GHSA-hv3w-m4g2-5x77
CVSS 7.5
CWE-400 CWE-770
Published
Advisory Summary

CVE-2026-35526 is a HIGH (CVSS 7.5) denial of service vulnerability (CWE-400: Uncontrolled Resource Consumption) affecting strawberry-graphql libraries in the PyPI ecosystem. The issue involves denial of service via unbounded websocket subscriptions. Remediation is available by upgrading affected packages to version 0.312.3.

CVE-2026-35526 at a Glance

CVE Identifier CVE-2026-35526
GHSA Identifier GHSA-hv3w-m4g2-5x77
Severity HIGH
CVSS v3.1 Base Score 7.5
CWE Classification CWE-400: Uncontrolled Resource Consumption
Affected Product strawberry-graphql
Package Ecosystem PyPI
Published Date
Last Updated

Security Impact

CVSS: 7.5

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required None (PR:N)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality None (C:N)
Integrity None (I:N)
Availability High (A:H)

How to Fix CVE-2026-35526

To remediate this vulnerability, upgrade all affected strawberry-graphql dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

strawberry-graphql fixed: 0.312.3
pip install strawberry-graphql>=0.312.3
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

pip show strawberry-graphql

How to Check if You Are Affected

To determine whether your Python environment is affected by CVE-2026-35526, inspect your installed packages using pip:

pip show strawberry-graphql

Analyze the terminal output to locate any version of strawberry-graphql in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 0.312.3), your application is affected.

Note: The pip show strawberry-graphql command checks currently installed packages in your active Python environment.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-400: Uncontrolled Resource Consumption, where the product does not properly control the allocation and maintenance of a limited resource. In strawberry-graphql, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

Strawberry GraphQL's WebSocket subscription handlers for both the `graphql-transport-ws` and legacy `graphql-ws` protocols allocate an `asyncio.Task` and associated `Operation` object for every incoming subscribe message without enforcing any limit on the number of active subscriptions per connection. An unauthenticated attacker can open a single WebSocket connection, send connection_init, and then flood subscribe messages with unique IDs. Each message unconditionally spawns a new `asyncio.Task` and async generator, causing linear memory growth and event loop saturation. This leads to server degradation or an OOM crash.

CVE-2026-35526 Affected strawberry-graphql Versions

1 component(s)
Fixed Versions:
0.312.3
Product / Package Ecosystem Affected Versions Fixed Version
strawberry-graphql
PyPI
< 0.312.3
0.312.3

References

Frequently Asked Questions

What is CVE-2026-35526?
CVE-2026-35526 is a security vulnerability in strawberry-graphql involving Denial of Service via unbounded WebSocket subscriptions under CWE-400: Uncontrolled Resource Consumption.
Which strawberry-graphql versions are affected?
Affected versions include releases prior to 0.312.3 across affected packages: strawberry-graphql.
What version fixes CVE-2026-35526?
Upgrading to 0.312.3 (or the latest patched release for your respective branch) resolves the vulnerability.
Is strawberry-graphql affected?
Yes, strawberry-graphql is affected in releases prior to 0.312.3. Upgrade your dependency to 0.312.3 or later.
What is the CVSS score of CVE-2026-35526?
CVE-2026-35526 has a CVSS v3.1 base score of 7.5 (HIGH) with vector string CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H.
What CWE is associated with CVE-2026-35526?
CVE-2026-35526 is classified under CWE-400: Uncontrolled Resource Consumption (The product does not properly control the allocation and maintenance of a limited resource.).
How can I check PyPI dependencies for CVE-2026-35526?
Run the dependency tree command: 'pip show strawberry-graphql'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-hv3w-m4g2-5x77",
  "modified" : "2026-06-08T19:51:02Z",
  "published" : "2026-04-06T18:00:29Z",
  "aliases" : [ "CVE-2026-35526" ],
  "summary" : "strawberry-graphql: Denial of Service via unbounded WebSocket subscriptions",
  "details" : "Strawberry GraphQL's WebSocket subscription handlers for both the `graphql-transport-ws` and legacy `graphql-ws` protocols allocate an `asyncio.Task` and associated `Operation` object for every incoming subscribe message without enforcing any limit on the number of active subscriptions per connection.\n\nAn unauthenticated attacker can open a single WebSocket connection, send connection_init, and then flood subscribe messages with unique IDs. Each message unconditionally spawns a new `asyncio.Task` and async generator, causing linear memory growth and event loop saturation. This leads to server degradation or an OOM crash.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "PyPI",
      "name" : "strawberry-graphql"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "0.312.3"
      } ]
    } ],
    "database_specific" : {
      "last_known_affected_version_range" : "<= 0.312.2"
    }
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/strawberry-graphql/strawberry/security/advisories/GHSA-hv3w-m4g2-5x77"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-35526"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/strawberry-graphql/strawberry/commit/0977a4e6b41b7cfe3e9d8ba84a43458a2b0c54c2"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/pypa/advisory-database/tree/main/vulns/strawberry-graphql/PYSEC-2026-134.yaml"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/strawberry-graphql/strawberry"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/strawberry-graphql/strawberry/releases/tag/0.312.3"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-400", "CWE-770" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-04-06T18:00:29Z",
    "nvd_published_at" : "2026-04-07T16:16:28Z"
  }
}