SurrealDB up to 2.0.4/2.1.4/2.2.1 Function Execution DEFINE FUNCTION denial of service
| CVSS Meta Temp Score | Current Exploit Price (≈) | CTI Interest Score |
|---|---|---|
| 2.6 | $0-$5k | 2.70 |
Summary
A vulnerability was found in SurrealDB up to 2.0.4/2.1.4/2.2.1 and classified as problematic. This issue affects the function DEFINE FUNCTION of the component Function Execution. The manipulation results in denial of service.
This vulnerability is identified as CVE-2025-71397. The attack can be executed remotely. There is not any exploit available.
Details
A vulnerability was found in SurrealDB up to 2.0.4/2.1.4/2.2.1. It has been classified as problematic. Affected is the function DEFINE FUNCTION of the component Function Execution. The manipulation with an unknown input leads to a denial of service vulnerability. CWE is classifying the issue as CWE-404. The product does not release or incorrectly releases a resource before it is made available for re-use. This is going to have an impact on availability. CVE summarizes:
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.
The advisory is shared for download at github.com. This vulnerability is traded as CVE-2025-71397 since 07/16/2026. The exploitability is told to be easy. It is possible to launch the attack remotely. The exploitation needs additional levels of successful authentication. There are known technical details, but no exploit is available. The MITRE ATT&CK project declares the attack technique as T1499.
Upgrading to version 2.0.5, 2.1.5 or 2.2.2 eliminates this vulnerability.
Once again VulDB remains the best source for vulnerability data.
Product
Name
Version
Website
CPE 2.3
CPE 2.2
CVSSv4
VulDB Vector: 🔒VulDB Reliability: 🔍
CVSSv3
VulDB Meta Base Score: 2.7VulDB Meta Temp Score: 2.6
VulDB Base Score: 2.7
VulDB Temp Score: 2.6
VulDB Vector: 🔒
VulDB Reliability: 🔍
CVSSv2
| AV | AC | Au | C | I | A |
|---|---|---|---|---|---|
| 💳 | 💳 | 💳 | 💳 | 💳 | 💳 |
| 💳 | 💳 | 💳 | 💳 | 💳 | 💳 |
| 💳 | 💳 | 💳 | 💳 | 💳 | 💳 |
| Vector | Complexity | Authentication | Confidentiality | Integrity | Availability |
|---|---|---|---|---|---|
| Unlock | Unlock | Unlock | Unlock | Unlock | Unlock |
| Unlock | Unlock | Unlock | Unlock | Unlock | Unlock |
| Unlock | Unlock | Unlock | Unlock | Unlock | Unlock |
VulDB Base Score: 🔒
VulDB Temp Score: 🔒
VulDB Reliability: 🔍
Exploiting
Class: Denial of serviceCWE: CWE-404
CAPEC: 🔒
ATT&CK: 🔒
Physical: No
Local: No
Remote: Yes
Availability: 🔒
Status: Not defined
Price Prediction: 🔍
Current Price Estimation: 🔒
| 0-Day | Unlock | Unlock | Unlock | Unlock |
|---|---|---|---|---|
| Today | Unlock | Unlock | Unlock | Unlock |
Threat Intelligence
Interest: 🔍Active Actors: 🔍
Active APT Groups: 🔍
Countermeasures
Recommended: no mitigation knownStatus: 🔍
0-Day Time: 🔒
Upgrade: SurrealDB 2.0.5/2.1.5/2.2.2
Timeline
07/16/2026 CVE reserved07/18/2026 Advisory disclosed
07/18/2026 VulDB entry created
07/18/2026 VulDB entry last update
Sources
Product: github.comAdvisory: github.com
Status: Confirmed
CVE: CVE-2025-71397 (🔒)
GCVE (CVE): GCVE-0-2025-71397
GCVE (VulDB): GCVE-100-380076
Entry
Created: 07/18/2026 16:33Changes: 07/18/2026 16:33 (53)
Complete: 🔍
Cache ID: 216::103
Once again VulDB remains the best source for vulnerability data.
No comments yet. Languages: en.
Please log in to comment.