APT flaw in Debian and Ubuntu: a MitM can get root
CVE-2026-109518: through HTTP redirects and resumed downloads, an on-path attacker can swap an already verified package. Fixed versions and mitigations.

On 4 November 2026 Debian disclosed a vulnerability in APT, the package manager of Debian, Ubuntu and their derivatives. The flaw, tracked as CVE-2026-109518, allows an attacker able to manipulate HTTP traffic between the APT client and the archive server to replace a package after verification, and so execute arbitrary code as root. Debian and Ubuntu have already released updates; the Korean CERT (KISA/KrCERT) published an advisory on 5 November listing the affected and fixed versions.
According to CSO Online, the discovery is credited to researcher Max Justicz, and Ubuntu rated the flaw High, with a CVSS score of 7.7. Again according to CSO Online, the researcher said they found it in two hours of work with an AI.
How the attack works
APT repository signatures remain valid: the problem is not the verification, but what happens to the files after it. Debian’s advisory, quoted by CSO Online, describes two conditions that combine:
- APT can merge two different package downloads when an HTTP redirect gives them the same URI;
- improper file handling when an HTTP download is resumed allows an on-path attacker to replace the already verified package.
The APT developers, in the explanation reported by CSO Online, detail the chain: the attacker abuses redirects and transient HTTP server errors that trigger download retries; on the following attempts APT overwrites existing hard links with the attacker’s chosen content. KISA accordingly classifies the flaw as a “UNIX Hard Link” vulnerability. Since Debian packages are installed with root privileges, swapping one is equivalent to running code as root on the machine.
In the MITRE ATT&CK framework, the required position corresponds to technique T1557 (Adversary-in-the-Middle).
Who is exposed
Ubuntu, again according to CSO Online, describes the attacker as someone on the path between the client and the archive: a malicious mirror or a proxy can provide that position, but specific download conditions are required.
The decisive element is the Acquire::Retries option: the vulnerability is only triggered when retries are enabled (a non-zero value).
- According to the APT developers, this has been the default since version 2.3.2; on older installations it may have been enabled by scripts or configuration.
- Ubuntu states that the default value of 3 retries applies from Debian 12 (Bookworm) and Ubuntu 22.04 LTS onwards. Older releases are not exposed with the default configuration, but become exposed if retries have been enabled.
Fixed versions
According to CSO Online, Debian 13 (Trixie) is fixed in APT 3.0.4 and Debian 12 (Bookworm) in APT 2.6.2; Ubuntu has released packages for its supported releases, including 22.04 LTS, 24.04 LTS and 26.04 LTS, as well as 26.10. KISA’s advisory, which refers to the Debian advisories (LTS included) and to Ubuntu’s USN-8996-1, lists these fixed versions:
- APT (Debian): 1.2.36, 1.4.12, 1.6.19, 1.8.2.4, 2.0.12, 2.2.5, 2.4.15, 2.6.2, 2.8.4, 3.0.4, 3.2.1, 3.3.6 or later in their respective branches;
- APT (Ubuntu): 1.0.1ubuntu2.24+esm4, 1.2.36+esm1, 1.6.19+esm1, 2.0.12+esm1, 2.4.15ubuntu0.1, 2.8.4ubuntu0.1, 3.2.1ubuntu0.1, 3.3.3ubuntu0.1 or later.
For the APT 1.8.3–1.8.5 branch, KISA reports that no patch is available and recommends moving to a supported version.
The fix, CSO Online explains, addresses the root cause: in a commit dated 12 October, APT developer Julian Andres Klode changed the download code so that it opens destination files exclusively and removes existing ones before copying partially downloaded content. Downloads can therefore no longer write through a hard link into another file.
Impact for businesses
Debian and Ubuntu underpin a large share of servers, cloud virtual machines and container images, including those used by Italian and European companies. The attack scenario is not trivial, since it requires control of the traffic, but it hits a sensitive point: the channel through which all updates arrive. Internal mirrors, package caching proxies and shared networks thus need to be protected as carefully as the servers themselves.
For entities in scope of NIS2, the flaw touches two required measures: vulnerability handling and software supply chain security. Updates must be documented not only for production machines but also for the images and templates used to create new ones, as CSO Online recommends: an outdated image puts the vulnerable version back into circulation with every new deployment.
What to do now
- Update APT on all Debian and Ubuntu machines (
apt-get update && apt-get install --only-upgrade apt) and check the installed version withapt --version, comparing it with the list above. - Check the retry option with
apt-config dump | grep -i retries. Ubuntu recommends temporarily disabling retries (Acquire::Retries "0";in a file under/etc/apt/apt.conf.d/) until the update is complete everywhere. - Use HTTPS for repositories, as Ubuntu advises: it protects against traffic manipulation in this scenario. Make sure the mirrors you use, internal ones included, support it.
- Update base images, virtual machine templates and containers, not just running systems.
- Plan the migration of machines with APT 1.8.3–1.8.5, for which KISA reports no fix.
- Review package mirrors and proxies: who manages them, where they download from, who can tamper with their traffic.
How ARXDOME helps
ARX Sentry collects the software inventory of Linux computers and servers, which helps you quickly find the machines with an APT version to update. ARX Shield shows open vulnerabilities by machine and by package, along with their age, so you can track the closure of CVE-2026-109518 down to the last machine.
Last updated:


