CVEReports
CVEReports

Automated vulnerability intelligence platform. Comprehensive reports for high-severity CVEs generated by AI.

Product

  • Home
  • Sitemap
  • RSS Feed

Company

  • About
  • Contact
  • Privacy Policy
  • Terms of Service

© 2026 CVEReports. All rights reserved.

Made with love by Amit Schendel & Alon Barad



CVE-2026-107728

CVE-2026-107728: Authorization Bypass in Strawberry GraphQL Permission Validation

Amit Schendel
Amit Schendel
Senior Security Researcher

Oct 9, 2026·5 min read·2 visits

Executive Summary (TL;DR)

Strawberry GraphQL fails to validate the return types of synchronous permission functions, allowing unawaited coroutines to evaluate as True and bypass access control.

An authorization bypass vulnerability in Strawberry GraphQL between versions 0.217.0 and 0.326.1 occurs when a synchronous permission handler returns an awaitable object (such as an unawaited coroutine). Due to Python's truthiness rules, the unawaited coroutine is evaluated as True, leading to an immediate bypass of security policies.

Vulnerability Overview

Strawberry GraphQL is a widely utilized Python library designed to build GraphQL APIs. The framework supports validating fields through permission classes, which check if the requesting user possesses the required authorizations before executing the corresponding field resolvers. This mechanism supports both synchronous and asynchronous modes of operation.

Between versions 0.217.0 and 0.326.1, a flaw exists in how the library handles synchronous field permission checks that return awaitable objects. The vulnerability allows an unauthenticated or unauthorized remote attacker to bypass permission validations. The flaw originates in the PermissionExtension.resolve() method, which performs direct truthiness checks on results returned from synchronous permission functions.

This vulnerability introduces a risk of unauthorized data disclosure, as custom permission decorators can be silently bypassed. Field resolvers that were intended to be private or restricted become accessible to any client.

Root Cause Analysis

The vulnerability is caused by a design discrepancy in Python's evaluation of coroutine objects coupled with the limitation of the supports_sync utility in Strawberry GraphQL. The library checks the asynchronous status of a permission class via inspect.iscoroutinefunction(permission.has_permission). If a developer defines the has_permission method using a standard synchronous declaration (def), this check evaluates to False.

Consequently, execution is routed through the synchronous path inside PermissionExtension.resolve(). If the developer's synchronous implementation returns an unawaited coroutine—for example, by calling an internal asynchronous function or external database wrapper without an asynchronous loop—the permission class returns a coroutine object instead of a boolean value.

In Python, all coroutines and awaitable objects evaluate to True when evaluated in a boolean context. The synchronous resolver checks truthiness using 'if not permission.has_permission(...)'. Because the returned coroutine object evaluates to True, the if statement evaluates to False, skipping the unauthorized logic path. The library assumes the check succeeded and executes the resolver, resulting in an authorization bypass.

Here is a visual mapping of the vulnerable execution flow:

Code Analysis

The vulnerability resides in the validation path of strawberry/permission.py. When checking permissions, the code originally executed the permission verification directly within an 'if not' statement.

Below is the vulnerable implementation within strawberry/permission.py:

def resolve(self, next_, source, info, **kwargs) -> Any:
    for permission in self.permissions:
        # Vulnerable: If has_permission returns a coroutine, 
        # 'not coroutine' is evaluated, which is always False.
        if not permission.has_permission(source, info, **kwargs):
            return self._on_unauthorized(permission)
    return next_(source, info, **kwargs)

The fix introduced in version 0.326.1 checks if the return value of has_permission is awaitable. If inspect.isawaitable(has_permission) returns True in a synchronous context, the system raises an exception rather than proceeding.

Below is the patched implementation:

