GHSA-3h96-34p3-xm76: Graphql GraphQL-Ruby's Ruby Lexer Does Not Vulnerability
MODERATEGHSA-3h96-34p3-xm76 is a MODERATE (CVSS 5.3) graphql-ruby's ruby lexer does not vulnerability (CWE-770: Allocation of Resources Without Limits or Throttling) affecting Graphql libraries in the RubyGems ecosystem. The issue involves graphql-ruby's ruby lexer does not count comment tokens for the purposes of max_query_string_tokens. Remediation is available by upgrading affected packages to version 2.6.1, 2.5.26, 2.4.18, 2.3.23.
GHSA-3h96-34p3-xm76 at a Glance
Security Impact
CVSS: 5.3
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:L).
How to Fix GHSA-3h96-34p3-xm76
To remediate this vulnerability, upgrade all affected 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.
Upgrade graphql to 2.6.1
Upgrade graphql to 2.5.26
Upgrade graphql to 2.4.18
Upgrade graphql to 2.3.23
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
inspect dependencies for graphql
How to Check if You Are Affected
To determine whether your application is affected by GHSA-3h96-34p3-xm76, inspect your project dependencies for Graphql:
inspect dependencies for graphql
Analyze the terminal output to locate any version of Graphql in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 2.6.1), your application is affected.
Note: Verify declared build manifests and deployed runtime container environments.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-770: Allocation of Resources Without Limits or Throttling, where the product allocates a reusable resource or group of resources on behalf of an actor without imposing any intended restrictions on the size or number of resources that can be allocated. In 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
GHSA-3h96-34p3-xm76 Affected Graphql Versions
4 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
graphql
|
RubyGems |
≥ 2.6.0
< 2.6.1
All 1 versions
2.6.0
|
2.6.1
|
|
graphql
|
RubyGems |
≥ 2.5.0
< 2.5.26
|
2.5.26
|
|
graphql
|
RubyGems |
≥ 2.4.0
< 2.4.18
|
2.4.18
|
|
graphql
|
RubyGems |
≥ 2.3.1
< 2.3.23
|
2.3.23
|
References
Frequently Asked Questions
What is GHSA-3h96-34p3-xm76?
Which Graphql versions are affected?
What version fixes GHSA-3h96-34p3-xm76?
Is graphql affected?
What is the CVSS score of GHSA-3h96-34p3-xm76?
What CWE is associated with GHSA-3h96-34p3-xm76?
How can I check RubyGems dependencies for GHSA-3h96-34p3-xm76?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-3h96-34p3-xm76",
"modified" : "2026-05-05T21:51:15Z",
"published" : "2026-05-05T21:51:15Z",
"aliases" : [ ],
"summary" : "GraphQL-Ruby's Ruby lexer does not count comment tokens for the purposes of max_query_string_tokens",
"details" : "GraphQL-Ruby's `max_query_string_tokens` configuration didn't count comment tokens against the limit, allowing strings to be processed even after the configured maximum had actually been reached. \n\nIn patched versions, the Ruby lexer does count these tokens. \n\nGraphQL-CParser is not affected by this problem. \n\n`max_query_string_tokens` was introduced in v2.3.1. Each 2.x version has received a new patch release for including a fix.",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "RubyGems",
"name" : "graphql"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "2.6.0"
}, {
"fixed" : "2.6.1"
} ]
} ],
"versions" : [ "2.6.0" ]
}, {
"package" : {
"ecosystem" : "RubyGems",
"name" : "graphql"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "2.5.0"
}, {
"fixed" : "2.5.26"
} ]
} ]
}, {
"package" : {
"ecosystem" : "RubyGems",
"name" : "graphql"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "2.4.0"
}, {
"fixed" : "2.4.18"
} ]
} ]
}, {
"package" : {
"ecosystem" : "RubyGems",
"name" : "graphql"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "2.3.1"
}, {
"fixed" : "2.3.23"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/rmosolgo/graphql-ruby/security/advisories/GHSA-3h96-34p3-xm76"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/rmosolgo/graphql-ruby"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-770" ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2026-05-05T21:51:15Z",
"nvd_published_at" : null
}
}