Skip to main content
Press slash or control plus K to focus the search. Use the arrow keys to navigate results and press enter to open a threat.
Reconnecting to live updates…

CVE-2026-23942: CWE-22 Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal') in Erlang OTP

0
Medium
VulnerabilityCVE-2026-23942cvecve-2026-23942cwe-22
Published: Fri Mar 13 2026 (03/13/2026, 09:11:56 UTC)
Source: CVE Database V5
Vendor/Project: Erlang
Product: OTP

Description

CVE-2026-23942 is a path traversal vulnerability in the Erlang OTP ssh_sftpd module affecting versions from OTP 17. 0 through OTP 28. 4. 1 and related ssh releases. The flaw arises because the SFTP server uses string prefix matching instead of proper path component validation to check if a requested path is within the configured root directory. This allows authenticated users to access sibling directories that share a prefix with the root directory, potentially exposing unauthorized files. The vulnerability requires authentication but no user interaction and has a CVSS 4. 0 score of 5. 3, indicating medium severity. There are no known exploits in the wild currently.

AI-Powered Analysis

AILast updated: 03/13/2026, 09:44:55 UTC

Technical Analysis

CVE-2026-23942 is a path traversal vulnerability classified under CWE-22 found in the ssh_sftpd module of Erlang OTP, specifically in the program files lib/ssh/src/ssh_sftpd.erl and the routine ssh_sftpd:is_within_root/2. The vulnerability stems from the use of string prefix matching (via lists:prefix/2) to verify if a requested file path resides within the configured root directory for the SFTP server. This approach is flawed because it does not properly validate path components, allowing paths that share a common prefix with the root directory but are actually outside it to be accepted. For example, if the root directory is set to /home/user1, paths such as /home/user10 or /home/user1_backup are incorrectly considered valid, enabling authenticated users to access sibling directories and potentially sensitive files outside the intended root. The affected OTP versions range from 17.0 up to 28.4.1, including specific patch releases 27.3.4.9 and 26.2.5.18, and corresponding ssh versions from 3.0.1 to 5.5.1 and certain patch versions. The vulnerability does not require user interaction but does require authentication, and it does not affect confidentiality or availability directly but can lead to unauthorized information disclosure. The CVSS 4.0 base score is 5.3 (medium severity), reflecting the moderate risk posed by this vulnerability. No public exploits are known at this time, but the flaw represents a significant logic error in path validation that could be exploited in environments where Erlang OTP's ssh_sftpd is used for SFTP services.

Potential Impact

The primary impact of CVE-2026-23942 is unauthorized access to files outside the intended SFTP root directory by authenticated users. This can lead to information disclosure of sensitive files stored in sibling directories that share a prefix with the configured root. While it does not allow remote unauthenticated access or direct code execution, the breach of directory isolation undermines the security model of the SFTP server. Organizations relying on Erlang OTP's ssh_sftpd for secure file transfers may face data leakage risks, especially if sensitive data is stored in adjacent directories. This can affect confidentiality and potentially lead to compliance violations or data breaches. The vulnerability could also facilitate lateral movement within a compromised environment if attackers gain authenticated access. Given the widespread use of Erlang OTP in telecommunications, messaging systems, and distributed applications, the impact could be significant in sectors such as finance, telecommunications, and government infrastructure.

Mitigation Recommendations

To mitigate CVE-2026-23942, organizations should upgrade Erlang OTP to versions beyond OTP 28.4.1 or the latest patched releases where the vulnerability is fixed. If immediate upgrading is not feasible, administrators should implement strict path validation controls on the SFTP server side, ensuring that path checks verify full path components rather than relying on prefix matching. Employing chroot jails or containerization to isolate the SFTP environment can further limit exposure. Monitoring and logging SFTP access for unusual directory traversal attempts can help detect exploitation attempts. Additionally, restricting SFTP access to only trusted users and enforcing strong authentication mechanisms reduces risk. Regularly auditing file system permissions and directory structures to avoid sensitive data residing in sibling directories with similar prefixes is also recommended. Finally, organizations should stay informed about Erlang OTP security advisories and apply patches promptly.

Pro Console: star threats, build custom feeds, automate alerts via Slack, email & webhooks.Upgrade to Pro

Technical Details

Data Version
5.2
Assigner Short Name
EEF
Date Reserved
2026-01-19T14:23:14.343Z
Cvss Version
4.0
State
PUBLISHED

Threat ID: 69b3d90e2f860ef943bac728

Added to database: 3/13/2026, 9:29:50 AM

Last enriched: 3/13/2026, 9:44:55 AM

Last updated: 3/13/2026, 10:52:04 AM

Views: 5

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

Need more coverage?

Upgrade to Pro Console in Console -> Billing for AI refresh and higher limits.

For incident response and remediation, OffSeq services can help resolve threats faster.

Latest Threats

Breach by OffSeqOFFSEQFRIENDS — 25% OFF

Check if your credentials are on the dark web

Instant breach scanning across billions of leaked records. Free tier available.

Scan now
OffSeq TrainingCredly Certified

Lead Pen Test Professional

Technical5-day eLearningPECB Accredited
View courses