All posts by corbet

[$] Two approaches to tightening restrictions on loadable modules

Post Syndicated from corbet original https://lwn.net/Articles/998221/

The kernel’s loadable-module facility allows code to be loaded into (and
sometimes removed from) a running kernel. Among other things, loadable
modules make it possible to run a kernel with only the subsystems needed
for the system’s hardware and workload. Loadable modules can also make it
easy for out-of-tree code to access parts of the kernel that developers
would prefer to keep private; this has led to many discussions in the
past. The topic has returned to the kernel’s mailing lists with two
different patch sets aimed at further tightening the restrictions applied
to loadable modules.

[$] Dancing the DMA two-step

Post Syndicated from corbet original https://lwn.net/Articles/997563/

Direct memory access (DMA) I/O is simple in concept: a peripheral device
moves data directly to or from memory while the CPU is busy doing other
things. As is so often the case, DMA is rather more complicated in
practice, and the kernel has developed a complicated internal API to
support it. It turns out that the DMA API, as it exists now, can affect
the performance of some high-bandwidth devices. In an effort to address
that problem, Leon Romanovsky is making the API even more complex with this patch series
adding a new two-step mapping API.

Security updates for Tuesday

Post Syndicated from corbet original https://lwn.net/Articles/997903/

Security updates have been issued by AlmaLinux (gstreamer1-plugins-base), Debian (chromium, ghostscript, libarchive, mpg123, ruby-saml, and symfony), Fedora (buildah and podman), Red Hat (buildah, containernetworking-plugins, podman, skopeo, and xorg-x11-server-Xwayland), Slackware (wget), SUSE (pcp), and Ubuntu (linux, linux-aws-5.15, linux-gcp, linux-gcp-5.15, linux-gke, linux-gkeop, linux-gkeop-5.15, linux-hwe-5.15, linux-ibm, linux-ibm-5.15, linux-kvm, linux-lowlatency, linux-lowlatency-hwe-5.15, linux-nvidia, linux-oracle, linux-oracle-5.15, linux-raspi, linux-xilinx-zynqmp and mysql-8.0).

[$] The top open-source security events in 2024

Post Syndicated from corbet original https://lwn.net/Articles/996955/

What have been the most significant security-related incidents for the
open-source community in 2024 (so far)? Marta Rybczyńska recently ran a
poll and got some interesting results. At the 2024 Open
Source Summit Japan
, she presented those results along with some
commentary of her own. The events in question are unlikely to be a
surprise to LWN readers, but the overall picture that was presented was
worth a look.

Cohen: gccrs: An alternative compiler for Rust

Post Syndicated from corbet original https://lwn.net/Articles/997483/

Arthur Cohen has posted a
detailed introduction to the gccrs project
on the Rust Blog, seemingly
with the goal of convincing the Rust community about the value of the
project.

Likewise, many GCC plugins are used for increasing the safety of
critical projects such as the Linux kernel, which has recently
gained support for the Rust programming language. This makes
gccrs a useful tool for analyzing unsafe Rust code, and
more generally Rust code which has to interact with existing C
code. We also want gccrs to be a useful tool for
rustc itself by helping pan out the Rust specification
effort with a unique viewpoint – that of a tool trying to replicate
another’s functionality, oftentimes through careful experimentation
and source reading where the existing documentation did not go into
enough detail.

(LWN last looked at gccrs in October).

[$] The trouble with struct sockaddr’s fake flexible array

Post Syndicated from corbet original https://lwn.net/Articles/997094/

Flexible arrays — arrays that are declared as the final member of a
structure and which have a size determined at run time — have long drawn
the attention of developers seeking to harden the kernel against
buffer-overflow vulnerabilities. These arrays have reliably been a source
of bugs, so anything that can be done to ensure that operations on them
stay within bounds is a welcome improvement. While many improvements,
including the recent counted-by work, have
been made, one of the most difficult cases remains. Now, however,
developers who are interested in using recent compiler bounds-checking
features are trying to get a handle on struct sockaddr.

Funding restored for man-page maintenance

Post Syndicated from corbet original https://lwn.net/Articles/997193/

Man pages maintainer Alejandro Colomar announced in September that he was suspending
his work due to a lack of support. He has now let
it be known
that funding has been found for the next year at least:

