Gnu Patch vulnerabilities
17 known vulnerabilities affecting gnu/patch.
Total CVEs
17
CISA KEV
0
Public exploits
0
Exploited in wild
0
Severity breakdown
HIGH8MEDIUM9
Vulnerabilities
Page 1 of 1
CVE-2015-1395P3HIGHCVSS 7.5≤ 2.7.22017-08-25
CVE-2015-1395 [HIGH] CWE-22 CVE-2015-1395: Directory traversal vulnerability in GNU patch versions which support Git-style patching before 2.7.
Directory traversal vulnerability in GNU patch versions which support Git-style patching before 2.7.3 allows remote attackers to write to arbitrary files with the permissions of the target user via a .. (dot dot) in a diff file name.
nvdosv
CVE-2015-1416P3HIGHCVSS 7.8≥ 0, < 2.5-12018-02-05
CVE-2015-1416 [HIGH] CVE-2015-1416: Larry Wall's patch; patch in FreeBSD 10
Larry Wall's patch; patch in FreeBSD 10.2-RC1 before 10.2-RC1-p1, 10.2 before 10.2-BETA2-p2, and 10.1 before 10.1-RELEASE-p16; Bitrig; GNU patch before 2.2.5; and possibly other patch variants allow remote attackers to execute arbitrary shell commands via a crafted patch file.
osv
CVE-2015-1396P3HIGHCVSS 7.5fixed in 2.7.42019-11-25
CVE-2015-1396 [HIGH] CVE-2015-1396: A Directory Traversal vulnerability exists in the GNU patch before 2.7.4. A remote attacker can writ
A Directory Traversal vulnerability exists in the GNU patch before 2.7.4. A remote attacker can write to arbitrary files via a symlink attack in a patch file. NOTE: this issue exists because of an incomplete fix for CVE-2015-1196.
nvdosv
CVE-2018-1000156P3HIGHCVSS 7.8v2.7.62018-04-06
CVE-2018-1000156 [HIGH] CWE-20 CVE-2018-1000156: GNU Patch version 2.7.6 contains an input validation vulnerability when processing patch files, spec
GNU 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 anc
nvdosv
CVE-2019-13638P3HIGHCVSS 7.8v2.7.62019-07-26
CVE-2019-13638 [HIGH] CVE-2019-13638: GNU patch through 2.7.6 is vulnerable to OS shell command injection that can be exploited by opening
GNU patch through 2.7.6 is vulnerable to OS shell command injection that can be exploited by opening a crafted patch file that contains an ed style diff payload with shell metacharacters. The ed editor does not need to be present on the vulnerable system. This is different from CVE-2018-1000156.
nvdosv
CVE-2018-6952P3HIGHCVSS 7.5≤ 2.7.62018-02-13
CVE-2018-6952 [HIGH] CWE-415 CVE-2018-6952: A double free exists in the another_hunk function in pch.c in GNU patch through 2.7.6.
A double free exists in the another_hunk function in pch.c in GNU patch through 2.7.6.
nvd
CVE-2018-6951P3HIGHCVSS 7.5≤ 2.7.62018-02-13
CVE-2018-6951 [HIGH] CWE-476 CVE-2018-6951: An issue was discovered in GNU patch through 2.7.6. There is a segmentation fault, associated with a
An issue was discovered in GNU patch through 2.7.6. There is a segmentation fault, associated with a NULL pointer dereference, leading to a denial of service in the intuit_diff_type function in pch.c, aka a "mangled rename" issue.
nvd
CVE-2015-1196P3MEDIUMCVSS 4.3v2.7.12015-01-21
CVE-2015-1196 [MEDIUM] CWE-59 CVE-2015-1196: GNU patch 2.7.1 allows remote attackers to write to arbitrary files via a symlink attack in a patch
GNU patch 2.7.1 allows remote attackers to write to arbitrary files via a symlink attack in a patch file.
nvdosv
CVE-2018-20969P3HIGHCVSS 7.8≤ 2.7.62019-08-16
CVE-2018-20969 [HIGH] CWE-78 CVE-2018-20969: do_ed_script in pch.c in GNU patch through 2.7.6 does not block strings beginning with a ! character
do_ed_script in pch.c in GNU patch through 2.7.6 does not block strings beginning with a ! character. NOTE: this is the same commit as for CVE-2019-13638, but the ! syntax is specific to ed, and is unrelated to a shell metacharacter.
nvdosv
CVE-2019-13636P4MEDIUMCVSS 5.9≤ 2.7.62019-07-17
CVE-2019-13636 [MEDIUM] CWE-59 CVE-2019-13636: In GNU patch through 2.7.6, the following of symlinks is mishandled in certain cases other than inpu
In GNU patch through 2.7.6, the following of symlinks is mishandled in certain cases other than input files. This affects inp.c and util.c.
nvdosv
CVE-2010-4651P4MEDIUMCVSS 5.8≥ 0, < 2.7.1-4ubuntu2.32015-06-22
CVE-2010-4651 [MEDIUM] patch vulnerabilities
patch vulnerabilities
Jakub Wilk discovered that GNU patch did not correctly handle file paths in
patch files. An attacker could specially craft a patch file that could
overwrite arbitrary files with the privileges of the user invoking the program.
This issue only affected Ubuntu 12.04 LTS. (CVE-2010-4651)
László Böszörményi discovered that GNU patch did not correctly handle some
patch files. An attacker could specially craft a patch file that could
osv
CVE-2016-10713P4MEDIUMCVSS 5.5fixed in 2.7.62018-02-13
CVE-2016-10713 [MEDIUM] CWE-119 CVE-2016-10713: An issue was discovered in GNU patch before 2.7.6. Out-of-bounds access within pch_write_line() in p
An issue was discovered in GNU patch before 2.7.6. Out-of-bounds access within pch_write_line() in pch.c can possibly lead to DoS via a crafted input file.
nvdosv
CVE-2026-56289P4MEDIUMCVSS 5.5≤ 2.8.02026-07-09
CVE-2026-56289 [MEDIUM] CWE-835 CVE-2026-56289: GNU patch is vulnerable to a denial of service (DoS) due to improper validation of hunk (single bloc
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.
nvd
CVE-2014-9637P4MEDIUMCVSS 5.5≤ 2.7.22017-08-25
CVE-2014-9637 [MEDIUM] CWE-399 CVE-2014-9637: GNU patch 2.7.2 and earlier allows remote attackers to cause a denial of service (memory consumption
GNU patch 2.7.2 and earlier allows remote attackers to cause a denial of service (memory consumption and segmentation fault) via a crafted diff file.
nvdosv
CVE-2026-56288P4MEDIUMCVSS 5.5≤ 2.8.02026-07-09
CVE-2026-56288 [MEDIUM] CWE-476 CVE-2026-56288: GNU patch is vulnerable to a NULL pointer dereference when processing a specially crafted unified-di
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 ca
nvd
CVE-2019-20633P4MEDIUMCVSS 5.5≤ 2.7.62020-03-25
CVE-2019-20633 [MEDIUM] CVE-2019-20633: GNU patch through 2.7.6 contains a free(p_line[p_end]) Double Free vulnerability in the function ano
GNU patch through 2.7.6 contains a free(p_line[p_end]) Double Free vulnerability in the function another_hunk in pch.c that can cause a denial of service via a crafted patch file. NOTE: this issue exists because of an incomplete fix for CVE-2018-6952.
nvdosv
CVE-2021-45261P4MEDIUMCVSS 5.5v2.72021-12-22
CVE-2021-45261 [MEDIUM] CWE-763 CVE-2021-45261: An Invalid Pointer vulnerability exists in GNU patch 2.7 via the another_hunk function, which causes
An Invalid Pointer vulnerability exists in GNU patch 2.7 via the another_hunk function, which causes a Denial of Service.
nvd