Skip to main content

CVE-2026-63735 — Vulnerability in surrealdb — CVE Details

HIGH

SurrealDB: Custom API route lets authenticated callers override namespace/database scope via URL path

Published September 4, 2026Updated September 4, 2026Source: OSV

What Should I Do?

Address in Next Maintenance Window

Low exploitation probability (0.37%). Schedule for your next planned update.

Does your project use an affected surrealdb version?

Paste your Cargo.lock to check it for CVE-2026-63735 and every other known vulnerability, with CISA KEV and EPSS on each finding. Free with no signup for up to 10 packages, or up to 500 per scan with a free account, which also keeps up to 200 packages in saved projects.

Check my Cargo.lock

Summary

An authenticated user scoped to one namespace/database could invoke a custom API (DEFINE API) belonging to a different namespace/database, reaching another tenant's endpoint.

The route /api/{namespace}/{database}/{endpoint} took the namespace and database from the URL and applied them to the caller's session before the endpoint was looked up or run, without checking that the caller's authenticated scope covered them. Because a custom API handler runs with permissions disabled (definer's rights), the endpoint's own PERMISSIONS clause was the only gate — open to everyone for a PERMISSIONS FULL endpoint. The api::invoke() function was affected the same way, resolving against the session's selected namespace/database (settable via the surreal-ns / surreal-db headers or USE).

Impact

What an attacker can do:

  • With valid credentials for any one namespace/database (a VIEWER is enough), invoke a custom API in another namespace/database by naming the victim scope in the URL.
  • Read data that endpoint returns — including from PERMISSIONS NONE tables, since the handler runs with permissions disabled — or trigger any writes and side effects it performs.

What it can't do:

  • Reach a scope without valid credentials for some namespace/database on the instance; this is not an unauthenticated bypass.
  • Affect single-tenant deployments, or any deployment where callers already hold instance-wide (root) scope.

Patches

The namespace/database is now validated against the caller's authenticated level — which the request cannot change — before the endpoint is resolved or run. A target scope outside that level is rejected with 403 Forbidden, both at the HTTP entry point and at the dispatch step shared with api::invoke(). Root reaches any scope; namespace principals their namespace; database and record principals their exact namespace/database; anonymous callers remain governed by the endpoint's PERMISSIONS.

  • Versions 3.2.0 and later are not affected by this issue.

Workarounds

Users unable to patch should consider the following workarounds:

  • Disable the custom API HTTP route via capabilities where it is not required.
  • Treat separate deployments, not namespace/database boundaries, as the tenant isolation boundary on shared instances.
  • Prefer a PERMISSIONS WHERE clause that checks the authenticated identity over PERMISSIONS FULL (reduces exposure but does not restore the boundary).

Resources

Acknowledgements

SurrealDB thanks sondt99 for reporting this issue.

Advisory Timeline

  • First published September 4, 2026 (83 days ago).
  • Last revised September 4, 2026 — 0 days after initial publication.

Remediation

Upgrade to the fixed version using your package manager.

Cargo
Update surrealdb to 3.2.0 or later
cargo update -p surrealdb --precise 3.2.0

After upgrading, scan your dependencies again to confirm the vulnerability is resolved.

Affected Packages (1)

Affects 1 ecosystem: crates.io (1).

PackageFixed In
surrealdb crates.io · Affected: All versions3.2.0

Vulnerability Classification

Common Weakness Enumeration (CWE) identifiers for this vulnerability type.

  • CWE-639
    Insecure Direct Object Reference (IDOR)MITRE
  • CWE-862
    Missing AuthorizationMITRE

CVSS Score Breakdown

What the CVSS (Common Vulnerability Scoring System) 8.1 score means for each attack dimension.

Attack Vector
Network
Attack Complexity
Low
Privileges Required
Low
User Interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
None

CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:N

Frequently Asked Questions

What is CVE-2026-63735?
SurrealDB: Custom API route lets authenticated callers override namespace/database scope via URL path. This vulnerability has been assigned a severity rating of HIGH (CVSS score: 8.1/10).
How do I check if my project is affected by CVE-2026-63735?
CVE-2026-63735 affects surrealdb. It has a 0.4% probability of exploitation within 30 days (EPSS score). Use GeekWala's free vulnerability scanner to check your dependencies against CVE-2026-63735 and 200,000+ other known vulnerabilities.

Severity & Exploitability

CVSS Score
8.1

Significant impact if exploited, or exploitable with modest effort.

EPSS Score (30-day exploit probability)
0.37%
EPSS percentile: 22.8

This is a below-median EPSS score — only 22.8% of tracked vulnerabilities score at or below it, so most tracked vulnerabilities are considered more likely to be exploited than this one.

Also Known As

GHSA-848m-r628-vrxw

Related CVEs

Check your own dependencies

Free, with no signup for up to 10 packages.

Check my Cargo.lock