Junglewise Threat Intelligence

CVE-2026-63739: SurrealDB arbitrary file read in DEFINE ANALYZER mapper filter

CVE-2026-63739 · Severity: high · CVSS 7.7 · Published 2026-07-20

Vendors: SurrealDB.

Executive brief

SurrealDB, a multi-model cloud database, contains a security flaw that allows certain database users to read sensitive files from the underlying server. By exploiting a specific text analysis feature, an attacker with existing database access could view system configuration files or credentials, potentially leading to full control over the database instance. This issue is particularly dangerous because the default security settings did not restrict file access as intended.

Technical details

An arbitrary file read vulnerability exists in SurrealDB's full-text search 'DEFINE ANALYZER' functionality, specifically within the 'mapper' filter. The root cause is a failure to enforce path restrictions when the 'SURREAL_FILE_ALLOWLIST' configuration is empty or unset, which was the default behavior. Authenticated attackers with EDITOR or OWNER roles can provide arbitrary file paths to the mapper filter; the system then leaks the file contents (typically the first line) within query error messages. This can be used to extract sensitive environment variables, startup credentials, or system files. The vulnerability is patched in version 3.1.5, which implements a 'deny-by-default' policy for file access and removes file content from error logs.

Affected products

  • SurrealDB SurrealDB < 3.1.5

Timeline

  • 2026-06-19: advisory: GitHub Security Advisory published
  • 2026-07-20: disclosed: NVD publication date
  • 2026-07-20: patched: Version 3.1.5 released

References