7.7

CVSS 4.0 base score, per Ubuntu; the APT maintainers call the bug critical

3

retries by default since APT 2.3.2, the setting that opens the path on Debian 12 and Ubuntu 22.04 onward

11

stable APT branches patched in one day, from 1.2 to 3.2

0

retries for the upgrade run: the one setting that closes the path while you patch

The hash passed. The file changed.

A package manager has one promise that matters: the file it installs is the file it checked. On 4 Nov 2026 the APT maintainers, Debian and Ubuntu published fixes for CVE-2026-109518, and that promise is the thing that broke. An attacker who can shape the plain HTTP traffic between a Debian or Ubuntu machine and its package mirror, which includes anyone running a malicious mirror or a proxy on the path, can make APT retry a download and, through a mishandled hard link, overwrite a package APT has already verified. The signature check runs. The hash check runs. Both pass. Then the file underneath them changes, and dpkg installs it as root.

That is a time-of-check to time-of-use bug in the one place a Linux estate has agreed to trust unconditionally. The signing is still sound. What failed is the gap between the moment APT decided a file was good and the moment it handed that file to the installer. The APT maintainers call it a critical file verification bypass. Ubuntu scores it 7.7 on CVSS 4.0, high, and the gap between those two words is mostly that the attacker has to be on the path. Who is on the path is the question this post is about.

Two things make this more than a Linux patch note. The host most likely to run an unattended package install over HTTP, on a network nobody audits, from an image nobody rebuilt, is not a hardened production server. It is the CI runner, the Dockerfile that opens with an install step, the build VM behind a caching proxy, and those machines hold the credentials that build and sign what production runs. We made a close argument about the Brotli copies inside container images that scanners miss; this time the exposure is the tool that installs libraries. And the setting which opens the path is a default that moved. Retrying a failed download became the default in APT 2.3.2, which is why Debian 12 and Ubuntu 22.04 and everything after them are exposed out of the box while older releases are not, unless a script turned retries on. Defaults change quietly, and the attack surface moves with them.

What is APT CVE-2026-109518?

The advisories agree on the mechanism and we keep to their words. Ubuntu's description: on Debian, Ubuntu and derivative distributions, an on-path attacker who can manipulate the HTTP traffic between an APT client and an archive server, including a malicious mirror or proxy, can trick the client into installing an attacker-controlled unverified package and achieve remote code execution with root privileges. The cause is the reuse of hard links, and the attack requires the client to follow redirects and to retry the download of package files. Debian's advisory adds the shape of the trick: APT can merge two different package downloads after an HTTP redirect gives them the same URI, and improper file handling when resuming an HTTP download lets a man in the middle replace a package after verification.

The APT maintainers' own notice states the precondition. The bypass relies on the Acquire::Retries setting being non-zero, which has only been the default since APT 2.3.2. Ubuntu gives the operator's version: the value 3 is the default from Debian 12 and Ubuntu 22.04 LTS onward, so older releases are unaffected in a default configuration. The maintainers add the caveat that matters for a mixed fleet: many user scripts set retries on older releases anyway, because flaky mirrors are a fact of life in build pipelines.

On severity, Ubuntu rates the flaw high priority with a CVSS 4.0 base score of 7.7: network, low complexity, attack requirements present, no privileges, passive user interaction, high impact across the board. The APT maintainers rate the same bug critical. Both are correct. The score discounts for the on-path requirement; the maintainers describe what the bug does to the trust model once that requirement is met. None of the advisories reports exploitation, and we have seen no credible claim of any as we publish.

The fix shipped broadly in one day. The maintainers released updates for 11 stable branches, from the 1.2 series that Ubuntu 16.04 carries up to 3.2, plus builds for Ubuntu 14.04 under Ubuntu Pro and for the current Ubuntu development release. Debian 13 trixie is fixed in 3.0.4 and Debian 12 bookworm in 2.6.2. The upstream fix is small and its commit message tells the story: open target files exclusively, because opening an existing file and modifying it can change other files in unexpected ways when they are hard links.

CVE-2026-109518, APT HTTP download handling High
  • Product //

    APT on Debian, Ubuntu and derivatives; every APT front end, not snaps or FTP
  • Condition //

    plain HTTP to the mirror, an attacker on the path or a malicious mirror, and Acquire::Retries above zero
  • Exposed by default //

    Debian 12 and later, Ubuntu 22.04 LTS and later; older releases only where a script set retries
  • Fixed in //

    Debian 13 3.0.4, Debian 12 2.6.2, Ubuntu 24.04 2.8.4ubuntu0.1, Ubuntu 22.04 2.4.15ubuntu0.1, older Ubuntu via Pro
  • CVSS //

    7.7 (4.0, Ubuntu); the APT maintainers rate it critical
  • Impact //

    an unverified package installed as root
  • Exploited //

    no exploitation reported in the advisories as of 8 Nov 2026

