Critical Heap-based Buffer Overflow in SQLite SQLite3 (CVE-2023-7104)

sqlite Updated 02 Oct 2025

Summary

29/12/2023
N/A
Yes i
High
7.3

CVE-2023-7104: A vulnerability was found in SQLite SQLite3 up to 3.43.0 and classified as critical. Affects sqlite across 2 version ranges.

< 3.40.1-r1 < 995f96f8e11036c909b1dec14049999bc23421c6

Fixed in 3.40.1-r1. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Devnack Your last release was probably never penetration tested Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

SQLite is a popular open-source relational database management system that is widely used in various applications. It provides a lightweight and self-contained database engine, making it a preferred choice for embedded systems and mobile applications. However, a critical vulnerability has been discovered in SQLite SQLite3 up to version 3.43.0. This vulnerability, identified as CVE-2023-7104, affects the 'sessionReadRecord' function in the 'ext/session/sqlite3session.c' file of the 'make alltest Handler' component.

Vulnerability Detail

The vulnerability in SQLite SQLite3 (CVE-2023-7104) is a heap-based buffer overflow. An attacker can manipulate the 'sessionReadRecord' function to cause a buffer overflow, potentially leading to arbitrary code execution or a denial of service attack. This vulnerability has been classified as critical, with a CVSS score of 7.3. It is crucial to apply the recommended patch to mitigate the risk.

How To Fix

Minimum fixed version

3.40.1-r1

This is the first release that contains the fix.

sudo apk add --upgrade sqlite

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

Currently, there is no known workaround for this vulnerability. It is essential to apply the patch as soon as possible to protect your system from potential exploitation.

Conclusion

In conclusion, the critical heap-based buffer overflow vulnerability (CVE-2023-7104) in SQLite SQLite3 poses a significant risk to systems using the affected versions. It is crucial to apply the provided patch or upgrade to a fixed version to protect against potential exploitation. For further support and assistance in vulnerability remediation, please contact DevNack.com.

See every vulnerability recorded for sqlite →

Share this vulnerability

FAQ

SQLite is an open-source relational database management system known for its lightweight and self-contained nature. It is widely used in various applications, including embedded systems and mobile applications.

A heap-based buffer overflow is a type of vulnerability where an attacker can manipulate data in the heap memory, causing a buffer to overflow. This can lead to arbitrary code execution or denial of service attacks.

The vulnerability in SQLite SQLite3 (CVE-2023-7104) can potentially allow an attacker to execute arbitrary code or launch a denial of service attack. It is crucial to apply the patch to mitigate the risk.

To fix this vulnerability, you should apply the patch provided by the SQLite project. Upgrading to version 3.41.2-r3 or later will include the necessary fix.

Currently, there is no known workaround for this vulnerability. It is recommended to apply the patch as soon as possible.

Related vulnerabilities

Recent vulnerabilities recorded for sqlite.

How To Fix

Minimum fixed version

3.40.1-r1

This is the first release that contains the fix.

sudo apk add --upgrade sqlite

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback