SurrealDB: Array element-level (field.*) SELECT permissions leak denied elements to record users (CVE-2026-63740)
SurrealDB versions prior to 3.1.4 contain a vulnerability where array element-level SELECT permissions (field.*) are not correctly enforced for record users. This causes denied array elements to be partially leaked in query results. The issue affects only element-level permissions for record users, not field-level permissions or root/record-owner sessions. The vulnerability impacts confidentiality but does not allow data modification or privilege escalation. A fix is available in SurrealDB 3.1.4.
AI Analysis
Technical Summary
SurrealDB's enforcement of SELECT permissions on array elements (field.*) is flawed for record users. When a SELECT permission denies access to certain array elements, the filtering logic removes denied elements in forward index order, causing index shifts that leave some denied elements visible. This results in partial leakage of denied array elements in query results. The problem does not affect field-level permissions or root/record-owner sessions. The issue is fixed by removing denied elements in reverse index order, preventing index invalidation during filtering. The fix is included in SurrealDB version 3.1.4.
Potential Impact
An attacker with record user privileges can read array elements that should be hidden by element-level SELECT permissions, thereby leaking confidential data. This leakage occurs even with deny-all or per-element predicates. However, the vulnerability does not allow bypassing field-level permissions, does not affect root or record-owner sessions, does not cross namespace or database boundaries, and does not permit data modification, privilege escalation, or denial of service. The impact is limited to confidentiality loss.
Mitigation Recommendations
A patch fixing this vulnerability is available in SurrealDB version 3.1.4. Users should upgrade to this version to resolve the issue. Until patched, avoid relying on element-level (field.*) SELECT permissions to hide data from record users; instead, use field-level permissions which are correctly enforced. Alternatively, restrict record users from selecting tables that use element-level permissions.
SurrealDB: Array element-level (field.*) SELECT permissions leak denied elements to record users (CVE-2026-63740)
Description
SurrealDB versions prior to 3.1.4 contain a vulnerability where array element-level SELECT permissions (field.*) are not correctly enforced for record users. This causes denied array elements to be partially leaked in query results. The issue affects only element-level permissions for record users, not field-level permissions or root/record-owner sessions. The vulnerability impacts confidentiality but does not allow data modification or privilege escalation. A fix is available in SurrealDB 3.1.4.
CVSS v3.1
Score 6.5medium
Affected software
Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
Weaknesses
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
SurrealDB's enforcement of SELECT permissions on array elements (field.*) is flawed for record users. When a SELECT permission denies access to certain array elements, the filtering logic removes denied elements in forward index order, causing index shifts that leave some denied elements visible. This results in partial leakage of denied array elements in query results. The problem does not affect field-level permissions or root/record-owner sessions. The issue is fixed by removing denied elements in reverse index order, preventing index invalidation during filtering. The fix is included in SurrealDB version 3.1.4.
Potential Impact
An attacker with record user privileges can read array elements that should be hidden by element-level SELECT permissions, thereby leaking confidential data. This leakage occurs even with deny-all or per-element predicates. However, the vulnerability does not allow bypassing field-level permissions, does not affect root or record-owner sessions, does not cross namespace or database boundaries, and does not permit data modification, privilege escalation, or denial of service. The impact is limited to confidentiality loss.
Mitigation Recommendations
A patch fixing this vulnerability is available in SurrealDB version 3.1.4. Users should upgrade to this version to resolve the issue. Until patched, avoid relying on element-level (field.*) SELECT permissions to hide data from record users; instead, use field-level permissions which are correctly enforced. Alternatively, restrict record users from selecting tables that use element-level permissions.
Technical Details
- Gcve Source
- db.gcve.eu
- Osv Id
- GHSA-8rw6-p7m8-63jp
- Osv Schema Version
- 1.4.0
- Ecosystems
- ["crates.io"]
- Database Specific Severity
- MODERATE
- Cvss Version
- 3.1
Threat ID: 6a7ff5f6bf8831d539880084
Added to database: 08/15/2026, 05:15:34 UTC
Last enriched: 09/13/2026, 12:54:03 UTC
Last updated: 09/27/2026, 21:40:45 UTC
Views: 37
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.