Safe kernel upgrade for CVE-2026-98432 on Ubuntu 24.04 with NVIDIA, and an analysis of the bug
This moves an Ubuntu 24.04 machine with an NVIDIA GPU onto a kernel that fixes CVE-2026-98432, a use-after-free in the kernel's IPv4 TCP code. It's built for a machine you may not be able to reach if the upgrade goes wrong: nothing is trusted until it has booted, and a failed step stops explicitly instead of leaving a broken host.
Prefer Ubuntu's normal updates if they carry the fix. This exists because, in the emergency it was written for, the only fixed kernel was a pre-release build in Canonical's staging archive. The newest published kernel, 7.0.0-42, still had the bug.
Don't go by the version number. Read the running kernel's own code with personal_server's gate:
sudo bash scripts/14_verify_kernel_fixes.sh
It reads the machine code of the running kernel from live memory, and of the kernel GRUB boots next from its image. In the fixed kernel, inet_sock_destruct and tcp_v4_reqsk_destructor call kvfree_call_rcu. In the vulnerable one they call kfree.
If it fails, try the normal route first:
sudo apt-get update
sudo apt-get install --only-upgrade linux-generic-hwe-24.04
sudo systemctl reboot
Use this repository only if that brings no fixed kernel.
You need your own copy, because the process publishes its audit trail to Git as it runs. Fork this repository, and on the machine:
git clone <your fork> && cd <it>
kernel-upgrade/install.sh
sudo systemctl reboot
Allow about 8 minutes for the reboots. The machine reboots itself twice more, and needs nothing from you:
uname -r # must print 7.0.0-43-generic
python3 -I kernel-upgrade/upgrade.py status # must say complete
If the machine doesn't fit, the installer says why and changes nothing. kernel-upgrade/PROCEDURE.md has what the host needs, every failure and what to do about it, and the crash boundary.
| Boot | Who starts it | Kernel | What happens |
|---|---|---|---|
| 1 | You | A kernel known to work here | Proves GRUB can write to this disk, so a one-time boot really is one time |
| 2 | The process, once | -43, one time only | Reads the fix from kernel memory and checks everything the host had before. A panic returns to the known-good kernel by itself |
| 3 | The process, once | -43, through stock GRUB | Proves the final state, with stock GRUB restored and every other kernel removed |
What it guarantees:
complete means proven. That status is only reached after a boot through the final GRUB and kernel state, and the final record reaches Git before the status is saved.lock.json says what to install and holds nothing about any machine. The fallback, removal lists and health baseline are all read from the host, and published before the first change.PROCEDURE.md names. The next boot continues or stops explicitly.kernel-upgrade/vm/final-run.sh builds UEFI test machines from scratch, with a 4 TB emulated NVMe disk, and runs the exact installer in them. test-report.json records the hashes of what passed, and install.sh refuses to run if the code differs from that report.
The 24 scenarios cover real power cuts during the packages, during the final purge and after the final record, kernel panics and hangs, GitHub going down at each stage, and a machine that must be refused. from-zero builds a machine with personal_server's real script from the real Ubuntu archive, sees the gate refuse it, upgrades it, and sees the gate pass. from-zero needs a clone of personal_server next to this repository.
What VMs can't show is listed in PROCEDURE.md. The main one is real firmware, which boot 1 tests on the machine itself.
This ran on an internet-facing server with a 4 TB NVMe disk and an RTX 5090 on 2026-11-02. That machine has no remote console, only a power switch on the network. The first boot through stock GRUB passed every check, with 7.0.0-43 as its only kernel and the fix confirmed in live kernel memory.
The first version of this process worked there but wasn't right. systemd killed it in its last milliseconds, because it deleted its own unit file while running. It also called itself complete before stock GRUB had booted, and it had that machine's details built into it. This repository is the rebuild. Independent reviews then found further real defects before it ran again, including a check that would have stopped every real NVMe host after its packages had changed.
├── ANALYSIS.md what the bug is, what MPTCP changes, and the limits of that
├── upstream-fix.diff the two-line upstream fix
├── filter/ an interim packet filter. It reduces exposure and isn't a fix
└── kernel-upgrade/
├── PROCEDURE.md the full procedure, failure table and crash boundary
├── install.sh the entry point
├── upgrade.py the controller and the audit publisher
├── lock.json what to install, with hashes
├── cuda-probe.c a real GPU allocation, for the health check
├── test_upgrade.py logic tests against a real Git remote
├── test-report.json what passed, and the exact bytes it covered
├── test-evidence/ the journal of each VM scenario
└── vm/ the VM test harness
The code is released under the Unlicense. The packages keep their own licences. The release holds Canonical's kernel packages and dkms, because the staging archive deletes old builds. NVIDIA's packages aren't redistributed here: they come from your own Ubuntu archive.