Skip to main content
No exploitation reportedFix available

CVE-2025-71397

No exploitation reported by the sources we read.

  • Published2026-07-18
  • Fixed in2.2.2 · 2.1.5 · 2.0.5
  • WeaknessCWE-835

Am I affected?

With a domain, we read the version its public headers and pages expose. A distribution build can carry the fix under an older number.

Description

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.

Timeline

dates in UTC
  1. 2026-07-1814:17CVE publishedNVD

Observed activity

isMalicious corpus · updated 2026-11-03 15:37 UTC
Indicators tagged with this CVE, per day0 indicators over 7 days
Block these indicators
  • Firewall list (EDL, text): https://api.ismalicious.com/edl/cve/CVE-2025-71397?format=txt
  • CSV export: https://api.ismalicious.com/edl/cve/CVE-2025-71397?format=csv
  • TAXII collection of exploited CVEs
  • The EDL and CSV take an API key on the Pro plan.

Versions per branch

NVD · OSV
Surrealdb
BranchAffectedFixed in
2.2≥ 2.2.0, < 2.2.22.2.2
2.1≥ 2.1.0, < 2.1.52.1.5
2.0< 2.0.52.0.5

as publishedRanges as NVD and OSV publish them; a distribution’s build can be fixed under an older number.

Products declared by the CNA3 products

As VulnCheck, the CNA that assigned this CVE, declared them in the CVE record; versions as written.

  • surrealdbother versions: not affected
    Affected
    • ≥ 2.2.0, < 2.2.2fixed in 2.2.2semver

    Not affected = 2.2.2

  • surrealdbother versions: not affected
    Affected
    • ≥ 2.1.0, < 2.1.5fixed in 2.1.5semver

    Not affected = 2.1.5

  • surrealdbother versions: not affected
    Affected
    • < 2.0.5fixed in 2.0.5semver

    Not affected = 2.0.5

Source: the CNA record (CVE Program), © The MITRE Corporation,CVE Terms of UseCVE recordupdated 2026-10-29

Fix

  1. Update Surrealdb to 2.2.2 · 2.1.5 · 2.0.5

Advisories and patches

Detection

Nuclei template
none so far
ProjectDiscovery
Exploit-DB
no entry
Exploit-DB
Proof-of-concept repositories
none listed
PoC-in-GitHub
Metasploit modules
none listed
Metasploit Framework

Sources

  • CISA-ADPSSVC decisionnone2026-07-20
  • OpenCVESSVC decisionnone—
  • CNACVSS 4.07.1known since 2026-10-30
  • NVDCVSS 3.16.5read 2026-10-30
  • CNAweakness (CWE)CWE-835known since 2026-10-30
  • FIRST EPSSEPSS score0.6 %2026-11-03
  • OSVaffected packages—
  • GitHub AdvisoriesadvisoryHIGH2025-04-11

Identifiers

Technical details

CVSS v3 Vector
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H
CVSS 4.0 vector
CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X
Published
2026-07-18
Last Modified
2026-10-29
NVD status
Analyzed

Frequently asked questions

What is CVE-2025-71397?

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.

Is CVE-2025-71397 actively exploited?

Active exploitation of CVE-2025-71397 has not been confirmed. Its EPSS score was 0.6% on 2026-11-03, the estimated probability of exploitation in the next 30 days.

What is the CVSS score for CVE-2025-71397?

CVE-2025-71397 has a CVSS v3 base score of 6.5 (MEDIUM severity), with vector string CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H.

Running surrealdb? Hear about its next vulnerability

Surveillance reads the versions in your stack — a domain, a lockfile or a list — checks each CVE against the ranges its sources publish, and alerts you when one you run is exploited or enters CISA KEV. A version it cannot read stays « version not verified ».

No credit card required · No monthly cap on website lookups · 250 API requests/month

Sources for this record