CVE-2026-78254
Apache Ant: Path traversal in ftp and scp tasks allows arbitrary file write
Reported by apache · Published September 7, 2026
ant is fixed in 1.10.18 (Maven Central)
The ftp and scp tasks of Apache Ant can download files from a remote server. A malicious server can provide relative paths that allow it to write outside of the dedicated target directory for the download, making it possible to overwrite files of the attacker's choice using the permissions of the user running Ant in versions prior to Ant 1.10.18. In order to exploit this vulnerability, the server would either have to be malicious or be subject to a machine-in-the-middle attack. Additionally in the case of scp or the ftp task using ftps the server must pass the server identity checks performed by the tasks. For ftp tasks not using ftps a malicious server could act as a machine-in-the-middle to provide malicious files. Starting with Ant 1.10.18 both tasks will prevent writing outside of the destination directory by default. An option is available to disable this behavior in the unlikely case that the old behavior is required by existing build files. Mitigations: Users of scp and ftp (when using ftps) in any version of Ant should not bypass server identity checks. Users of ftp not using ftps should switch to ftps where possible. All users are recommended to upgrade to Apache Ant 1.10.18, which fixes this issue.
Fixed versions
Upgrade to a fixed version or later. Language registries are listed first, then Linux distributions, then vendor products.
| Package | Ecosystem | Fixed in |
|---|---|---|
| org.apache.ant:ant | Maven Central | 1.10.18 |
| ant-junit | Amazon Linux | 1.10.12-5.amzn2023.0.5, 1.9.16-1.amzn2.0.2 |
| ant-jmf | Amazon Linux | 1.10.12-5.amzn2023.0.5, 1.9.16-1.amzn2.0.2 |
| apache-ant | Alpine | 1.10.18-r0 |
| ant-javamail | Amazon Linux | 1.10.12-5.amzn2023.0.5, 1.9.16-1.amzn2.0.2 |
| ant-apache-bsf | Amazon Linux | 1.10.12-5.amzn2023.0.5, 1.9.16-1.amzn2.0.2 |
| ant-apache-log4j | Amazon Linux | 1.9.16-1.amzn2.0.2 |
| ant | Amazon Linux | 1.10.12-5.amzn2023.0.5, 1.9.16-1.amzn2.0.2 |
| ant-apache-xalan2 | Amazon Linux | 1.10.12-5.amzn2023.0.5, 1.9.16-1.amzn2.0.2 |
| ant-apache-resolver | Amazon Linux | 1.10.12-5.amzn2023.0.5, 1.9.16-1.amzn2.0.2 |
| ant-xz | Amazon Linux | 1.10.12-5.amzn2023.0.5 |
| ant-apache-regexp | Amazon Linux | 1.10.12-5.amzn2023.0.5, 1.9.16-1.amzn2.0.2 |
15 more packages have a fixed version. See every fix in Lookup.
Risk scores
Affected products
| Vendor | Product | Versions |
|---|---|---|
| Apache Software Foundation | Apache Ant | 1.2 |
| amazon:2 | ant-junit | 0 |
| amazon:2 | ant-jmf | 0 |
| alpine | apache-ant | 0 |
| amazon:2 | ant-javamail | 0 |
| amazon:2023 | ant-apache-bsf | 0 |
| amazon:2023 | ant-jmf | 0 |
| amazon:2 | ant-apache-log4j | 0 |
| amazon:2023 | ant | 0 |
| amazon:2023 | ant-junit | 0 |
| amazon:2 | ant | 0 |
| amazon:2023 | ant-apache-xalan2 | 0 |
| amazon:2 | ant-apache-resolver | 0 |
| amazon:2023 | ant-xz | 0 |
| amazon:2 | ant-apache-xalan2 | 0 |
| amazon:2023 | ant-apache-regexp | 0 |
| amazon:2023 | ant-imageio | 0 |
| amazon:2023 | ant-javamail | 0 |
| amazon:2 | ant-commons-net | 0 |
| amazon:2023 | ant-manual | 0 |
…and 27 more
Timeline
- Sep 7, 2026 CVE Published
- Sep 7, 2026 EPSS Score (30 in total, the first dated here)
- Sep 17, 2026 CVE Updated
- Oct 30, 2026 Security Advisory
Query this with the API
The same record, from the CLI:
vulnetix vdb vuln CVE-2026-78254
vulnetix vdb fixes CVE-2026-78254
Or with curl, using the org id and key from your account page:
curl -s -H "Authorization: ApiKey ${VULNETIX_ORG_ID}:${VULNETIX_API_KEY}" \
"https://api.vdb.vulnetix.com/v2/vuln/CVE-2026-78254/fixes/registry"
The Community plan is free and allows 50 queries a day. Get a free API key · API quickstart
References
- vendor-advisory
- https://nvd.nist.gov/vuln/detail/CVE-2026-78254 advisory
- http://www.openwall.com/lists/oss-security/2026/09/06/2 url