CVE-2026-73505

Oh My Posh: Arbitrary command execution via template injection in the path segment

Published Aug 13, 2026 CVSS 3.1 · 7.8 High EPSS < 1% KEV · Not listed
Description
Oh My Posh is the most customisable and low-latency cross platform/shell prompt renderer. Prior to 29.35.1, the setStyle() function in src/segments/path.go passed pt.Path, which includes raw folder names, to template.Render, whose function map exposes cmd, so an attacker-controlled directory name containing a Go template expression could execute arbitrary operating system commands as the current user whenever the prompt rendered inside that directory or a descendant. This issue is fixed in version 29.35.1.

Remediation

No solution or workaround provided in the CVE record

Tracking

Sign in to view the affected projects.

Advisories

Source ID Title
Github GHSA Github GHSA GHSA-6xj8-qv9j-xcjq Oh My Posh: Arbitrary command execution via template injection in the path segment
History
Type Values Removed Values Added
First Time appeared Jandedobbeleer
Jandedobbeleer oh-my-posh
Vendors & Products Jandedobbeleer
Jandedobbeleer oh-my-posh
Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'poc', 'Technical Impact': 'total'}, 'version': '2.0.3'}

Type Values Removed Values Added
Description Oh My Posh is the most customisable and low-latency cross platform/shell prompt renderer. Prior to 29.35.1, the setStyle() function in src/segments/path.go passed pt.Path, which includes raw folder names, to template.Render, whose function map exposes cmd, so an attacker-controlled directory name containing a Go template expression could execute arbitrary operating system commands as the current user whenever the prompt rendered inside that directory or a descendant. This issue is fixed in version 29.35.1.
Title Oh My Posh: Arbitrary command execution via template injection in the path segment
Weaknesses CWE-1336
CWE-94
References
Metrics cvssV3_1

{'score': 7.8, 'vector': 'CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H'}

Weaknesses

Sources

Status
PUBLISHED
Assigner
GitHub_M
Published
Updated
Aug 13, 2026, 3:18 PM
Reserved
Aug 12, 2026, 7:00 PM
Status
Deferred
Published
Aug 13, 2026, 3:20 PM
Modified
Oct 24, 2026, 3:10 PM
Severity
Important
Public date
Aug 13, 2026, 2:21 PM