Read the docs
TI-2025-43641 Aliases GHSA-2cvj-g5r5-jrrg

SurrealDB has local file read of 2-column TSV files via analyzers

Priority LOW 38CWE-22Published · Updated

Key facts

Attack vector
—
Privileges required
—
User interaction
—
Attack complexity
—
Impact type
—
Confidentiality · integrity · availability
—
Fix status
Fixed

No CVSS vector from any source. Fix status from GitHub.

Summary

An authenticated system user at the root, namespace, or database levels can use the `DEFINE ANALYZER` statement to point to arbitrary file locations on the file system, and should the file be tab separated with two columns, the analyzer can be leveraged to exfiltrate the content. This issue was discovered and patched during an code audit and penetration test of SurrealDB by cure53, the severity defined within cure53's preliminary finding is Low, matched by our CVSS v4 assessment. ### Impact Limited to unauthorised access to 2 column TSV files on the file system ### Patches A patch has been created that introduces a new environment variable, `SURREAL_FILE_ALLOWLIST` , which contains a list of allowed file paths. When a mapping file is processed, the mapper checks if the file’s path is within one of the allowed paths. - Versions 2.1.5, 2.2.2 and later are not affected by this issue. ### Workarounds Users unable to update may want to limit those with root, namespace, or database level users to trusted parties only. ### References [SurrealQL Documentation - DEFINE ANALYZER](https://surrealdb.com/docs/surrealql/statements/define/analyzer#define-analyzer-statement) [#5600](https://github.com/surrealdb/surrealdb/pull/5600)

Why it matters now

Fix Fixed surrealdb (crates.io): 2.2.2, 2.1.5

SSVC decision points

Not available: CISA has not published SSVC decision points for this record.

Affected products

VendorProductAffected versionsFixed inStatusSource
—surrealdb (crates.io)2.2.0 to before 2.2.22.2.2Patch availableGHSA-2cvj-g5r5-jrrg
—surrealdb (crates.io)before 2.1.52.1.5Patch availableGHSA-2cvj-g5r5-jrrg
  • surrealdb (crates.io) Vendor— Affected 2.2.0 to before 2.2.2 Fixed in 2.2.2 Patch available GHSA-2cvj-g5r5-jrrg
  • surrealdb (crates.io) Vendor— Affected before 2.1.5 Fixed in 2.1.5 Patch available GHSA-2cvj-g5r5-jrrg

Remediation

  • Fix · GHSA-2cvj-g5r5-jrrg surrealdb (crates.io) Fixed in 2.2.2 Advisory →
  • Fix · GHSA-2cvj-g5r5-jrrg surrealdb (crates.io) Fixed in 2.1.5 Advisory →

Timeline

  1. 2026-10-03 Threatist record created from GHSA-2cvj-g5r5-jrrg

References

Sources

This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences