Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB
CVE-2026-106552 Overview
CVE-2026-106552 is a directory traversal vulnerability [CWE-23] in the sftp client component of OpenSSH versions prior to 10.6. A malicious or compromised SFTP server can craft responses that cause the client to write files outside the intended destination directory during a recursive copy operation. Exploitation requires user interaction, specifically a user initiating a recursive download such as sftp -r from an attacker-controlled server. Successful exploitation can lead to file overwrite in unintended filesystem locations with the privileges of the invoking user.
Critical Impact
A hostile SFTP server can write client-side files to arbitrary paths accessible to the invoking user during recursive copy operations, enabling potential configuration tampering or persistence.
Affected Products
- OpenSSH versions prior to 10.6 (sftp client component)
- Operating system distributions bundling vulnerable OpenSSH sftp builds
- Any environment where users perform recursive SFTP downloads from untrusted servers
Discovery Timeline
- 2026-10-06 - CVE-2026-106552 published to NVD
- 2026-10-07 - Last updated in NVD database
Technical Details for CVE-2026-106552
Vulnerability Analysis
The flaw resides in the OpenSSH sftp client when performing recursive copy operations. During a recursive transfer, the client enumerates remote directory entries returned by the server and writes corresponding files locally. The client fails to adequately validate server-supplied filenames against path traversal sequences before using them to construct local write paths.
An attacker controlling the SFTP server can return directory entries containing .. sequences or absolute path components. When the client processes these entries during recursion, it resolves the path outside the user-specified destination directory. This allows the server to dictate where files land on the client filesystem.
The impact is limited to the privileges of the user running sftp. However, overwriting files such as shell startup scripts, SSH authorized keys, or application configuration files can enable follow-on code execution or persistence under that user context.
Root Cause
The root cause is insufficient sanitization of untrusted filename metadata received from the SFTP server during recursive directory traversal. The client treats server-provided names as safe path components rather than validating that each resolved target remains within the destination tree.
Attack Vector
Exploitation requires the victim to initiate a recursive SFTP copy, such as sftp -r user@host:/remote/dir local/dir, against an attacker-controlled or compromised server. The server responds with crafted directory listings that cause writes to locations outside local/dir. No authentication to the client is needed; the server simply replies to legitimate client requests. See the OpenSSH Release Notes 10.6 for the upstream description of the fix.
Detection Methods for CVE-2026-106552
Indicators of Compromise
- Files created or modified outside the intended destination directory following an sftp -r session
- Unexpected writes to sensitive user-controlled paths such as ~/.ssh/authorized_keys, ~/.bashrc, or ~/.profile shortly after an SFTP transfer
- SFTP sessions to untrusted or newly observed remote hosts preceding anomalous local filesystem changes
Detection Strategies
- Audit filesystem telemetry for write events whose parent process is sftp but whose target path lies outside the command-line destination argument
- Correlate SSH client process execution with subsequent writes to dotfiles, cron directories, or shell initialization scripts
- Inventory installed OpenSSH versions across endpoints and flag hosts running ssh -V output below OpenSSH_10.6
Monitoring Recommendations
- Enable process and file integrity monitoring on user home directories and system configuration paths
- Log outbound SSH and SFTP connections to non-corporate destinations for anomaly review
- Alert on modifications to SSH key material, shell profiles, and scheduled task configurations outside change windows
How to Mitigate CVE-2026-106552
Immediate Actions Required
- Upgrade OpenSSH to version 10.6 or later on all client systems that perform SFTP operations
- Restrict recursive SFTP transfers (sftp -r, get -r) to known, trusted servers until patches are deployed
- Inventory and prioritize patching for jump hosts, developer workstations, and automation servers that frequently use SFTP
Patch Information
Upstream fixes are included in OpenSSH 10.6. Refer to the OpenSSH Release Notes 10.6 for the complete changelog and apply distribution-provided updates once available. Operators who build OpenSSH from source should rebuild and redeploy client binaries.
Workarounds
- Avoid recursive SFTP copies from untrusted servers; transfer individual files or use archive formats such as tar fetched as a single file
- Perform SFTP operations inside a dedicated, unprivileged account or container with a scratch working directory to contain unintended writes
- Use scp alternatives or rsync over SSH with explicit path constraints where feasible, keeping in mind their own security considerations
# Verify installed OpenSSH client version
ssh -V
# Example: isolate SFTP recursive transfers to a sandbox directory
mkdir -p /tmp/sftp-sandbox && cd /tmp/sftp-sandbox
sftp -r user@trusted-host:/remote/path ./download
Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB

