---
id: CVE-2026-35342
aliases:
  - GHSA-2w8r-9xj7-69j5
title: 'mktemp: empty TMPDIR creates temp files in CWD instead of /tmp'
summary: 'mktemp: empty TMPDIR creates temp files in CWD instead of /tmp'
severity: low
cvss: 3.3
cwe:
  - CWE-377
vendor: uu_mktemp
product: uu_mktemp
ecosystem: rust
affected:
  - uu_mktemp < 0.6.0
patched:
  - uu_mktemp 0.6.0
published: '2026-07-06'
updated: '2026-07-06'
source: GHSA
sourceUrl: 'https://github.com/advisories/GHSA-2w8r-9xj7-69j5'
references:
  - url: >-
      https://github.com/uutils/coreutils/security/advisories/GHSA-2w8r-9xj7-69j5
  - url: 'https://nvd.nist.gov/vuln/detail/CVE-2026-35342'
  - url: 'https://github.com/uutils/coreutils/pull/10566'
  - url: >-
      https://github.com/uutils/coreutils/commit/eb25ec328b226d8fbbaa4058bf9187165bf06d51
  - url: 'https://github.com/uutils/coreutils/releases/tag/0.6.0'
  - url: 'https://github.com/advisories/GHSA-2w8r-9xj7-69j5'
tags:
  - ghsa
  - rust
epss: 0.00133
epssPercentile: 0.03183
ingestedAt: '2026-07-06T20:46:12.695Z'
---

## Overview

The mktemp utility in uutils coreutils fails to properly handle an empty TMPDIR environment variable. Unlike GNU mktemp, which falls back to /tmp when TMPDIR is an empty string, the uutils implementation treats the empty string as a valid path. This causes temporary files to be created in the current working directory (CWD) instead of the intended secure temporary directory. If the CWD is more permissive or accessible to other users than /tmp, it may lead to unintended information disclosure or unauthorized access to temporary data.

---
_Zellic finding 3.11. Reported in the Zellic *uutils coreutils Program Security Assessment* (for Canonical, Jan 2026), audited commit `3a07ffc5a9bd4c283e75afa548ba1f1957bad242`._

## Affected packages

- `uu_mktemp < 0.6.0`

## Remediation

Upgrade to a patched release:

- `uu_mktemp 0.6.0`
