Skip to main content

Linux opendir() CVE-2026-52078

MEDIUM
2026-08-13 vendor:ubuntu
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Supply crafted MAX_PATH-length directory path
  2. Delivery
    Pass path to opendir()-invoking application
  3. Exploit
    wcscat() concatenation overflows stack buffer
  4. Execution
    Stack memory corrupted beyond buffer boundary
  5. Impact
    Crash (DoS) or control-flow hijack

Vulnerability Assessment

Exploitation Conditions

Exploitation requires the ability to cause opendir() to be called with a wide-character path at or exceeding the MAX_PATH boundary - specifically, the path must be long enough that wcscat() concatenation overflows the destination stack buffer. If opendir() is invoked only on trusted, internally-generated paths, the attack surface is minimal. The condition is triggered by path length alone, not a protocol feature or non-default configuration flag; however, the attacker must control or influence the path argument passed to opendir(). Whether this is reachable remotely depends entirely on the calling application's design. Local privilege level required is not confirmed from available data, as the CVSS vector is absent. Stack canaries and ASLR limit but may not fully prevent exploitation depending on implementation.

Impact

Available risk signals are sparse: no CVSS vector, no EPSS score, no KEV listing, and no POC confirmation are present in the input data. The vulnerability class - stack buffer overflow via unbounded wcscat - is inherently serious, as stack overflows in path-handling code can be reachable from unprivileged local users or, if opendir() is invoked server-side on attacker-controlled input, remotely. Without a CVSS vector, attack complexity and required privileges cannot be formally assessed; the description does not clarify whether exploitation requires local access, a mounted filesystem, or remote path injection. The Ubuntu vendor attribution suggests this was discovered through internal auditing or fuzzing rather than active exploitation reports. No public exploit code has been identified at time of analysis. Given the uncertainty in scope and reach, even a mid-sized IT operations team should not dismiss this solely on the basis of missing CVSS data - stack overflows in core POSIX library functions historically carry elevated real-world risk once triggering conditions are characterized and a POC emerges.

Exploit ScenarioDerived

An attacker with the ability to supply a crafted directory path - either through a local shell, a mounted network filesystem, or an application that passes user-controlled input to opendir() - constructs a path exactly at or exceeding the MAX_PATH wide-character boundary. The wcscat() call in opendir() writes beyond the stack buffer, corrupting the return address or adjacent stack data. Depending on stack layout, compiler protections, and OS ASLR, this may cause a crash (denial of service) or enable control-flow hijacking. No public POC has been identified at time of analysis.

This Month Plan within 30 days. Why: MEDIUM severity (CVSS 4.0-6.9).
No patch listed yet

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Aug 13, 2026

Stack-based buffer overflow in the opendir() implementation triggered via unbounded wcscat() concatenation when processing paths at or near the MAX_PATH boundary. Callers supplying a crafted, maximally-long wide-character directory path can overflow a stack buffer, potentially leading to memory corruption, denial of service via crash, or - depending on stack layout and mitigations - arbitrary code execution. Ubuntu has reported this as a vendor-tracked issue; exploitation conditions and patch availability are not yet fully confirmed from available data.

RemediationAI

No vendor-released patch or advisory URL is available in the provided data at time of analysis. As a compensating control, operators should restrict the ability of untrusted users or processes to supply arbitrarily long directory paths to opendir()-invoking code. Where opendir() is called on attacker-influenced input (e.g., in FTP daemons, file managers, or web services), enforce strict path length validation before the call, rejecting inputs at or approaching MAX_PATH. Enabling stack-smashing protection (SSP/stack canaries, -fstack-protector-strong) and ASLR at the OS and compile level reduces exploitability of stack overflows even where the overflow itself cannot be prevented. Monitor Ubuntu Security Notices at ubuntu.com/security/notices for the official patch and affected package identification.

Affected ProductsAI

The affected product is the opendir() implementation as shipped in Ubuntu Linux, reported by Ubuntu as a vendor-tracked issue. Exact affected Ubuntu releases, glibc versions, and CPE strings are not provided in the available intelligence. No NVD CPE data is present. The specific library or binary containing the vulnerable wcscat call (e.g., glibc, a filesystem utility, or a userspace daemon) is not named in the available data. Consumers should monitor Ubuntu Security Notices (USN) for the precise package name and affected version range.

Affects your stack

Find out whether the stacks and servers you run are on an affected version.

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

The vulnerability resides in the opendir() POSIX function implementation, likely within glibc or a platform-specific filesystem abstraction layer on Ubuntu Linux. The root cause is an unsafe use of wcscat() - the wide-character (wchar_t) string concatenation function - to build or extend a directory path that can reach MAX_PATH in length. Unlike mbscpy/strcat equivalents, wcscat() performs no bounds checking; if the destination buffer is sized to exactly MAX_PATH wide characters but the concatenation of path components exceeds that boundary, the excess bytes overflow into adjacent stack frames. The CWE is not formally assigned in the available data, but this is a canonical CWE-121 (Stack-based Buffer Overflow), a subclass of CWE-787 (Out-of-bounds Write). The MAX_PATH boundary condition suggests the triggering path requires a filename or directory structure at or near 260 or 4096 characters depending on the filesystem and compile-time constant used.

Know when the next one hits your stack

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

vuln.today AI 7.4 HIGH

Local vector assumed as path supply is typically local; AC:H because MAX_PATH boundary conditions require precise path crafting; full CIA impact for stack overflow with code execution potential.

3.1 AV:L/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H
4.0 AV:L/AC:H/AT:P/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N

DescriptionCVE.org

[opendir() stack overflow via wcscat on MAX_PATH path]

Threat Intelligence Overview

Prevalence
Ubiquitous
opendir() is a core POSIX call present across essentially all Linux deployments
Data Quality
1 sources
Confidence: Low

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity MEDIUM
CISA KEV No
Public POC No
EPSS N/A
Patch available No
Active threat No
Deciding rule
MEDIUM severity (CVSS 4.0-6.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

Attack Technique

A buffer overflow occurs when a program writes more data to a memory buffer than it was allocated to hold, causing the excess data to spill into adjacent memory regions.

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy