CVE-2026-145738
Received Received - Intake

Local Privilege Escalation in Composer Patches Plugin

Vulnerability report for CVE-2026-145738, including description, CVSS score, EPSS score, affected products, exploitability, helpful resources, and attack-flow context.

Publication date: 2026-12-06

Last updated on: 2026-12-06

Assigner: MITRE

Description

The cweagans composer-patches (aka Composer Patches) plugin 2.0.0 for Composer allows local users to gain privileges by modifying patches stored in the /tmp/composer-patches or /tmp/patches directory.

CVSS Scores

EPSS Scores

Probability:
Percentile:

Meta Information

Published
2026-12-06
Last Modified
2026-12-06
Generated
2026-12-06
AI Q&A
2026-12-06
EPSS Evaluated
N/A
NVD
EUVD

Affected Vendors & Products

Showing 1 associated CPE
Vendor Product Version / Range
cweagans Composer Patches 2.0.0

Helpful Resources

Exploitability

CWE
CWE Icon
KEV
KEV Icon
CWE ID Description
CWE-379 The product creates a temporary file in a directory whose permissions allow unintended actors to determine the file's existence or otherwise access that file.

Attack-Flow Graph

AI Quick Actions

Instant insights powered by AI
Executive Summary

This vulnerability allows local users with write access to system-wide temporary directories to replace legitimate patch files with malicious versions, enabling privilege escalation within Composer-managed projects.

Detection Guidance

Check if the cweagans/composer-patches plugin version 2.0.0 is installed and verify the temporary directory used by running:

Bash
composer show cweagans/composer-patches --format=json | jq '.version'

Then inspect the temporary directory for patch files:

Bash
ls -la /tmp/composer-patches /tmp/patches 2>/dev/null || echo "No temporary patch directories found"

Verify ownership and permissions of these directories to assess exposure:

Bash
stat -c "%U:%G %a %n" /tmp/composer-patches /tmp/patches 2>/dev/null
Impact Analysis

An attacker with local write access to the temporary directories could replace patch files, leading to arbitrary code execution during Composer patch application in projects run by other users.

Compliance Impact

If patch files are modified to include malicious code, this could result in unauthorised code execution, potentially violating integrity controls in compliance frameworks that require software integrity.

Mitigation Strategies

No verified fix is documented in the provided evidence; monitor the upstream repository for updates or apply the proposed workaround of customising the temporary directory path.

Chat Assistant

Ask questions about this CVE
Hi! I’m here to help you understand CVE-2026-145738. Ask me anything about the vulnerability, its impact, or mitigation strategies.
0/70

EPSS Chart

Security Radar

News mentioning this vulnerability
Loading related security news...