SQLite Integer Overflow Vulnerability in FTS5 Extension Allowing Out-of-Bounds Write

Vulnerability

A moderate integer overflow vulnerability has been identified in the SQLite FTS5 extension, specifically in version 3.49.1. The issue arises when the size of an array of tombstone pointers is calculated and improperly truncated to a 32-bit integer. This flaw allows a pointer to partially controlled data to be written out of bounds, potentially leading to memory corruption.

Impact

Exploitation of this vulnerability causes a heap-based buffer overflow, allowing for out-of-bounds memory writes that could be exploited to overwrite adjacent memory and potentially execute arbitrary code.

Reproduction

The vulnerability can be reproduced by executing a crafted SQL query that manipulates the 'nPgTombstone' value, which is under attacker control. This can be done using the SQLite command-line tool. The AddressSanitizer will report a heap-buffer-overflow error, indicating that the vulnerability has been successfully exploited.

Remediation

Users should upgrade to SQLite version 3.50 or later, where this vulnerability has been patched.

Added: Sep 8, 2025, 3:17 PM
Updated: Sep 8, 2025, 4:29 PM

Vulnerability Rating

Custom Algorithm
spread
9.0
impact
0.6
exploitability
4.6
remediation
7.7
relevance
0.5
threat
6.4
urgency
2.9
incentive
1.7

Our algorithm analyzes dozens of metrics to generate these 8 key vulnerability categories, which are then combined to calculate the overall risk score.