CVE-2026-53422
JSON

2.3low

SFTP REALPATH path-existence oracle allowing filesystem enumeration outside configured root

Severity
2.3low CVSS:4.0 by EEF
Exploit likelihood
0.34% (higher than 30% of CVEs; EPSS, by FIRST)
Published
Last changed
Assigned by
EEF
Also known as
EEF-CVE-2026-53422GHSA-h9pw-h5w4-h976

Description

Observable Response Discrepancy vulnerability in Erlang OTP ssh (ssh_sftpd module) allows an authenticated SFTP user to enumerate the existence of files and directories outside the configured root directory. The SSH_FXP_REALPATH handler in ssh_sftpd calls relate_file_name/3 with Canonicalize=false, unlike every other SFTP operation handler. This allows .. components in the requested path to bypass the is_within_root/2 check without being resolved. The un-canonicalized path then enters resolve_symlinks/2, which walks up the directory tree above the configured root and issues read_link() syscalls on arbitrary filesystem paths. An authenticated SFTP client can exploit this by sending a REALPATH request with a crafted traversal path. The server response differs depending on whether the target path exists on the host filesystem (SSH_FXP_NAME when the path resolves successfully, SSH_FX_NO_SUCH_FILE when it does not). This creates a path-existence oracle that an attacker can use to enumerate the filesystem structure outside the configured root, including the existence of sensitive files, directories, and mount points. The vulnerability leaks only the existence of paths. No file contents, credentials, or write access are obtainable through this issue alone. The information gained may assist further attacks when combined with other vulnerabilities. This vulnerability is associated with program files lib/ssh/src/ssh_sftpd.erl and program routine ssh_sftpd:handle_op/4. This issue affects OTP from OTP 17.0 before OTP 27.3.4.14, OTP 28.5.0.3, and OTP 29.0.3, corresponding to ssh from 3.0.1 before 5.2.11.9, 5.5.2.2, and 6.0.2. Whether OTP before OTP 17.0, corresponding to ssh before 3.0.1, is affected is unknown.

Affected

Product or packageVersionsReported by
sshfrom 3.0.1 before *CVE List
otpfrom 17.0 before *CVE List
erlang/otpfrom 84adefa331c4159d432d22840663c38f155cd4c1 before *
Not affected: from 059e5785ef8c1d423820ca633fb7b37f47645172 before *, from 86622cfaacf57a02c7645d1999f946846b504c94 before *, from c5a8f50ae68888ff243c5c741a06d2b3a4b48b7a before *
CVE List
https://github.com/erlang/otpfrom 84adefa331c4159d432d22840663c38f155cd4c1 before 059e5785ef8c1d423820ca633fb7b37f47645172, before 86622cfaacf57a02c7645d1999f946846b504c94, before c5a8f50ae68888ff243c5c741a06d2b3a4b48b7aErlang Ecosystem Foundation
erlang erlang/otpfrom 17.0 before 27.3.4.14, from 28.0 before 28.5.0.3, from 29.0 before 29.0.3NVD
erlang erlang/sshfrom 3.0.1 before 5.2.11.9, from 5.3 before 5.5.2.2, from 6.0 before 6.0.2NVD

All scores

EEF2.3low CVSS:4.0CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:L/VI:N/VA:N/SC:N/SI:N/SA:N
Erlang Ecosystem FoundationNot scored CVSS:4.0CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:L/VI:N/VA:N/SC:N/SI:N/SA:N
NVD4.3medium CVSS:3.1CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:N

Classification

CWE-204

SSVC (CISA-ADP): exploitation none, automatable no, technical impact partial.

What each source says

CVE List

Observable Response Discrepancy vulnerability in Erlang OTP ssh (ssh_sftpd module) allows an authenticated SFTP user to enumerate the existence of files and directories outside the configured root directory. The SSH_FXP_REALPATH handler in ssh_sftpd calls relate_file_name/3 with Canonicalize=false, unlike every other SFTP operation handler. This allows .. components in the requested path to bypass the is_within_root/2 check without being resolved. The un-canonicalized path then enters resolve_symlinks/2, which walks up the directory tree above the configured root and issues read_link() syscalls on arbitrary filesystem paths. An authenticated SFTP client can exploit this by sending a REALPATH request with a crafted traversal path. The server response differs depending on whether the target path exists on the host filesystem (SSH_FXP_NAME when the path resolves successfully, SSH_FX_NO_SUCH_FILE when it does not). This creates a path-existence oracle that an attacker can use to enumerate the filesystem structure outside the configured root, including the existence of sensitive files, directories, and mount points. The vulnerability leaks only the existence of paths. No file contents, credentials, or write access are obtainable through this issue alone. The information gained may assist further attacks when combined with other vulnerabilities. This vulnerability is associated with program files lib/ssh/src/ssh_sftpd.erl and program routine ssh_sftpd:handle_op/4. This issue affects OTP from OTP 17.0 before OTP 27.3.4.14, OTP 28.5.0.3, and OTP 29.0.3, corresponding to ssh from 3.0.1 before 5.2.11.9, 5.5.2.2, and 6.0.2. Whether OTP before OTP 17.0, corresponding to ssh before 3.0.1, is affected is unknown.

