SQLite before 3.54.0 contains a stack exhaustion vulnerability in countOfViewOptimization() that allows attackers to crash the host process via count(*) over a large multi-row VALUES clause. Attackers supplying SQL or a database file with a crafted view can trigger deeply nested TK_PLUS expressions whose recursive freeing in sqlite3ExprDeleteNN() exhausts the C stack, causing denial of service.
The product does not properly control the amount of recursion that takes place, consuming excessive resources, such as allocated memory or the program stack.
| Name | Vendor | Start Version | End Version |
|---|---|---|---|
| Sqlite | Sqlite | * | 3.54.0 (excluding) |
| Red Hat Enterprise Linux 10 | RedHat | sqlite-0:3.46.1-7.el10_3 | * |
| Red Hat Enterprise Linux 9 | RedHat | sqlite-0:3.34.1-12.el9_9 | * |
| Red Hat Enterprise Linux 9 | RedHat | sqlite-0:3.34.1-12.el9_9 | * |
| Red Hat Hardened Images | RedHat | sqlite-main-3.54.1-1.hum1 | * |
| Sqlite | Ubuntu | upstream | * |
| Sqlite3 | Ubuntu | noble | * |
| Sqlite3 | Ubuntu | resolute | * |
| Sqlite3 | Ubuntu | upstream | * |