Logo
componentpatch
Name
patch
Version
2.8
Type
library
Description
Tool for applying a patch file
Licenses
GPL-3.0-only
PURL
-
CPE
cpe:2.3:*:gnu:patch:2.8:*:*:*:*:*:*:*

Other Versions#


Project
Branch
Version
kirkstone
2.7.6
scarthgap
2.7.6

Patches#


#
Title
Author
Resolve
1
=?UTF-8?q?Don=E2=80=99t=20infloop=20on=20null=20ranges?=
Paul Eggert <eggert@cs.ucla.edu>
CVE-2026-56289
2
Avoid null pointer derefence with bad hunks
Paul Eggert <eggert@cs.ucla.edu>
CVE-2026-56288

Vulnerabilities#


Name
Analysis
Description
Patched
GNU patch is vulnerable to a denial of service (DoS) due to improper validation of hunk (single block of changes in diff) line offsets in unified-diff input. A specially crafted patch can specify an extremely large line number, causing the application to enter an effectively infinite processing loop while attempting to locate the requested position. This results in excessive CPU consumption and prevents the process from completing. An attacker can trigger this behavior by supplying a malicious patch file, causing the utility to become unresponsive and require manual termination. This issue has been fixed in the commit faba04ef4f2b410257f76c1b9dc85e350929c4b9
Patched
GNU patch is vulnerable to a NULL pointer dereference when processing a specially crafted unified-diff patch file. Improper handling of consecutive end-of-file newline markers can corrupt internal hunk (single block of changes in diff) data structures, causing the application to pass a NULL pointer to fwrite() during patch processing. An attacker can trigger this condition with a malicious patch file, causing the utility to crash and resulting in a denial of service. This issue has been fixed in the commit e6d6a4e021660679d7fc9150f981d4920f722313