highCVSS 7.5Vulnerability

GHSA-wjjj-24cx-f28g

A single unauthenticated WebSocket message to `/rpc` crashed the SurrealDB server. Sending `use { db: "x" }` without first selecting a namespace hit `.expect("namespace should be set")` in the `use` handler; because `surrealdb-core` is built with `panic = 'abort'`, the panic terminated the process. `use` is callable before `signin`, and the per-method capability check passes by default for guest callers — so no credentials, token, or `--allow-guests` flag are required. ### Impact An unauthenticated remote attacker who could reach the `/rpc` endpoint could crash the SurrealDB server with a single WebSocket message. No credentials, token, session knowledge, or capability are required. ### Patches A patch has been introduced that returns a typed `invalid_params` response when `db` is set on a session with no `ns`, replacing the panic. - Versions 3.1.0 and later are not affected by this issue. ### Workarounds Affected users who are unable to update should restrict network access to the `/rpc` endpoint to trusted clients, and run SurrealDB under a process supervisor that restarts on crash.

Properties

ghsa_id
GHSA-wjjj-24cx-f28g
summary
SurrealDB has unauthenticated remote DoS via malformed RPC `use` call
severity
high
cvss_score
7.5
cve_id
GHSA-wjjj-24cx-f28g
cvss_vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
is_ghsa_only
true
ghsa_published
2026-07-01T20:04:22Z
source_url
https://github.com/advisories/GHSA-wjjj-24cx-f28g
ghsa_updated
2026-07-01T20:04:23Z

Related Entities (5)

HAS_WEAKNESS (2)

[Weakness]Uncaught Exception
[Weakness]Improper Check for Unusual or Exceptional Conditions

REPORTED_BY (1)

[Source]GitHub Advisory Database

VULNERABLE_TO (1)

[Software]rust/surrealdb

AFFECTS (1)

[Software]rust/surrealdb

Explore deeper with Ninja Signal's threat intelligence graph

GHSA-wjjj-24cx-f28g (CVSS 7.5) — Ninja Signal Threat Intelligence | Ninja Signal