def resolve(self, next_, source, info, **kwargs) -> Any:
    for permission in self.permissions:
        has_permission = permission.has_permission(source, info, **kwargs)
 
        # Patched: Validate if an awaitable was returned in sync context
        if inspect.isawaitable(has_permission):
            # Close the coroutine to prevent resource leaks
            if inspect.iscoroutine(has_permission):
                has_permission.close()
 
            # Fail closed by throwing an explicit exception
            raise PermissionReturnedAwaitableInSyncContextError(permission)
 
        if not has_permission:
            return self._on_unauthorized(permission)
 
    return next_(source, info, **kwargs)

The fix ensures that any attempt to return an awaitable object inside a synchronous resolution path raises a PermissionReturnedAwaitableInSyncContextError exception. This causes the request to fail closed, preventing exposure of sensitive fields.

Exploitation

An attacker can exploit this bypass if a custom permission class evaluates authorization synchronously but delegates to asynchronous helpers. The exploit requires no special privileges and is executed over the network by sending a standard GraphQL query.

Below is a demonstration of how a vulnerable implementation behaves. The permission class is defined synchronously, but mistakenly returns an unawaited coroutine:

class VulnerableBypassPermission(BasePermission):
    message = "Unauthorized Access"
 
    def has_permission(self, source, info, **kwargs) -> Any:
        async def verify_user():
            # This logic should return False to deny access
            return False
        
        # Returns the coroutine object itself
        return verify_user()

When a request is submitted to the server for a field protected by VulnerableBypassPermission, the engine resolves the field synchronously. Because the returned coroutine object is inherently truthy, the bypass is completed, and the backend resolves the field despite the logic within verify_user evaluating to False.

Impact Assessment

The impact of this vulnerability is classified as High, with a CVSS v3.1 base score of 7.5. The vulnerability allows complete bypass of application-level access controls designed to secure specific GraphQL fields. An attacker can access sensitive information, administrative fields, or trigger operations they are unauthorized to execute.

Because the bypass occurs silently without logging an error or exception, detecting the exploitation via standard application logs can be difficult unless the application monitors the exact types of objects returned by permissions. The exploitation complexity is low, requiring only standard GraphQL query structures.

There is no integrity or availability impact as the flaw is an information leakage and access bypass. However, if the field resolver performs write operations (such as mutations executing under synchronous resolvers), integrity impact could also occur depending on the specific implementation.

Remediation & Detection

To mitigate CVE-2026-107728, developers must upgrade the strawberry-graphql package to version 0.326.1 or higher. The upgraded library implements defensive checks to block the synchronous execution of awaitable objects.

For legacy deployments where immediate patching is not possible, developers must audit all BasePermission subclasses. Ensure that any has_permission function using standard def returns a primitive boolean. If asynchronous functions must be invoked, the method should be redeclared as async def.

A Semgrep rule can automate the identification of vulnerable patterns. The rule should flag any synchronous has_permission function that returns calls to functions known to return coroutines or awaitables.

Official Patches

strawberry-graphqlPR 4605: Fix permission validation returning awaitable in sync context

Fix Analysis (1)

Technical Appendix

CVSS Score
7.5/ 10
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N
EPSS Probability
0.35%
Top 73% most exploited

Affected Systems

strawberry-graphql

Affected Versions Detail

Product
Affected Versions
Fixed Version
strawberry-graphql
strawberry-graphql
>= 0.217.0, < 0.326.10.326.1
AttributeDetail
CWE IDCWE-863
Attack VectorNetwork
CVSS Score7.5
EPSS Score0.00353
EPSS Percentile26.95%
ImpactHigh (Confidentiality)
Exploit StatusProof of Concept
CISA KEV StatusNot Listed

MITRE ATT&CK Mapping

T1068Exploitation for Privilege Escalation
Privilege Escalation
CWE-863
Incorrect Authorization

The product performs an authorization check when an actor attempts to access a resource or perform an action, but it does not correctly prove that the actor has the authorization to do so.

Vulnerability Timeline

Pull request #4605 submitted and merged
2026-08-31
Security Advisory GHSA-pfvf-fwfp-25mp published and CVE-2026-107728 assigned
2026-10-08

