Bug 2558775 (CVE-2026-115207) - CVE-2026-115207 patch: Filename validation bypass in reversal fallback allows file creation outside the working directory
Summary: CVE-2026-115207 patch: Filename validation bypass in reversal fallback allows...
Keywords:
Status: NEW
Alias: CVE-2026-115207
Deadline: 2026-10-22
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Product Security
QA Contact:
URL:
Whiteboard:
Depends On: 2558782
Blocks:
TreeView+ depends on / blocked
 
Reported: 2026-10-22 07:27 UTC by OSIDB Bzimport
Modified: 2026-11-23 11:42 UTC (History)
4 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2026:102252 0 None None None 2026-11-23 10:42:55 UTC
Red Hat Product Errata RHSA-2026:102274 0 None None None 2026-11-23 11:42:28 UTC
Red Hat Product Errata RHSA-2026:96215 0 None None None 2026-11-09 11:03:57 UTC
Red Hat Product Errata RHSA-2026:99161 0 None None None 2026-11-12 02:26:09 UTC

Description OSIDB Bzimport 2026-10-22 07:27:09 UTC
A flaw was found in GNU patch. The reversal fallback in intuit_diff_type() in src/pch.c selects a filename from the patch headers without applying the name_is_valid() check that normally rejects absolute paths. A crafted unified diff that appears to delete a nonexistent file, with an absolute filename in both headers and an epoch timestamp for the new file, can trigger automatic reversal when applied with patch -p0 -t. The unvalidated absolute filename reaches the filesystem operations, allowing attacker-controlled file creation outside the working directory with the permissions of the account running patch. Exploitation requires a user or workflow to apply the crafted patch; it does not bypass operating-system filesystem permissions.

Comment 1 Andreas Gruenbacher 2026-10-23 13:40:05 UTC
Fixed in patch-2.8.1.

Comment 2 errata-xmlrpc 2026-11-09 11:03:56 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 8

Via RHSA-2026:96215 https://access.redhat.com/errata/RHSA-2026:96215

Comment 3 errata-xmlrpc 2026-11-12 02:26:07 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 9.8 Extended Update Support

Via RHSA-2026:99161 https://access.redhat.com/errata/RHSA-2026:99161

Comment 4 errata-xmlrpc 2026-11-23 10:42:54 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 10.2 Extended Update Support

Via RHSA-2026:102252 https://access.redhat.com/errata/RHSA-2026:102252

Comment 5 errata-xmlrpc 2026-11-23 11:42:27 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 10

Via RHSA-2026:102274 https://access.redhat.com/errata/RHSA-2026:102274


Note You need to log in before you can comment on or make changes to this bug.