cbcvebase.
CVE-2025-6965
published 2025-07-15

CVE-2025-6965: There exists a vulnerability in SQLite versions before 3.50.2 where the number of aggregate terms could exceed the number of columns available. This could lead…

PriorityP270high7.7CVSS 3.1
AVNACHPRLUINSCCLIHAL
EXPLOIT
EPSS
73.50%
99.4th percentile
There exists a vulnerability in SQLite versions before 3.50.2 where the number of aggregate terms could exceed the number of columns available. This could lead to a memory corruption issue. We recommend upgrading to version 3.50.2 or above.

Affected

43 ranges· showing 25
VendorProductVersion rangeFixed in
appleios_18.6_and_ipados
appleios_26_and_ipados
appleipados< 26.0.026.0.0
appleiphone_os< 26.0.026.0.0
applemacos< 26.0.026.0.0
applemacos_sequoia
applemacos_tahoe
appletvos< 26.0.026.0.0
appletvos
appletvos
applevisionos< 26.0.026.0.0
applevisionos
applevisionos
applewatchos< 26.0.026.0.0
applewatchos
applewatchos
debiansqlite3< sqlite3 3.40.1-2+deb12u2 (bookworm)sqlite3 3.40.1-2+deb12u2 (bookworm)
ghostsqlite3>= 0 < 3.40.1-2+deb12u23.40.1-2+deb12u2
ghostsqlite3>= 0 < 3.46.1-73.46.1-7
ghostsqlite3>= 0 < 3.46.1-73.46.1-7
ghostsqlite3>= 0 < 3.8.2-1ubuntu2.2+esm53.8.2-1ubuntu2.2+esm5
ghostsqlite3>= 0 < 3.11.0-1ubuntu1.5+esm33.11.0-1ubuntu1.5+esm3
ghostsqlite3>= 0 < 3.22.0-1ubuntu0.7+esm23.22.0-1ubuntu0.7+esm2
ghostsqlite3>= 0 < 3.31.1-4ubuntu0.7+esm13.31.1-4ubuntu0.7+esm1
msrcazl3_sqlite_3.44.0-2

Detection & IOCsextracted from sources · hover to see the quote

versionSQLite < 3.50.2
commandSELECT COUNT(*) AS c{i}, SUM(val) AS s{i}, AVG(val) AS a{i}, ... FROM ad_cache (300+ aggregates vs 1 column)
  • Detect SQLite queries with an abnormally large number of aggregate terms (COUNT, SUM, AVG, etc.) exceeding the number of columns in the target table — the PoC uses 300+ aggregate expressions against a single-column table to trigger the heap overflow.
  • Monitor Windows Event Viewer Application Log for winsqlite3.dll Access Violation (exception code 0xC0000005), which indicates successful heap corruption trigger.
  • Monitor for unexpected stop/start of Active Directory-related Windows services (e.g., via 'net stop' / 'net start') combined with SQLite database file writes to AD cache directories, which may indicate exploitation attempts.
  • The vulnerability is triggered when the number of aggregate terms exceeds the number of available columns, causing memory corruption. Flag SQL statements where aggregate function count greatly exceeds the column count of the queried table.
  • ·The PoC targets winsqlite3.dll on Windows Server in an Active Directory context, but the underlying SQLite vulnerability is cross-platform and affects any application embedding SQLite < 3.50.2, including Oracle MySQL Docker Images, Apple tvOS/watchOS/visionOS, and Ubuntu Linux packages.
  • ·Oracle rates this CVE as CVSS 9.8 with remote exploitability via the MySQL Protocol in Docker Images shipping SQLite, broadening the attack surface beyond local/Windows-only scenarios.
  • ·Ubuntu USN-7679-1 confirms the impact ranges from denial of service (crash) to possible arbitrary code execution, and a standard system update (upgrading the SQLite package) is the remediation path on Linux.

CVSS provenance

nvdv3.17.7HIGHCVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:C/C:L/I:H/A:L
nvdv4.07.2HIGHCVSS:4.0/AV:N/AC:H/AT:P/PR:L/UI:N/VC:L/VI:H/VA:L/SC:L/SI:H/SA:L/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:N/AU:N/R:U/V:D/RE:L/U:Green
osv7.2HIGH
vendor_msrc9.8CRITICAL
vendor_oracle9.8HIGH
vendor_debian7.2HIGH
vendor_redhat7.2HIGH
vendor_ubuntu5.6MEDIUM
CVEs like this are exactly what “Exploited This Week” covers.

Every Monday: what got weaponized or added to CISA KEV in the last seven days — each CVE cross-linked to its PoC, Nuclei template, and detection rule. Free, one email a week, unsubscribe in one click.