All posts by daroc

[$] Stabilizing Rust’s never type

Post Syndicated from daroc original https://lwn.net/Articles/1091015/

A function’s return type is supposed to indicate the kind of data that it
produces.
Rust’s “never” type, which is

denoted by an exclamation mark
(“!“), is the type the language uses to mark
a function that never returns and other places where a value can never occur. For
a long time, the never type was used internally by the compiler, but was
considered an unstable feature. On

August 24
, after more than two years of work,
Rust-compiler-contributor “waffle” finally managed to stabilize the type. It
took so long, in part, because it involved a small breaking
change to previous Rust editions, which the compiler maintainers needed to
ensure did not impact much real code.

[$] Securely suspending LUKS-encrypted disks

Post Syndicated from daroc original https://lwn.net/Articles/1090568/

When a laptop is asleep, its memory is not unreadable. The right
tooling can attach to the computer’s memory bus and read out its contents, and

cold-boot attacks
can theoretically read values from memory for a short time
after the computer loses power. That
is really an unavoidable fact about the hardware, but some users would still
like to ensure that, even if this happens, their long-term encryption keys, such as
the key for full-disk encryption, remain unreadable. In June 2026, Ingo
Blechschmidt

discovered
that Linux kernel versions after 6.9 (released in
May 2024)
were not erasing disk-encryption keys when a laptop was put to sleep, even
when configured to do so. He quickly identified a potential fix, which has been
merged, but it was not a comprehensive solution.

[$] The “rnull” Rust block driver

Post Syndicated from daroc original https://lwn.net/Articles/1090378/

The
null block
driver
(null_blk)
is a small driver that is mostly useful for benchmarking block-layer
implementations. It accepts all requests and marks them complete as quickly as
possible, doing as little work as possible. In June 2026, Andreas Hindborg shared

a patch set
implementing the same functionality in Rust, in order to show
that a simple block driver is now possible to write using the kernel’s
Rust APIs and to enable comparisons between the C and Rust
implementations.
A minimal version of the “rnull” driver is already present in the mainline
kernel, but Hindborg’s patch set brings it up to feature parity with the C
version.

[$] How to be safe from quantum computing

Post Syndicated from daroc original https://lwn.net/Articles/1088305/

Practical quantum computers have been ten years away for the last several
decades. Now, however, it’s beginning to look as though they will be
possible in just a few years. Recent

research with obfuscated results
demonstrated much lower memory requirements to factor

ECDSA
keys on a quantum computer, with

work by other researchers in the open
more than halving memory use compared
to the state of the art in 2023.
At the same time, computer
manufacturers are

boasting
quantum processors that retain viable superpositions over longer periods.
Given how slowly software updates filter out to stable systems, it’s worth
looking at what configuration changes and protocol updates are needed to be safe
from quantum computers now.

[$] BPF, continuous testing, and stable kernels

Post Syndicated from daroc original https://lwn.net/Articles/1087823/

Ihor Solodrai and Shung-Hsi Yu wrapped up the BPF track at the 2026

Linux
Storage, Filesystem, Memory-Management, and BPF Summit
with a pair of
sessions related to testing.
Solodrai spoke about what has changed for BPF’s continuous-integration (CI)
testing. Yu spoke about what may be
needed to test BPF updates in stable kernels more thoroughly. The
BPF subsystem’s CI tests are in a good place, they said; even so, Solodrai and Yu have a
handful of possible avenues toward enabling better test coverage in the future.

Domas: Bypassing memory protection with AMD’s memory controllers

Post Syndicated from daroc original https://lwn.net/Articles/1088778/

Christopher Domas has
published a proof of concept with a description showing how to use AMD memory controllers’ bank swizzle mode to bypass memory protection and read or write arbitrary data, including CPU microcode definitions and memory belonging to the

platform security processor
. Among other things, this allows code running at the kernel level to directly manipulate the meaning of processor instructions, potentially bypassing other security measures such as memory encryption and virtual machine isolation.

This is not, strictly, unexpected behavior: it is

documented in AMD’s manual
(on page 113 of that PDF). But the fact that it can be used to access arbitrary memory and thereby rewrite supposedly immutable parts of the computer’s firmware without crashing the host machine seems like an unintentional side-effect of the design. Fortunately, since enabling bank swizzle mode requires kernel-level privileges, the vulnerability is not an immediate problem for most software. Still, it seems likely that this technique will end up being used for nefarious purposes eventually.

