Skip to main content

SurrealDB EUVDEUVD-2026-136584

| CVE-2026-137490 HIGH
Missing Authorization (CWE-862)
2026-11-26 VulnCheck
8.7
CVSS 4.0 · Vendor: VulnCheck
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Authenticate as restricted subject with script permission
  2. Delivery
    Invoke permitted JavaScript function
  3. Exploit
    Call surrealdb.query() bridge bypassing allows_query() gate
  4. Execution
    Execute arbitrary SurrealQL
  5. Impact
    Exfiltrate or tamper with database contents

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A01:2025 - Broken Access Control
ASVS 5.0
V8 - Authorization Authorization checks on every request
MITRE ATT&CK

1 technique across 1 tactic: Privilege Escalation

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires that the embedded JavaScript scripting engine be in use and that the attacker be an authenticated subject explicitly permitted to run a specific script - i.e., a subject whose capabilities deny arbitrary queries (Capabilities::allows_query() would return false) but allow script execution. From inside that permitted script, the attacker calls the surrealdb.query() bridge, which parses and executes queries without checking allows_query(). Limiting factors: the attacker must already hold valid (low-privileged) credentials and script-run permission, so an instance that does not grant restricted subjects any scripting capability, or that does not expose JavaScript functions, is not exploitable via this path. Not exploitable anonymously and not against configurations where scripting is disabled. Complete fix is upgrading to SurrealDB 4.0.0 or later, which enforces query and function capabilities inside the JavaScript bridge; the advisory presents the update as the remediation.

Impact

This is a credible, prioritize-this-week issue rather than a hypothetical high-CVSS flaw, though it is not an emergency on current signals. The CVSS 4.0 vector (AV:N/AC:L/AT:N/PR:L/UI:N) and the 8.7 score indicate a network-reachable, low-complexity bypass requiring only low privileges - specifically a subject already authenticated and permitted to run a particular JavaScript script. All three impact dimensions are High (VC:H/VI:H/VA:H): a successful bypass yields unrestricted query execution, which in a database means full read, write, and availability impact to the data the server holds. Subsequent-system impact is None (SC/SI/SA:N), so this is confined to the SurrealDB instance's own data boundary rather than pivoting to other systems. The input provides no EPSS score, no CISA KEV listing, and no PoC/exploit reference - only the GHSA advisory and the VulnCheck advisory - so exploitation is best described as plausible-but-unproven in the wild. The vuln.today decision label is 'this_week' (not act_now/emergency), consistent with a serious authorization-bypass that is patched but not yet shown to be actively exploited. The main caveat limiting real-world risk is the precondition: the attacker must already be an authenticated, albeit restricted, subject with permission to run scripting functions, so this is a privilege-escalation-within-the-database problem, not an anonymous remote takeover.

Exploit ScenarioDerived

An authenticated SurrealDB subject whose capabilities deny arbitrary queries but allow running a specific JavaScript scripting function invokes the surrealdb.query() bridge from inside that script. Because the bridge parses and executes the supplied query without consulting Capabilities::allows_query(), the restricted subject runs arbitrary SurrealQL beyond its intended operations, reading or modifying any data the server process can access. No public exploit was identified in the provided data; triggering only requires that scripting functions be enabled and reachable by the restricted subject.

This Week Schedule remediation this week. Why: HIGH severity (CVSS 7.0-8.9).
Patch available 0.6% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Nov 26, 2026

SurrealDB releases before 4.0.0 fail to check query capability inside the embedded JavaScript bridge, so a low-privileged subject who is allowed to run one specific script can call surrealdb.query() from that script and execute arbitrary queries the session's capabilities explicitly deny. Exploitation requires valid credentials plus script-run permission on a deployment that exposes the JavaScript scripting functions; anonymous access or configurations with scripting disabled are not affected via this path. CVSS v3.1 scores it 8.7 (network, low privileges, high confidentiality/integrity/availability impact); no public exploit code or active exploitation is identified at time of analysis, and the priority label is this-week rather than emergency.

RemediationAI

Upgrade to SurrealDB 4.0.0 or later, which enforces query and function capabilities inside the embedded JavaScript bridge so a script can no longer run queries or functions the session denies; the advisory presents updating as the remediation and the change landed in commit 0b8be14543. The vendor advisory at https://github.com/surrealdb/surrealdb/security/advisories/GHSA-fq69-wr4w-v3gm is the authoritative reference for the fixed release. Where the upgrade cannot be applied promptly, the practical compensating control is to stop granting script-run permission to subjects whose capabilities deny arbitrary queries and to keep JavaScript scripting functions unavailable to low-privileged roles, since the bypass only exists for callers inside a permitted script; the trade-off is that legitimate SurrealQL scripting workflows used by those subjects will break until they are moved to trusted roles or scripting is re-enabled after upgrading. Restricting script permission is a narrowing of exposure rather than a complete fix, because any subject still able to run a script retains the bypass on a patched-pending instance.

Affected VersionsENISA

surrealdb 0 <4.0.0

Affected Packages

euvd surrealdb fix: 4.0.0

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in euvd

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

SurrealDB is a Rust-implemented multi-model database whose SurrealQL language supports embedding JavaScript scripting functions, and access control for that scripting surface runs through a Capabilities configuration. The relevant gate is Capabilities::allows_query(), which determines whether a subject may execute arbitrary queries; nested queries issued from SurrealQL functions do consult this gate, but the JavaScript bridge implemented in surrealdb/core/src/fnc/script/modules/surrealdb/query/mod.rs parses and executes the supplied query string without ever calling allows_query(). This is a CWE-862 Missing Authorization weakness: the enforcement point exists but is simply not invoked on one code path, so the intended policy boundary between 'may run a named script' and 'may run arbitrary SurrealQL' collapses. The trigger is described in the source evidence as a script calling surrealdb.query() with attacker-supplied query text; the fix commit (0b8be14543, 'fix(script): JS bridge bypasses the query and function capabilities') enforces both the query and function capabilities inside the embedded JavaScript bridge, and 4.0.0 and later are unaffected. Note that the reported CVSS 4.0 vector is E:X (no exploitation maturity asserted), and the independent assessment re-rates the issue as CVSS 3.1 AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H.

