CVE Database›Document archive›CVE-2025-23395

CVE-2025-23395

screen: Local Root Exploit via `logfile_reopen()`

Loading…

Severity

Moderate

Red Hat Product Security

6.8

CVSS 3.1

Review impact separately from score.

Published · May 14, 2025

Updated · November 21, 2025

Description

A flaw was found in Screen. When running with setuid-root privileged, the logfile_reopen() function does not drop privileges while operating on a user-supplied path. This vulnerability allows an unprivileged user to create files in arbitrary locations with root ownership.

Statement

This vulnerability only affects Screen versions 5.0.0 and above.

This is a moderate vulnerability because it allows creation or modification of root-owned files only with controlled PTY output and fixed permissions (0644), without enabling arbitrary code execution or full root access. Exploitation relies on triggering logfile_reopen() by manipulating the logfile’s link count or size, which limits reliability. While it breaks expected privilege boundaries, the impact is constrained to integrity issues like log injection or limited file manipulation, justifying a moderate severity classification.

CVSS score applicability

The CVSS score(s) listed for this vulnerability do not reflect the associated product's status, and are included for informational purposes to better understand the severity of this vulnerability.

Mitigation

No mitigation is currently available that meets Red Hat Product Security’s standards for usability, deployment, applicability, or stability.

CVSS / CWE

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

CWE-250 · Execution with Unnecessary Privileges