CVE-2025-71397
SurrealDB before 2.2.2 CPU Exhaustion via nested FOR loops
CVSS Score
0.0
EPSS Score
0.0%
EPSS Percentile
0th
SurrealDB before 2.0.5, 2.1.x before 2.1.5, and 2.2.x before 2.2.2 allows authenticated users with OWNER or EDITOR permissions (at the root, namespace, or database level) to define custom database functions via DEFINE FUNCTION using nested FOR loops. Although a single loop's iteration count is constrained, nesting multiple loops (e.g., each with 1,000,000 iterations) is not, so an attacker can execute a function that consumes all server CPU time. Configured timeouts do not stop the execution, rendering the server unresponsive to other queries and connections until it is manually restarted.
| CWE | CWE-835 |
| Vendor | surrealdb |
| Product | surrealdb |
| Published | Jul 18, 2026 |
Stay Ahead of the Next One
Get instant alerts for surrealdb surrealdb
Be the first to know when new unknown vulnerabilities affecting surrealdb surrealdb are published โ delivered to Slack, Telegram or Discord.
Get Free Alerts โ
Free ยท No credit card ยท 60 sec setup
Affected Versions
surrealdb / surrealdb
0 < 2.2.2
surrealdb / surrealdb
0 < 2.1.5
surrealdb / surrealdb
0 < 2.0.5
References
Credits
๐ cure53