patch — security advisory
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
- Products
- patch
- Affected versions
- 2.7.6-7, 2.8-1, 2.8-2, 2.8.1-1
- Fixed versions
- Not specified
- CVEs
- CVE-2026-56288
- Confirmed fixed CVEs
- Not specified
- Updated in this feed
- 1 Nov 2026, 13:35 UTC · Revision 2
Source evidence
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
osv:DEBIAN-CVE-2026-56288
patch
Fixed versions: Not specified
patch
Fixed versions: Not specified
patch
Fixed versions: Not specified
Complete source record
{
"id": "4accc86f30b87a62ebb31bdc5a8d0f46fe3880bf710fa64d507bc87822050f8f",
"url": "https://osv.dev/vulnerability/DEBIAN-CVE-2026-56288",
"method": "structured",
"payload": {
"kind": "advisory",
"title": "DEBIAN-CVE-2026-56288",
"summary": "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",
"evidence": "osv:DEBIAN-CVE-2026-56288",
"products": [
{
"name": {
"value": "patch",
"evidence": "/affected/0/package/name"
},
"prerequisites": [],
"fixed_versions": [],
"affected_versions": [
{
"value": "2.7.6-7",
"evidence": "/affected/0/versions"
},
{
"value": "2.8-1",
"evidence": "/affected/0/versions"
},
{
"value": "2.8-2",
"evidence": "/affected/0/versions"
},
{
"value": "2.8.1-1",
"evidence": "/affected/0/versions"
}
]
},
{
"name": {
"value": "patch",
"evidence": "/affected/1/package/name"
},
"prerequisites": [],
"fixed_versions": [],
"affected_versions": [
{
"value": "2.8-2",
"evidence": "/affected/1/versions"
},
{
"value": "2.8.1-1",
"evidence": "/affected/1/versions"
}
]
},
{
"name": {
"value": "patch",
"evidence": "/affected/2/package/name"
},
"prerequisites": [],
"fixed_versions": [],
"affected_versions": [
{
"value": "2.8-2",
"evidence": "/affected/2/versions"
},
{
"value": "2.8.1-1",
"evidence": "/affected/2/versions"
}
]
}
],
"severity": "medium",
"structured": {
"id": "DEBIAN-CVE-2026-56288",
"aliases": [
"DEBIAN-CVE-2026-56288"
],
"metrics": [
{
"type": "CVSS_V3",
"score": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H"
}
],
"affected": [
{
"ranges": [
{
"type": "ECOSYSTEM",
"events": [
{
"introduced": "0"
}
]
}
],
"package": {
"name": "patch",
"purl": "pkg:deb/debian/patch?arch=source&distro=bookworm",
"ecosystem": "Debian:12"
},
"versions": [
"2.7.6-7",
"2.8-1",
"2.8-2",
"2.8.1-1"
],
"database_specific": {
"source": "https://storage.googleapis.com/debian-osv/debian-cve-osv/DEBIAN-CVE-2026-56288.json"
},
"ecosystem_specific": {
"urgency": "unimportant"
}
},
{
"ranges": [
{
"type": "ECOSYSTEM",
"events": [
{
"introduced": "0"
}
]
}
],
"package": {
"name": "patch",
"purl": "pkg:deb/debian/patch?arch=source&distro=trixie",
"ecosystem": "Debian:13"
},
"versions": [
"2.8-2",
"2.8.1-1"
],
"database_specific": {
"source": "https://storage.googleapis.com/debian-osv/debian-cve-osv/DEBIAN-CVE-2026-56288.json"
},
"ecosystem_specific": {
"urgency": "unimportant"
}
},
{
"ranges": [
{
"type": "ECOSYSTEM",
"events": [
{
"introduced": "0"
}
]
}
],
"package": {
"name": "patch",
"purl": "pkg:deb/debian/patch?arch=source&distro=forky",
"ecosystem": "Debian:14"
},
"versions": [
"2.8-2",
"2.8.1-1"
],
"database_specific": {
"source": "https://storage.googleapis.com/debian-osv/debian-cve-osv/DEBIAN-CVE-2026-56288.json"
},
"ecosystem_specific": {
"urgency": "unimportant"
}
}
],
"modified": "2026-10-26T12:02:37.083193129Z",
"provider": "osv",
"upstream": [
"CVE-2026-56288"
],
"references": [
"https://security-tracker.debian.org/tracker/CVE-2026-56288"
]
},
"related_cves": [
{
"value": "CVE-2026-56288",
"evidence": "/upstream"
}
],
"security_relevant": true,
"severity_evidence": "/severity/0/score"
},
"source_id": "core-osv",
"document_id": 452567,
"published_at": "2026-07-09T11:16:40.713+00:00"
}