DescriptionGNU Patch version 2.7.6 contains an input validation vulnerability when processing patch files, specifically the EDITOR_PROGRAM invocation (using ed) can result in code execution. This attack appear to be exploitable via a patch file processed via the patch utility. This is similar to FreeBSD's CVE-2015-1418 however although they share a common ancestry the code bases have diverged over time.
SourceCVE (at NVD; CERT, LWN, oss-sec, fulldisc, bugtraq, EDB, Metasploit, Red Hat, Ubuntu, Gentoo, SUSE bugzilla/CVE, Mageia, GitHub code/issues, web search, more)
Debian Bugs894993

Vulnerable and fixed packages

The table below lists information on source packages.

Source PackageReleaseVersionStatus
patch (PTS)wheezy2.6.1-3vulnerable
wheezy (security)2.6.1-3+deb7u1fixed
jessie, stretch2.7.5-1vulnerable
buster, sid2.7.6-2fixed

The information below is based on the following data on fixed versions.

PackageTypeReleaseFixed VersionUrgencyOriginDebian Bugs


[stretch] - patch <no-dsa> (Can be fixed via point release)
[jessie] - patch <no-dsa> (Can be fixed via point release)
Upstream bug:
This CVE is specifically for GNU patch and relates to CVE-2015-1418
Respective patch in FreeBSD:
Respective patch in OpenBSD:
wheezy patch adds a testcase

Search for package or bug name: Reporting problems