CVE-2026-134292: SurrealDB 1.0.0 before 4.0.0 Function Capability Bypass via JavaScript Built-in Bridge
Exploitation: None known · CVSS 9.8 Critical · Unauthenticated · Published 2026-11-21
Description
SurrealDB 1.0.0 before 4.0.0 contains a capability check bypass in its embedded JavaScript scripting engine, where the surrealdb.functions bridge calls the internal fnc::synchronous() and fnc::asynchronous() dispatchers without enforcing function capability checks. Authenticated users denied access to built-in functions in SurrealQL can execute them by calling them through surrealdb.functions from embedded JavaScript.
Enclave's analysis
SurrealDB's embedded JavaScript bridge calls built-in functions directly, skipping the capability checks SurrealQL normally enforces. An authenticated session that's been denied certain functions can get them back by calling them from embedded JS instead. It only bites when scripting is turned on and the deployment already restricts functions per-session — both non-default setups. No public exploit or active abuse has surfaced yet; patch to 4.0.0 or turn off scripting if you don't need it.
Fix
Upgrade surrealdb to 4.0.0; surrealdb (cargo crate / SurrealDB server) to 4.0.0.
Affected versions
| Product | Vulnerable | Fixed in |
|---|---|---|
| surrealdb | 1.0.0 before 4.0.0 | 4.0.0 |
| surrealdb (cargo crate / SurrealDB server) | >=1.0.0, <4.0.0 | 4.0.0 |