How a failed download becomes root

The chain below describes what each stage achieves and nothing about how to perform it. The attacker's starting position is the only expensive part. They need to sit between an APT client and the archive it talks to over plain HTTP. A compromised network segment does it. So does a malicious or compromised mirror, or a caching proxy on the path. From there they wait for the machine to install something. On a developer laptop that is an occasional event. On a CI runner or a container build it is the first thing that happens, every time.

Figure 01

Verified, then replaced, then installed

  1. 01

    Path //

    The attacker controls HTTP responses between an APT client and its mirror: a hostile segment, a bad mirror, or a proxy on the way.

  2. 02

    Trigger //

    The machine runs a package install. On a build runner or in a Dockerfile this happens unattended, many times a day.

  3. 03

    Merge //

    Redirects make APT treat two different package downloads as one file, bound together by a hard link.

  4. 04

    Retry //

    Ordinary transient server errors make APT retry and resume. The resumed write lands in the file APT has already verified.

  5. 05

    Install //

    dpkg installs the replaced package and runs its scripts as root.

Result //

The hash check passed on a file that no longer exists.

Every stage uses behaviour APT was designed to have. The bug is in the order they can be made to happen.

The limits are real. The attacker cannot do this from across the internet to a machine whose mirror path they do not control. They cannot do it to a system that fetches over HTTPS, because the responses they would need to forge are inside TLS. They cannot do it where retries are set to zero, because the retry is the write that does the damage. What they can do, from any position in stage one, is turn the most trusted operation on a Linux host into arbitrary code as root, with the system's own logs showing a routine install that passed verification. There is no failed signature to alert on, because the signature did not fail.

Why plain HTTP mirrors were fine until the retry

The design APT rests on is worth restating, because the bug does not refute it. The archive publishes a signed release file that lists the hash of every index, and the indexes list the hash of every package. APT verifies the signature once, then checks each downloaded file against the hash the signed chain vouches for. Transport security is beside the point in that model: a hostile mirror or network can tamper with a file, and the file still fails the hash and is refused. That is why the distributions have shipped HTTP mirrors for decades, and why Canonical still calls the signature scheme a stronger protection than HTTPS: it checks the file end to end, not only in transit.

The model has one assumption: the file that is checked is the file that is installed. Three ordinary decisions eroded it. APT merges downloads that redirect to the same location and implements the merge with hard links, so one piece of content can be reached by two names. Resuming a partial download writes into the existing file rather than starting a new one, which is how resumption works everywhere. And for most of APT's life a failed download simply failed; in 2.3.2 the client started retrying three times by default. Each decision is defensible. Together they mean that after APT has checked one name, a retry on the other name can write through the shared link into the checked content, and nothing re-checks it.

Nor is this the first time the HTTP transport is where the trust model leaked. In 2019, CVE-2019-3462 let a man in the middle inject content through the redirect handling in APT's HTTP method, in versions 1.4.8 and earlier, and Debian fixed it in DSA-4371-1. The redirect parsing was hardened. The broader lesson is that the HTTP method is the part of APT that negotiates with an adversary, and every feature added to it, redirects, merged downloads, resumption, retries, is a new conversation with that adversary. We see the pattern on engagements in every kind of software: a control is designed against the threat model of its day, then convenience features accumulate around it, each tested for whether it works and not for whether it reopens the thing the control was for. We wrote about it at the scale of a whole supply chain in Trusted by default, compromised by design. APT's retry is the small, exact version.

Where this lands: CI runners, container builds, proxies

Ask where in an organisation a machine installs packages over plain HTTP, unattended, from a network position the security team has never mapped, and the answer is rarely production. Production servers are patched on a schedule, often through a controlled mirror, and often by unattended-upgrades, which Canonical says applies security updates within 24 hours by default. The machines that match the description are the ones that build production.

A GitHub Actions or GitLab job that begins with a package install does so as root on a runner it did not choose, over a network the runner image decided. A Dockerfile that starts from a Debian or Ubuntu base and installs packages in its first layer runs that install on a build host, through whatever proxy the build host has, then bakes the result into an image that is pushed, pulled and run everywhere. A corporate egress proxy or package cache sits, by design, on the path between all of these and the mirror. Each of these is the position stage one of the chain requires, and each holds the credentials an attacker actually wants: source, signing keys, cloud roles, the token that publishes the artefact. The LiteLLM release that shipped a credential stealer through its own signed pipeline showed what an attacker does from that position. CVE-2026-109518 is a way into it that needs no stolen token, only a network seat.

