Creation of Temporary File in Directory with Insecure Permissions Affecting @mariozechner/pi-coding-agent package, versions >=0.50.0


Severity

Recommended
0.0
high
0
10

CVSS assessment by Snyk's Security Team. Learn more

Threat Intelligence

Social Trends
EPSS
0.12% (2nd percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications

Snyk Learn

Learn about Creation of Temporary File in Directory with Insecure Permissions vulnerabilities in an interactive lesson.

Start learning
  • Snyk IDSNYK-JS-MARIOZECHNERPICODINGAGENT-17817907
  • published5 Jul 2026
  • disclosed17 Jun 2026
  • creditUnknown

Introduced: 17 Jun 2026

NewCVE-2026-54328  (opens in a new tab)
CWE-379  (opens in a new tab)

How to fix?

A fix was pushed into the master branch but not yet published.

Overview

@mariozechner/pi-coding-agent is a Coding agent CLI with read, bash, edit, write tools and session management

Affected versions of this package are vulnerable to Creation of Temporary File in Directory with Insecure Permissions in the process handling temporary extension package installs via npm or git sources, which used predictable paths under the operating system's temporary directory. An attacker can execute arbitrary code as another user by pre-creating a malicious extension package at the expected location before the victim runs the process with a temporary extension package source. This is only exploitable if the system is a shared Linux host with a world-writable temporary directory and a victim user runs the process with a temporary npm or git extension package source that maps to the attacker-prepared location.

Workaround

This vulnerability can be mitigated by avoiding the use of --extension or -e with npm or git package sources on shared Linux systems, and by configuring the process temporary directory environment to point to a directory owned by the invoking user with 0700 permissions before starting the process.

CVSS Base Scores

version 4.0
version 3.1