Know when Surrealdb gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (VulnCheck) PRIMARY 8.7 HIGH
CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N
vuln.today AI 8.8 HIGH

Network-reachable bridge, low complexity, requires an authenticated restricted subject with script permission (PR:L), yielding full read/write/availability over database data within one security scope (S:U).

3.1 AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
4.0 AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N

Primary rating from Vendor (VulnCheck).

CVSS VectorVendor: VulnCheck

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
None
Privileges Required
Low
User Interaction
None
Vulnerable system: Confidentiality
High
Vulnerable system: Integrity
High
Vulnerable system: Availability
High
Subsequent system: Confidentiality
None
Subsequent system: Integrity
None
Subsequent system: Availability
None

Lifecycle Timeline

2
Patch available
Nov 26, 2026 - 17:02 EUVD
CVE Published
Nov 26, 2026 - 16:01 cve.org
HIGH 8.7

DescriptionCVE.org

SurrealDB before 4.0.0 contains an authorization bypass vulnerability that allows restricted subjects to execute arbitrary queries by calling the JavaScript surrealdb.query() bridge. Attackers permitted to run a specific script can bypass the Capabilities::allows_query() gate in the query module to execute unrestricted queries beyond their predefined operations.

Technical POC Analysis

CWE-862, Missing Authorization.

Full technical POC analysis - root cause, step-by-step exploitation and patch breakdown - is part of the Pro and Business plans.

Executive ViewAI

Why It Matters

SurrealDB database deployments prior to version 4.0.0 with JavaScript scripting enabled permit a low-privileged authenticated user to bypass query capability restrictions, enabling execution of arbitrary database queries. This can lead to unauthorized access, modification, or deletion of sensitive data, directly impacting data confidentiality, integrity, and availability. Leadership should prioritize remediation because trusted insiders or compromised low-privilege accounts could exploit this flaw to escalate privileges and compromise critical data stores.

Business Impact: High
Compensating Controls

No vendor-released patch identified at time of analysis. Interim mitigations: disable JavaScript scripting entirely, or restrict script-run permissions to trusted administrators only; enforce strict credential management and monitor for anomalous query activity.

Threat Intelligence Overview

EPSS Score
0.6%
Top 59% exploitable
Prevalence
Low
emerging multi-model database, limited production enterprise footprint
Data Quality
5 sources
Confidence: Medium

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity HIGH
CISA KEV No
Public POC No
EPSS 0.6%
Patch available Yes
Active threat No
Deciding rule
HIGH severity (CVSS 7.0-8.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation· derived
None
System Exposure· derived
Open
Automatable· derived
No
Human Impact
High

Priority Score

45
Low Medium High Critical
KEV: 0
EPSS: +1
CVSS: +44
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Authentication bypass attacks exploit flaws in the verification mechanisms that control access to systems and applications.

CVE-2025-71392 CRITICAL
9.4 Jul 18

Privilege escalation via second-order SurrealQL injection in SurrealDB before 2.0.5, 2.1.5, and 2.2.2 lets an authentica

CVE-2026-134292 CRITICAL
9.3 Nov 21

SurrealDB versions 1.0.0 through 3.x (before 4.0.0) fail to enforce built-in function capability checks inside the embed

CVE-2026-63756 CRITICAL
9.2 Jul 20

Privilege escalation in SurrealDB before v3.1.0 lets unauthenticated attackers hijack the privileges of concurrently-act

CVE-2026-134299 HIGH
8.7 Nov 21

Memory exhaustion in SurrealDB 3.0.4 through 3.x lets unauthenticated remote clients pin up to 64 MiB of in-flight WebSo

CVE-2026-134293 HIGH
8.8 Nov 21

SQL injection in the Model Context Protocol (MCP) server component of SurrealDB 3.1.0 through 3.x (fixed in 4.0.0) allow

CVE-2026-134295 HIGH
8.7 Nov 21

Authenticated tenants of SurrealDB 3.0.0 through 3.x can escape key-based ACL boundaries in direct filesystem buckets an

CVE-2026-134291 HIGH
8.7 Nov 21

Filesystem bucket path traversal in SurrealDB 3.0.0 before 4.0.0 allows an attacker with bucket-operation access to read

CVE-2026-134309 HIGH
8.7 Nov 21

SurrealDB 1.0.0 through 3.x lets an authenticated user with only the database-level VIEWER role read, modify, and delete

CVE-2026-121417 HIGH
8.8 Nov 03

Use-after-free in SurrealDB Core before 3.3.0 can crash or corrupt memory in Rust applications that embed the database a

CVE-2026-134294 HIGH
8.7 Nov 21

Cross-bucket file disclosure and modification on Windows affects SurrealDB versions 3.0.0 up to but not including 4.0.0

CVE-2026-63760 HIGH
8.7 Jul 20

Denial of service in SurrealDB before 3.1.0 lets an unauthenticated remote attacker crash the database with a single Web

CVE-2026-63747 HIGH
8.7 Jul 20

Denial of service in SurrealDB before 3.1.0 lets an unauthenticated remote attacker crash the entire database process wi

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy