Memory Corruption Vulnerability in bsdiff Package: CVE-2020-14315

bsdiff Updated 02 Oct 2025

Summary

16/09/2020
N/A
Yes i
Critical
9.8

CVE-2020-14315: A memory corruption vulnerability is present in bspatch as shipped in Colin Percival’s bsdiff tools version 4.3. Affects bsdiff across 2 version ranges.

< 4.3-22 < ce07a29894acd74c52b975a42c02f11d9483566a

Fixed in 4.3-22. 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 Mobile apps built by Devnack Design, build and launch iOS and Android apps with a senior product team. From idea to store release Start a project

Background

bsdiff is a tool for creating and applying binary patches, widely used in software distribution to reduce the size of updates. It is part of Colin Percival's bsdiff tools, which are known for their efficiency in handling binary differences. However, the bsdiff package has been found to have a critical memory corruption vulnerability that can be exploited if not addressed.

Vulnerability Detail

CVE-2020-14315 is a memory corruption vulnerability found in the bsdiff tool, specifically in the bspatch function. The vulnerability arises from insufficient checks when handling external inputs, allowing an attacker to bypass sanity checks and write outside the boundaries of a dynamically allocated buffer. This can lead to arbitrary code execution, data corruption, or crashes, posing significant risks to systems using affected versions of the package.

How To Fix

Minimum fixed version

4.3-22

This is the first release that contains the fix.

sudo apt-get install --only-upgrade bsdiff

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

Workaround

As a temporary workaround, users can avoid using the bsdiff tool for patching until they have upgraded to a secure version. Additionally, validating inputs before processing them can help mitigate the risk of exploitation.

Conclusion

CVE-2020-14315 represents a significant security risk for users of the bsdiff tool due to its memory corruption vulnerability. It is crucial for users to upgrade to the patched version to mitigate potential threats. Utilizing tools like Vulert can help monitor and alert for such vulnerabilities in real-time.

See every vulnerability recorded for bsdiff →

Share this vulnerability

FAQ

CVE-2020-14315 is a memory corruption vulnerability in the bsdiff tool that allows attackers to exploit insufficient input checks.

You can use the Vulert playground at Vulert Scanner to check if your application is affected by this vulnerability without needing to sign up.

Exploitation of this vulnerability can lead to arbitrary code execution, data corruption, or system crashes, posing serious security risks.

If an immediate upgrade is not possible, refrain from using the bsdiff tool and validate all inputs to reduce the risk of exploitation.

The CVSS score for CVE-2020-14315 is 9.8, indicating a critical level of severity.

Related vulnerabilities

Recent vulnerabilities recorded for bsdiff.

How To Fix

Minimum fixed version

4.3-22

This is the first release that contains the fix.

sudo apt-get install --only-upgrade bsdiff

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