We’ve been talking for a couple of months, and we have already
agreed to sign a contract through the LF [Linux Foundation], where
a number of companies provide the funds for the contract. The
contract will cover the next 12 months for the agreed amount, and
we should sign it in the following days. Since I’ve already seen a
draft of the contract, and it looks good, I’ve already started
maintaining the project again, starting on Nov 1st.

The BPF instruction set architecture is now RFC 9669

Post Syndicated from corbet original https://lwn.net/Articles/997002/

After a couple of years of effort, the BPF instruction set architecture has
been accepted as RFC
9669
, giving it a standard outside of the in-kernel implementation. This message from David
Vernet
(who also contributed an article on
the standardization process
last year) describes the process and why it
is important:

Though some vendors have already implemented BPF offloading
capabilities without having a standardized ISA, others are not
quite as risk tolerant. As Christoph [Hellwig] discussed at LSFMM
2022, certain NVMe vendors have expressed an interest in building
BPF offloading capabilities for various use cases such as eXpress
Resubmission Path (XRP), but they simply can’t fund such a project
without certain components of BPF being standardized. Hence, the
effort to standardize BPF was born.

Security updates for Tuesday

Post Syndicated from corbet original https://lwn.net/Articles/997030/

Security updates have been issued by AlmaLinux (firefox, openexr, and thunderbird), Fedora (llama-cpp and python-quart), Oracle (firefox, openexr, thunderbird, and xorg-x11-server and xorg-x11-server-Xwayland), SUSE (chromium, govulncheck-vulndb, openssl-1_1, python311, and python312), and Ubuntu (linux-azure, linux-bluefield, linux-azure, linux-gcp, linux-ibm, openjpeg2, and ruby3.0, ruby3.2, ruby3.3).

[$] The OpenWrt One system

Post Syndicated from corbet original https://lwn.net/Articles/994961/

OpenWrt is, despite its relatively low
profile, one of our community’s most important distributions; it runs
untold numbers of network routers and has served as the base on which a lot
of network-oriented development (including the bufferbloat-reduction
work
) has been done. At the beginning of 2024, a few members of the
project announced
a plan to design and produce a router device specifically designed to run
OpenWrt. This device, dubbed the “OpenWrt One”, is now becoming available;
the kind folks at the Software Freedom
Conservancy
were kind enough to ship one to LWN, where the desire to
play with a new toy is never lacking.

[$] The Overture open-mapping project

Post Syndicated from corbet original https://lwn.net/Articles/995992/

OpenStreetMap tends to dominate
the space for open mapping data, but it is not the only project working in
this area. At the 2024 Open
Source Summit Japan
, Marc Prioleau presented the Overture Maps Foundation, which is
building and distributing a set of worldwide maps under open licenses.
Overture may have a similar goal to OpenStreetMap, but its approach and
intended uses are significantly different.

Flock: a Flutter fork

Post Syndicated from corbet original https://lwn.net/Articles/996147/

A project called Flock has announced
its existence
. Flock is a fork of the Flutter user-interface toolkit
project, motivated by frustration with the resources that Google is putting
into Flutter.

We describe Flock as “Flutter+”. In other words, we do not want, or
intend, to fork the Flutter community. Flock will remain constantly
up to date with Flutter. Flock will add important bug fixes, and
popular community features, which the Flutter team either can’t, or
won’t implement.

(LWN looked at flutter in 2020).

Kernel prepatch 6.12-rc5

Post Syndicated from corbet original https://lwn.net/Articles/995981/

Linus has released 6.12-rc5 for testing.

rc5 looks perfectly normal, and maybe even on the small side of
normal. The diffstat looks nice and flat too, with the exception of
the removal of the da8xx fbdev driver due to it having been
replaced by the tilcdc driver. And I’m sure we’re all thinking the
same thing: “What lovely descriptive driver names we have”.

[$] realloc() and the oversize importance of zero-size objects

Post Syndicated from corbet original https://lwn.net/Articles/995196/

Small objects can lead to large email threads. In this
case, the GNU C Library (glibc) community has been having an extensive
debate over the handling of zero-byte allocations. Specifically, what
should happen when a program calls realloc()
specifying a size of zero? This is, it seems, a topic about which some
people, at least, have strong feelings.