Description
sqlite3 provides Ruby bindings for the SQLite3 embedded database. From 2.1.0 to 2.9.4, the callbacks used for SQLite aggregate functions can be freed while still referenced during aggregation, resulting in a use-after-free. This issue is fixed in version 2.9.5.
Affected products
| Vendor | Product | Affected | Fixed |
|---|---|---|---|
| sparklemotion | sqlite3-ruby | >= 2.1.0, < 2.9.5 | — |
Fixed in Linux distributions
Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.
Debian
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian 14 | ruby-sqlite3 | 2.9.5-1 | — |
| Debian 13 | ruby-sqlite3 | No fix yet | — |
| Debian 12 | ruby-sqlite3 | No fix yet | — |
Ubuntu
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu 26.10 | ruby-sqlite3 | No fix yet | — |
| Ubuntu 26.04 LTS | ruby-sqlite3 | No fix yet | — |
| Ubuntu 24.04 LTS | ruby-sqlite3 | No fix yet | — |
| Ubuntu 22.04 LTS | ruby-sqlite3 | No fix yet | — |
| Ubuntu 20.04 LTS | ruby-sqlite3 | No fix yet | — |
Show 2 more (older releases, extended support, other products)Fewer releases
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu 18.04 LTS | ruby-sqlite3 | No fix yet | — |
| Ubuntu 16.04 LTS | ruby-sqlite3 | No fix yet | — |
Affected packages
| Ecosystem | Package | Affected | Fixed | Record |
|---|---|---|---|---|
| RubyGems | sqlite3 | >= 2.1.0, < 2.9.5 | 2.9.5 | GHSA-j7fr-3v8c-3qc3 |
| RubyGems | sqlite3-ruby | >= 2.1.0, < 2.9.5 | 2.9.5 | GHSA-j7fr-3v8c-3qc3 |
References
- https://github.com/sparklemotion/sqlite3-ruby/security/advisories/GHSA-j7fr-3v8c-3qc3
- https://github.com/sparklemotion/sqlite3-ruby/pull/711
- https://github.com/sparklemotion/sqlite3-ruby/commit/b24e1e6076528b7f95f99acf7a81c70d0004c726
- https://github.com/sparklemotion/sqlite3-ruby/releases/tag/v2.9.5