Two things are worth checking this week beyond the patch. The first is whether your builds set retries explicitly. The maintainers' warning about user scripts applies with force to Dockerfiles and CI configuration, where a retry count is a common fix for a flaky mirror; a search for Acquire::Retries across your repositories tells you which older base images are exposed despite their default. The second is whether anything in your estate still fetches packages over plain HTTP, and from where. APT identifies itself in every request with a User-Agent that begins with the string Debian APT-HTTP, so a proxy or network log can list every client that talks to a mirror without TLS and every destination it talks to. The rule below is the simplest version of that hunt: APT traffic, over port 80, to anything that is not a mirror you meant to use.

Figure 02

APT package traffic over plain HTTP to an unapproved mirror

Sigma

title: APT package download over plain HTTP to an unapproved host
status: experimental
description: APT's HTTP method identifies itself as Debian APT-HTTP. Package
  fetches without TLS to hosts outside the approved mirror list are the
  network position CVE-2026-109518 needs. Tune the filter to your mirrors.
logsource:
  category: proxy
detection:
  selection:
    c-useragent|startswith: 'Debian APT-HTTP'
    dst_port: 80
  filter_approved:
    cs-host:
      - 'deb.debian.org'
      - 'security.debian.org'
      - 'archive.ubuntu.com'
      - 'security.ubuntu.com'
      - 'mirror.internal.example'
  condition: selection and not filter_approved
falsepositives:
  - A mirror or caching proxy you run but have not yet listed
  - Country mirrors a developer chose by hand
level: medium
A starting point to tune against your own telemetry, not a production rule. Replace the approved list with the mirrors and caches you actually operate.

The rule is a map more than an alarm. Most of what it shows on the first run will be legitimate, and the value is the list. Every host on it is one to patch before its next install, one whose network path you should be able to describe, and a candidate for HTTPS sources once the fix is in. Our guide to reviewing what a CI pipeline can reach covers the credential side of the same hosts, and the container registry review covers how an image built on one of them becomes everyone's problem.

How we test the package path on an engagement

When we assess a build environment, the first question is not which packages are installed. It is where they come from and who sits on the way. We map every place a build fetches code or binaries, and for each we ask what transport it uses, what verifies it, and what network position would let someone change it. Package installs over plain HTTP from a runner on a shared network are a standard finding, and until this week the honest severity was low, because the archive signature made the transport irrelevant. CVE-2026-109518 moves that finding, for unpatched clients, to the top of the report. The network position that used to buy an attacker nothing now buys them root on the build host.

The second question is what the build host can reach once it is root, and that is usually the finding that gets the budget. A runner that holds a long-lived cloud key, a signing key, or a token that can publish to the registry turns a single install into a compromise of everything downstream. Our GitHub Actions workflow checker looks at the workflow side of that path, the unpinned actions, injectable inputs and broad token scopes that let an attacker into a job; this bug is the network side, where the job is already running and the attacker is on the wire. We never deliver a modified package into a client's pipeline. The finding stands on the configuration.

What is still coming

Expect the long tail to be images, not hosts. The patch for a running system is one command, and unattended-upgrades will apply it on its own where it is enabled. The exposure that persists is every container base image, runner image and golden VM template built before 4 Nov 2026, each carrying the old apt into every build until someone rebuilds the image. Organisations that pin base images for reproducibility, which is good practice, keep the vulnerable client exactly as long as they keep the pin, and the retry default means those images are exposed with no configuration at all. We made the neighbouring argument about an update channel that became the attack: the mechanism you rely on to fix things runs with the most trust and the least suspicion.

Expect the derivatives to lag. Ubuntu names them as affected without listing them, and every Debian-based distribution, appliance and embedded image carries its own copy of apt on its own schedule. The 11 patched branches cover the upstream series back to 1.2; what a downstream vendor shipped, and when it rebuilds, is a question for that vendor.

Expect the class to recur, and not only in APT. Every package manager that resumes downloads, follows redirects and retries has the same three conversations with the network, and the same assumption that the file it checked is the file it uses. The durable fix is not in APT. It is treating the fetch path of every build as attack surface that is mapped and tested, rather than as plumbing that works.

What to do today

  1. Upgrade apt on every Debian and Ubuntu system, with retries off for that one run. Canonical says setting Acquire::Retries to zero during the upgrade protects it against both an on-path attacker and a malicious mirror. On Ubuntu 20.04 and older the fix is through Ubuntu Pro.

  2. Rebuild every base image, runner image and VM template that installs packages. A patched host is undone by the next job that boots from an old image. Check the apt version inside a fresh build, not the image tag.

  3. Search your Dockerfiles and CI configuration for Acquire::Retries. Any older release with retries set by a script is exposed despite its safe default.

  4. List every client that fetches packages over plain HTTP and where from. The Sigma rule above is a starting point. Approved mirrors over HTTP are a decision to revisit; unknown destinations are a finding.

  5. Move package sources to HTTPS where the mirror supports it, and draw the path from each build host to its mirror. The signature scheme stays the primary control; the encrypted channel takes the on-path attacker out of the next bug before it is found, and the map tells you who could sit there.