References & Sources

  • [1]GitHub Security Advisory GHSA-pfvf-fwfp-25mp
  • [2]Fix PR #4605
  • [3]Fixing Commit
  • [4]Release 0.326.1
  • [5]NVD - CVE-2026-107728
  • [6]CVE-2026-107728

Attack Flow Diagram

Press enter or space to select a node. You can then use the arrow keys to move the node around. Press delete to remove it and escape to cancel.
Press enter or space to select an edge. You can then press delete to remove it or escape to cancel.

More Reports

•about 2 hours ago•CVE-2026-107727
3.7

CVE-2026-107727: Connection-Level Denial of Service via State Leak in Strawberry GraphQL Legacy WS Handler

An uncontrolled resource consumption vulnerability in Strawberry GraphQL allows unauthenticated remote attackers to trigger a Denial of Service on persistent WebSocket connections using the legacy graphql-ws protocol. When the server enforces max_subscriptions_per_connection, naturally terminating subscriptions are not cleared from memory registries, leading to exhaustion of connection slots.

Alon Barad
Alon Barad
5 views•6 min read
•about 3 hours ago•CVE-2026-107723
8.1

CVE-2026-107723: Silent Claim-Validator Bypass in NearForm fast-jwt via Array Payload Type Confusion

A high-severity type-confusion vulnerability exists in NearForm fast-jwt prior to version 6.3.0. The vulnerability allows attackers to bypass crucial claim validation steps (such as expiration, issuer, audience, and subject validations) by presenting a validly signed JSON Web Token structured as a JSON array instead of a JSON object. This occurs because the library's decoder fails to reject JSON arrays during type evaluation.

Alon Barad
Alon Barad
7 views•6 min read
•about 4 hours ago•CVE-2026-107721
5.9

CVE-2026-107721: Time Validation Bypass in NearForm fast-jwt due to Loose Temporal Option Validation

NearForm fast-jwt prior to version 6.3.0 is vulnerable to an input validation flaw where configuring verifier properties (such as clockTolerance, clockTimestamp, and cacheTTL) with non-finite values like Infinity or NaN allows attackers to bypass temporal claim validations, including expiration (exp) and activation (nbf) boundaries. This validation bypass can result in unauthorized session persistence and cache poisoning.

Amit Schendel
Amit Schendel
5 views•6 min read
•about 5 hours ago•CVE-2026-107722
9.8

CVE-2026-107722: Algorithm Confusion via Non-Whitespace Prefix Bypass in fast-jwt

A critical cryptographic vulnerability in fast-jwt versions 6.2.x prior to 6.3.0 allows unauthenticated remote attackers to execute an asymmetric-to-symmetric algorithm confusion attack due to incomplete validation of leading non-whitespace prefixes.

Amit Schendel
Amit Schendel
6 views•5 min read
•about 6 hours ago•CVE-2026-107720
7.4

CVE-2026-107720: Signature Verification Bypass in NearForm fast-jwt

CVE-2026-107720 is a critical signature verification bypass vulnerability in NearForm's fast-jwt Node.js library. Under specific configurations where the token verifier is initialized with a falsy cryptographic key (such as an empty string or null) and a non-empty algorithms allowlist, the library erroneously skips signature validation. This allows unauthenticated remote attackers to submit fabricated, unsigned JSON Web Tokens and bypass the authorization boundary of the application entirely.

Amit Schendel
Amit Schendel
7 views•7 min read
•about 7 hours ago•CVE-2026-107715
6.8

CVE-2026-107715: Information Disclosure and Credential Leakage in Ruby Mechanize via Cross-Origin Redirections

Ruby Mechanize prior to version 2.14.1 contains an information disclosure vulnerability. When executing cross-origin HTTP redirects, global headers configured on the Mechanize agent (such as Authorization or Session Cookies) are dynamically re-applied to the subsequent request, bypassing the internal header-stripping logic. An attacker who controls a redirection endpoint can capture sensitive bearer tokens or cookies.

Alon Barad
Alon Barad
9 views•7 min read