[$] Block-layer error injection

Post Syndicated from daroc original https://lwn.net/Articles/1086344/

Storage code has to cope with hardware that fails in inconvenient
ways, but coaxing a healthy disk into producing those failures on
demand, for testing, is usually not possible. The kernel
provides several ways to inject block-layer I/O errors, but none of those can select the
operation to fail, pick the status code to return, or target a disk
directly without employing a stacked device on top. Use of a stacked device means
the test runs against the mapper device, not the disk it was meant to
exercise. A patch
series
from Christoph Hellwig adds a configurable error-injection
interface that does all three things that the current error-injection code
lacks, controlled by a per-disk debugfs
file.

[$] Even more formal verification for BPF

Post Syndicated from daroc original https://lwn.net/Articles/1087069/

BPF offers useful safety guarantees, but Kumar Kartikeya Dwivedi wants BPF
programs to be even safer. At the 2026

Linux Storage, Filesystem,
Memory-Management, and BPF Summit
, he led a session
(slides)
discussing the possibility
of adding domain-specific invariants to BPF programs. It was not a discussion
intended to lead to the implementation of any particular kernel feature, but
rather an overview of why additional formal verification might be needed, and
how it could work with the existing BPF ecosystem.

[$] Examining other network namespaces using BPF

Post Syndicated from daroc original https://lwn.net/Articles/1085896/

Jordan Rife’s work involves writing BPF programs for

Cilium
that interface with

Kubernetes

networking. As part of that work, he wants to enable BPF programs with
appropriate permissions to iterate through the sockets of a different network
namespace. He led a session about the idea at the 2026

Linux Storage,
Filesystem, Memory-Management, and BPF Summit
where the BPF developers in
attendance were quick to suggest a number of related alternatives.

Another npm worm

Post Syndicated from daroc original https://lwn.net/Articles/1087108/


StepSecurity
is

reporting
the emergence of a new worm affecting npm packages.
The design of the worm is nothing new, but the rapidity with which it is
exploiting captured npm
packager credentials is noteworthy.

TL;DR: A self-propagating worm, which we are calling ChainDrop, is spreading rapidly through the npm ecosystem. So far 435 packages and more than 1,550 compromised versions have been flagged, starting with [email protected]. If you are using any of the packages listed below, assume your environment is compromised. We are still investigating the full scope; check back on this post for updates.

[$] The future of libraries in BPF

Post Syndicated from daroc original https://lwn.net/Articles/1084869/

Song Liu believes that the way that programmers assemble complex BPF programs
will be changing rapidly in the future.
At a session of the 2026

Linux Storage,
Filesystem, Memory-Management, and BPF Summit
, he shared his thoughts on what
that change could look like, though he did not have any concrete proposals for
what, if anything, the BPF maintainers should do. He anticipates an
ecosystem of Rust BPF packages developing, which is significant because BPF
does not really have a package manager at the moment.

[$] Debugging information for inlined functions

Post Syndicated from daroc original https://lwn.net/Articles/1083985/

BPF programs use

BPF type format
(BTF) debugging information in order to
determine how to interact with functions in the kernel. Specifically, tracing a
kernel function involves finding its address in the kernel’s BTF section — but
that doesn’t work for functions that have been inlined, and therefore don’t have
a single, specific address. Alan Maguire wants to add information about inlined
functions to BTF in order to allow them to be traced, and led a session on that
topic at the 2026

Linux Storage, Filesystem, Memory-Management, and BPF Summit
.

[$] Progress toward compiling Linux with gccrs

Post Syndicated from daroc original https://lwn.net/Articles/1083202/

The
gccrs project
, which is creating a Rust frontend for the GCC compiler, has
spent the first half of 2026 focusing on compiling the Linux
kernel. By testing the compiler against the kernel crates, the
development team has made significant progress toward generating correct code
for other Rust programs. As detailed in the project’s

weekly
and

monthly
reports, this effort has uncovered and resolved problems
in areas such as
attribute handling (described in the

report for February
), name resolution, and resource management (both

detailed in the May report
). Currently, the compiler can only handle simple
standalone programs, but that situation could change rapidly in the coming
months.

[$] An update on netkit and the use of BPF in user space

Post Syndicated from daroc original https://lwn.net/Articles/1083418/