Erlang Ecosystem Foundation

Summary

Observable Response Discrepancy vulnerability in Erlang OTP ssh (ssh_sftpd module) allows an authenticated SFTP user to enumerate the existence of files and directories outside the configured root directory.

The SSH_FXP_REALPATH handler in ssh_sftpd calls relate_file_name/3 with Canonicalize=false, unlike every other SFTP operation handler. This allows .. components in the requested path to bypass the is_within_root/2 check without being resolved. The un-canonicalized path then enters resolve_symlinks/2, which walks up the directory tree above the configured root and issues read_link() syscalls on arbitrary filesystem paths.

An authenticated SFTP client can exploit this by sending a REALPATH request with a crafted traversal path. The server response differs depending on whether the target path exists on the host filesystem (SSH_FXP_NAME when the path resolves successfully, SSH_FX_NO_SUCH_FILE when it does not). This creates a path-existence oracle that an attacker can use to enumerate the filesystem structure outside the configured root, including the existence of sensitive files, directories, and mount points.

The vulnerability leaks only the existence of paths. No file contents, credentials, or write access are obtainable through this issue alone. The information gained may assist further attacks when combined with other vulnerabilities.

This vulnerability is associated with program files lib/ssh/src/ssh_sftpd.erl and program routine ssh_sftpd:handle_op/4.

This issue affects OTP from OTP 17.0 before OTP 27.3.4.14, OTP 28.5.0.3, and OTP 29.0.3, corresponding to ssh from 3.0.1 before 5.2.11.9, 5.5.2.2, and 6.0.2. Whether OTP before OTP 17.0, corresponding to ssh before 3.0.1, is affected is unknown.

Workarounds

  • Use OS-level chroot to run the Erlang VM or SFTP server process in an isolated filesystem environment, eliminating reliance on the application-level root option.
  • Ensure the SFTP server port on the machine running the Erlang/OTP SFTP server is not reachable from untrusted machines.
  • Ensure that no sensitive information (usernames, project names, mount topology) is inferrable from the existence or non-existence of paths on the host filesystem.

Configurations

The SFTP subsystem must be configured with the root option in ssh_sftpd:subsystem_spec/1, and the operator must rely on it to provide filesystem path isolation. The root option is not set by default.

NVD (es)

Vulnerabilidad de Discrepancia de Respuesta Observable en Erlang OTP ssh (módulo ssh_sftpd) permite a un usuario SFTP autenticado enumerar la existencia de archivos y directorios fuera del directorio raíz configurado. El gestor SSH_FXP_REALPATH en ssh_sftpd llama a relate_file_name/3 con Canonicalize=false, a diferencia de cualquier otro gestor de operación SFTP. Esto permite que los componentes ’..’ en la ruta solicitada eludan la verificación is_within_root/2 sin ser resueltos. La ruta no canonizada luego entra en resolve_symlinks/2, que asciende por el árbol de directorios por encima de la raíz configurada y emite llamadas al sistema read_link() en rutas de sistema de archivos arbitrarias. Un cliente SFTP autenticado puede explotar esto enviando una solicitud REALPATH con una ruta de recorrido manipulada. La respuesta del servidor difiere dependiendo de si la ruta objetivo existe en el sistema de archivos del host (SSH_FXP_NAME cuando la ruta se resuelve con éxito, SSH_FX_NO_SUCH_FILE cuando no lo hace). Esto crea un oráculo de existencia de rutas que un atacante puede usar para enumerar la estructura del sistema de archivos fuera de la raíz configurada, incluyendo la existencia de archivos sensibles, directorios y puntos de montaje. La vulnerabilidad solo filtra la existencia de rutas. No se pueden obtener contenidos de archivos, credenciales o acceso de escritura a través de este problema por sí solo. La información obtenida puede ayudar a futuros ataques cuando se combina con otras vulnerabilidades. Esta vulnerabilidad está asociada con los archivos de programa lib/ssh/src/ssh_sftpd.erl y la rutina de programa ssh_sftpd:handle_op/4. Este problema afecta a OTP desde OTP 17.0 hasta OTP 29.0.3, 28.5.0.3 y 27.3.4.14 correspondiente a ssh desde 3.0.1 hasta 6.0.2, 5.5.2.2 y 5.2.11.9.

References

Sources

SourceRecordLicence
CVE ListCVE-2026-53422 changed 2026-11-20CVE Terms of Use
Erlang Ecosystem FoundationEEF-CVE-2026-53422 changed 2026-11-25CC-BY-4.0
NVDCVE-2026-53422 changed 2026-11-20Public domain