{"id":"UBUNTU-CVE-2026-56288","details":"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","modified":"2026-08-26T07:00:15.639245773Z","published":"2026-07-09T11:16:00Z","upstream":["CVE-2026-56288"],"references":[{"type":"REPORT","url":"https://ubuntu.com/security/CVE-2026-56288"},{"type":"REPORT","url":"https://www.cve.org/CVERecord?id=CVE-2026-56288"},{"type":"REPORT","url":"https://cert.pl/en/posts/2026/07/CVE-2026-56288"}],"affected":[{"package":{"name":"patch","ecosystem":"Ubuntu:Pro:14.04:LTS","purl":"pkg:deb/ubuntu/patch?arch=source&distro=esm-infra-legacy%2Ftrusty"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["2.7.1-3","2.7.1-4","2.7.1-4ubuntu1","2.7.1-4ubuntu2","2.7.1-4ubuntu2.3","2.7.1-4ubuntu2.4","2.7.1-4ubuntu2.4+esm1"],"ecosystem_specific":{"binaries":[{"binary_name":"patch","binary_version":"2.7.1-4ubuntu2.4+esm1"}],"priority_reason":"Only a crash in a command line tool"},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-56288.json"}},{"package":{"name":"patch","ecosystem":"Ubuntu:16.04:LTS","purl":"pkg:deb/ubuntu/patch?arch=source&distro=xenial"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["2.7.5-1","2.7.5-1ubuntu0.16.04.1","2.7.5-1ubuntu0.16.04.2"],"ecosystem_specific":{"binaries":[{"binary_name":"patch","binary_version":"2.7.5-1ubuntu0.16.04.2"}],"priority_reason":"Only a crash in a command line tool"},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-56288.json"}},{"package":{"name":"patch","ecosystem":"Ubuntu:18.04:LTS","purl":"pkg:deb/ubuntu/patch?arch=source&distro=bionic"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["2.7.5-1build1","2.7.6-1","2.7.6-2ubuntu1","2.7.6-2ubuntu1.1"],"ecosystem_specific":{"priority_reason":"Only a crash in a command line tool","binaries":[{"binary_version":"2.7.6-2ubuntu1.1","binary_name":"patch"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-56288.json"}},{"package":{"name":"patch","ecosystem":"Ubuntu:20.04:LTS","purl":"pkg:deb/ubuntu/patch?arch=source&distro=focal"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["2.7.6-6"],"ecosystem_specific":{"binaries":[{"binary_name":"patch","binary_version":"2.7.6-6"}],"priority_reason":"Only a crash in a command line tool"},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-56288.json"}},{"package":{"name":"patch","ecosystem":"Ubuntu:22.04:LTS","purl":"pkg:deb/ubuntu/patch?arch=source&distro=jammy"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["2.7.6-7","2.7.6-7build1","2.7.6-7build2"],"ecosystem_specific":{"binaries":[{"binary_name":"patch","binary_version":"2.7.6-7build2"}],"priority_reason":"Only a crash in a command line tool"},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-56288.json"}},{"package":{"name":"patch","ecosystem":"Ubuntu:24.04:LTS","purl":"pkg:deb/ubuntu/patch?arch=source&distro=noble"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["2.7.6-7build2","2.7.6-7build3"],"ecosystem_specific":{"binaries":[{"binary_name":"patch","binary_version":"2.7.6-7build3"}],"priority_reason":"Only a crash in a command line tool"},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-56288.json"}},{"package":{"name":"patch","ecosystem":"Ubuntu:25.10","purl":"pkg:deb/ubuntu/patch?arch=source&distro=questing"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["2.7.6-7build3","2.8-1","2.8-2"],"ecosystem_specific":{"priority_reason":"Only a crash in a command line tool","binaries":[{"binary_name":"patch","binary_version":"2.8-2"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-56288.json"}},{"package":{"name":"patch","ecosystem":"Ubuntu:26.04:LTS","purl":"pkg:deb/ubuntu/patch?arch=source&distro=resolute"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["2.8-2","2.8-2build1"],"ecosystem_specific":{"priority_reason":"Only a crash in a command line tool","binaries":[{"binary_name":"patch","binary_version":"2.8-2build1"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-56288.json"}}],"schema_version":"1.9.0","severity":[{"type":"CVSS_V4","score":"CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:A/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N"},{"type":"CVSS_V3","score":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H"},{"type":"Ubuntu","score":"low"}]}