Daniel Borkmann led a session at the 2026

Linux Filesystem, Memory-Management,
and BPF Summit
about the progress that has been made with netkit, the subsystem
that allows virtual machines (VMs) running on Linux to perform networking efficiently.
When that did not fill the full time, he went on to discuss his idea for
using BPF to live-patch user-space applications. While netkit is making
progress, and can now support zero-copy receipt of packets into a VM in a
network namespace, the idea of using BPF for patching user-space programs
remains entirely speculative.

[$] Attaching programs to multiple tracepoints

Post Syndicated from daroc original https://lwn.net/Articles/1082948/

Tracepoints in the kernel are useful for a variety of purposes: debugging,
active monitoring, and performance measurements, among other things. Previously,
any given BPF program could only be attached to a single tracepoint.
Jiri Olsa has been working to change that, and led a discussion about
his progress at the 2026

Linux Storage, Filesystem, Memory-Management, and BPF
Summit
. That work has since been

merged
, and can be expected as part of the 7.2
kernel.

[$] Securing BPF LSMs against tampering

Post Syndicated from daroc original https://lwn.net/Articles/1082111/

Since 2020, BPF programs have been able to

act as
Linux security modules
(LSMs). Several projects, including systemd, have been working to use
that capability to provide more security to users. Christian Brauner
spoke at the 2026

Linux Storage, Filesystem, Memory-Management, and BPF Summit

about some of the limitations of using BPF in this way, and the changes he
would like to see for systemd’s use. In particular, he would like a way to make
sure that BPF programs cannot be removed or have their private data tampered with.

[$] Sending packets directly from BPF

Post Syndicated from daroc original https://lwn.net/Articles/1081696/


Tetragon
, the BPF-based security monitoring tool,
uses BPF to monitor different aspects of a running kernel and
enforce user-specified policies. It sends its data to a user-space process,
which forwards the data to a central monitoring service elsewhere in the
network, however. This
presents a point of vulnerability: if an attacker can kill Tetragon’s user-space
agent, it won’t be able to properly report on the situation. Song Liu, Mahé
Tardy, and Liam Wiseheart spoke about their work removing the need for the
user-space agent at the 2026

Linux Storage, Filesystem, Memory-Management, and
BPF Summit
.

Security updates for Tuesday

Post Syndicated from daroc original https://lwn.net/Articles/1082832/

Security updates have been issued by AlmaLinux (389-ds:1.4, buildah, freeipmi, freerdp, gegl, gimp, golang, kernel, libreoffice, maven:3.9, openexr, perl-DBI, plexus-utils, podman, tomcat, tomcat9, xorg-x11-server, and xorg-x11-server-Xwayland), Debian (imagemagick, p7zip, and redis), Fedora (breezy, calibre, and golang-github-openprinting-ipp-usb), Mageia (ffmpeg, gzip, haproxy, libheif, libtiff, libxml2, packages, perl-List-SomeUtils-XS, and perl-Socket), SUSE (alsa, chromedriver, curl, dhcpcd, docker-compose, glibc, haproxy, ImageMagick, jq, kernel, kubernetes, libpng15, libredwg-devel, libslirp, nghttp2, php8, python-Pillow, python313-Django, python313-weasyprint, qemu, rust-keylime, sccache, and systemd), and Ubuntu (cifs-utils, libexif, libreoffice, libssh2, openssh, and pipewire).

[$] Shielding running kernels against exploits with BPF

Post Syndicated from daroc original https://lwn.net/Articles/1081546/

Cisco has some unusual challenges when it comes to deploying security patches
across the company’s many devices running custom kernels. John Fastabend spoke
about his work preventing exploits with BPF at the 2026

Linux Storage,
Filesystem, Memory-Management, and BPF Summit
.
The technique could substantially reduce the time necessary to respond to kernel
vulnerabilities, but it will not be fully effective unless more hooks are added
to the kernel.

Final normal Debian bookworm release

Post Syndicated from daroc original https://lwn.net/Articles/1082647/

Debian has
announced the final normal update for Debian 12 (“bookworm”). Long-term-support updates will continue until 2028. As may be expected from a stable version, the update is mostly limited to security fixes. Still, it may be time for Debian users to look into upgrading to a more recent version. Conveniently, Debian 13 (“trixie”) also
received an update this weekend, with many of the same security fixes.