CVE-2026-59381
Spring Integration Remote File MGET Local Directory Path Traversal via Server-Controlled Remote Directory
Description
The fix for CVE-2026-40987 validates only the file name against the local directory. For the remote file outbound gateway MGET command, the local directory itself can be derived from the server-controlled listing entry via the documented #remoteDirectory SpEL variable in a local-directory-expression. Since the directory is canonicalized before the containment check, the check passes even though the directory has already escaped the intended root, and the framework then creates the escaped directory.
As a result, a malicious FTP, SFTP or SMB server can write files with attacker-controlled content to arbitrary paths outside the configured local directory.
Applications are affected if they use the MGET command of an FTP, SFTP or SMB outbound gateway with a local directory expression that references #remoteDirectory (as in the reference documentation examples) and connect to a server that may be malicious or compromised.
Affected Maven artifacts (1)
| Artifact | Affected versions | Fixed in |
|---|---|---|
| org.springframework.integration » spring-integration-file | >= 5.5.0, <= 5.5.22>= 6.4.0, <= 6.4.13>= 6.5.0, <= 6.5.11>= 7.0.0, < 7.0.8>= 7.1.0, < 7.1.3 | 7.0.8, 7.1.3 |
Blast radius
79% of the dependent artifacts (50) still pull an affected version in their latest release.
| Depth | Dependent versions |
|---|---|
| Direct | 242 |
| 2 hops | 292 |
| 3 hops | 77 |
| 4 hops | 9 |
Most used dependents
- org.springframework.integration » spring-integration-sftp45 usages
- org.springframework.integration » spring-integration-ftp37 usages
- org.apache.sshd » apache-sshd14 usages
- org.eclipse.digitaltwin.basyx » basyx.aasenvironment-core5 usages
- org.springframework.cloud.fn » spring-file-common5 usages
- org.eclipse.dirigible » dirigible-components-group-engines4 usages
- org.springframework.cloud.fn » spring-splitter-function4 usages
- org.springframework.integration » spring-integration-zip3 usages
- org.apache.sshd » sshd-spring-sftp3 usages
- org.eclipse.digitaltwin.basyx » basyx.aasenvironment-http3 usages
- org.eclipse.digitaltwin.basyx » basyx.aasenvironment-feature-authorization2 usages
- org.eclipse.dirigible » dirigible-application2 usages
- org.springframework.cloud.fn » spring-file-consumer2 usages
- org.springframework.cloud.fn » spring-file-supplier2 usages
- org.springframework.cloud.fn » spring-ftp-common2 usages
Computed from the dependency graph of build 20261125.2201 (compile and runtime scopes, nearest version wins). Exclusions and dependency management in consuming projects are not applied, so dependents are potentially affected. When several artifacts are affected, a dependent version that pulls more than one of them is counted once per artifact.
