CubePath

CVE-2023-25652

"git apply --reject" partially-controlled arbitrary file write

CVSS 3.1 High 7.5

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N

Description

Git is a revision control system. Prior to versions 2.30.9, 2.31.8, 2.32.7, 2.33.8, 2.34.8, 2.35.8, 2.36.6, 2.37.7, 2.38.5, 2.39.3, and 2.40.1, by feeding specially crafted input to `git apply --reject`, a path outside the working tree can be overwritten with partially controlled contents (corresponding to the rejected hunk(s) from the given patch). A fix is available in versions 2.30.9, 2.31.8, 2.32.7, 2.33.8, 2.34.8, 2.35.8, 2.36.6, 2.37.7, 2.38.5, 2.39.3, and 2.40.1. As a workaround, avoid using `git apply` with `--reject` when applying patches from an untrusted source. Use `git apply --stat` to inspect a patch before applying; avoid applying one that create a conflict where a link corresponding to the `*.rej` file exists.

Official description from the CVE record, published by GitHub_M. Copyright © 1999-2026 The MITRE Corporation. See /security/cve/legal for the CVE license. View the record on cve.org

Key data

CVSS 3.1 High 7.5

Score published by GitHub_M in the CVE record.

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N

  • Attack vector: Network

    The vulnerable component can be reached over a network, possibly from the Internet.

  • Attack complexity: Low

    No special conditions are needed. The attack can be repeated at will.

  • Privileges required: None

    No account or privileges are needed.

  • User interaction: None

    No action from any user is needed.

  • Scope: Unchanged

    The impact stays within the vulnerable component.

  • Confidentiality impact: None

    No effect on the secrecy of data.

  • Integrity impact: High

    Serious or total effect on the trustworthiness of data.

  • Availability impact: None

    No effect on availability.

CVSS is owned and managed by FIRST.Org, Inc. (FIRST) and is used by permission. Each CVSS score on this site is shown together with its vector string, as published in the CVE record by the source named next to it. Learn more at first.org/cvss.

EPSS

Exploit Prediction Scoring System by FIRST: an estimate of the probability that exploitation activity will be observed in the next 30 days.
Score
0.51883 (51.9% probability)
Percentile
99.0%
Scores of
Nov 10, 2026
Model
v2026.06.15

CISA assessment as of Jan 5, 2024

Stakeholder-Specific Vulnerability Categorization (SSVC) decision points added by CISA.
Automatable
yes
Technical impact
partial

Weakness (CWE)

CWE catalog version 5.0.
CWE names: Copyright © 2006-2026, The MITRE Corporation. See /security/cve/legal for the CWE license.
  • CWE-22Improper Limitation of a Pathname to a Restricted Directory

Affected products

Products listed in the CVE record, as the CNA published them.
  • git

    • affected: < 2.30.9
    • affected: >= 2.31.0, < 2.31.8
    • affected: >= 2.32.0, < 2.32.7
    • affected: >= 2.33.0, < 2.33.8
    • affected: >= 2.34.0, < 2.34.8
    • affected: >= 2.35.0, < 2.35.8
    • affected: >= 2.36.0, < 2.36.6
    • affected: >= 2.37.0, < 2.37.7
    • affected: >= 2.38.0, < 2.38.5
    • affected: >= 2.39.0, < 2.39.3
    • affected: >= 2.40.0, < 2.40.1

Timeline

  1. ID reserved
  2. Record published
  3. Record last updated

Look up another CVE

About CubePath

CubePath is a cloud provider with data centers in Europe and the United States. It offers VPS, bare metal servers and DDoS protection.

Data from the CVE Program (MITRE), CISA KEV and FIRST EPSS. CVSS is owned by FIRST and used by permission. Not affiliated with or endorsed by MITRE, CISA or FIRST. Data as of Nov 10, 2026, 19:49 UTC. Sources and licenses