|
|
Log in / Subscribe / Register

A security model for systemd

By Joe Brockmeier
November 5, 2025

All Systems Go!

Linux has many security features and tools that have evolved over the years to address threats as they emerge and security gaps as they are discovered. Linux security is all, as Lennart Poettering observed at the All Systems Go! conference held in Berlin, somewhat random and not a "clean" design. To many observers, that may also appear to be the case for systemd; however, Poettering said that he does have a vision for how all of the security-related pieces of systemd are meant to fit together. He wanted to use his talk to explain "how the individual security-related parts of systemd actually fit together and why they exist in the first place".

I did not have a chance to attend the All Systems Go! conference this year, but watched the recording of the talk after it was published. The slides are also available.

What is a security model?

Poettering said that when he started drafting his slides it dawned on him that he had used the phrase "security model" frequently, but without knowing its formal definition. So he turned to Wikipedia's definition, which states:

A computer security model is a scheme for specifying and enforcing security policies. A security model may be founded upon a formal model of access rights, a model of computation, a model of distributed computing, or no particular theoretical grounding at all.

That definition was pleasing, he said, because he could just "pull something out of my hair and it's a security model." Of course, he wanted to be a bit more formal than that. Considering the threats in the world we actually live in was the place to begin.

Thinking about threats

Today's systems are always exposed, he said. They are always connected; even systems that people do not think about, such as those in cars, are effectively always online waiting for updates. And systems are often in physically untrusted environments. Many systems are hosted by cloud providers and outside the physical control of their users. Users also carry around digital devices, such as phones, tablets, and laptops: "So it is absolutely essential that we talk about security to protect them both from attacks on the network and also locally and physically."

The next thing is to think about what is actually being attacked. Poettering described some of the possible scenarios; one type of attack might take advantage of a vulnerability in unprivileged code, while another might try to exploit privileged code to make it execute something it was not supposed to. It could be an attack on the kernel from user space. "We need to know what's being attacked in order to defend those parts from whomever is attacking them."

Attacks also have different goals, he said. Some attacks may target user data, others may attempt to backdoor a system, and still others may be focused on using a system's resources, or conducting a denial-of-service (DoS) attack. The type of attacks determine the type of protections to be used. Encryption, he said, is useful if one is worried about data exfiltration, but not so much for a DoS.

Poettering said that he also thought about where attacks are coming from. For example, does an attacker have physical access to a system, is the attack coming over a network, or is the attack coming from inside the system? Maybe a user has a compromised Emacs package, or something escapes a web browser's sandbox. Not all of these attack sources are relevant to systemd, of course, but thinking about security means understanding that attacks can come from everywhere.

FLOUTing security

The bottom line is that the approach to defending against attacks depends on where they come from and what the intention of the attack is. Poettering put up a new slide, which he said was the most important of all the slides in his presentation. It included his acronym for systemd's security model, "FLOUT":

Frustrate attacks
Limit exposure after successful attacks
Observe attacks
Undo attacks
Track vulnerabilities

"I call this 'FLOUT': frustrate, limit, observe, undo, and track. And I think in systemd we need to do something about all five of them".

The first step is to "frustrate" attackers; to make attacks impossible. "Don't even allow the attack to happen and all will be good." But, it does not always work that way; software is vulnerable, and exploits are inevitable. That is why limiting exposure with sandboxing is important, he said. If a system is exploited, "they might do bad stuff inside of that sandbox, but hopefully not outside of it."

Since exploits are inevitable, it also necessary to be able to observe the system and know not only that an attack happened, but how it happened as well. And, once an attack has happened and been detected, it must be undone. With containers and virtual machines, it is less important to have a reset function, Poettering said: "Just delete the VM or container, if you have the suspicion that it was exploited, and create a new one". But that approach does not work so well with physical devices. "We need to always have something like a factory reset that we can return to a well-defined state" and know that it is no longer exploited. Finally, there is tracking vulnerabilities. Ideally, he said, you want to know in advance if something is vulnerable.

Poettering returned to a theme from the beginning of the talk; the fact that Linux, and its security features, were not designed "in a smooth, elegant way". There are so many different security components, he complained, ranging from the original Unix model with UIDs and GIDs, to user namespaces. "And if you want to use them together, its your problem". Too much complexity means less security.

He said that he preferred universal security mechanisms to fine-grained ones. This means finding general rules that always apply and implementing security policies that match those rules, rather than trying to apply policies for specific projects or use cases. He gave the example that device nodes should only be allowed in /dev. That is a very simple security policy that is not tied to any specific hardware.

But that is not how many of Linux's security mechanisms are built. SELinux, for instance, requires a specific policy for each daemon. Then, one might write the policy that forbids that daemon from creating device nodes. But that is much more fragile and difficult to maintain, he said. "It's much easier figuring out universal truths and enforcing them system-wide". To do that, components should be isolated into separate worlds.

Worlds apart

Poettering said that he liked to use the word "worlds" because it's not used much in the Linux community, so far. The term "worlds" could be replaced with "containers", "sandboxes", "namespaces", and so on. The important concept is that something in a separate world is not only restricted from accessing resources that are outside of that world, it should not see those resources at all.

So to keep the complexity of these sandboxes small, it's good if all these objects are not even visible, not even something you have to think about controlling access to, because they are not there, right?

Security rules should be that way, he said, and deal with isolation and visibility. That is different than the way SELinux works; everything still runs in the same world. An application may be locked down, but it still sees everything else.

The next fundamental thing to think about, he said, is to figure out what an application is in the first place and how to model it for security. It is not just an executable binary, but a combination of libraries, runtimes, data resources, configuration files, and more, all put together. To have a security model, "we need to model apps so that we know how to apply the security" to them.

Ideally, an app would be something like an Open Container Initiative (OCI) image or Flatpak container that has all of its resources shipped in an "atomic" combination; that is, all of the components are shipped together and updated together. In this way, he said, each application is its own world. Here, Poettering seemed to be comparing the update model for Docker-type containers and Flatpak containers to package-based application updates, where an application's dependencies might updated independently; he said that "non-atomic behavior" is a security vulnerability because different components may not be tested together.

Another piece of a security model is delegation; components need to be able to talk to one another and delegate tasks. On the server side, the database and web server must be able to talk to one another. On the desktop, the application that needs a Bluetooth device needs to be able to talk to the application that manages Bluetooth devices.

Security boundaries

Poettering also talked about different types of security boundaries. Security sandboxes are one type of boundary that most people already think about, and boundaries between user identities (UIDs). A system's different boot phases are yet another type of boundary; for example, during certain parts of the boot process there are values that are measured into the TPM. After that phase of the boot process is finished it "kind of blows a fuse" and the system can no longer modify those values, which provides a security boundary.

He said that there are also distinctions that are important between code, configuration, and state. Code is executable, but the configuration is not. The resources should be kept separate; state and configuration should be mutable, but code should not be mutable "because that's an immediate exploit, basically, if some app or user manages to change the code".

Along with the security boundaries are the technologies that enforce those boundaries; for example, Linux namespaces, SELinux security labels, CPU rings, and others.

Distributions

The Linux distribution code-review model is supposed to be a security feature, he said. It means that users do not have to download software from 500 different sources they "cannot possibly understand if they are trustworthy or not". Instead, users rely on distributions to do some vetting of the code.

However, Poettering said that there are problems with this model: namely that it does not scale and it is too slow. Distributions cannot package everything, and they cannot keep up with how quickly developers release software. Plus, code reviews are hard, even harder than programming. "So do we really trust all the packagers and the distributions to do this comprehensively? I can tell you I'm not." This is not to disrespect distribution packagers, he said: "I'm just saying that because I know I'm struggling with code reviews, and so I assume that other people are not necessarily much better than me".

One never knows, he said, if distribution packagers are actually reviewing the code they package, and "sometimes it becomes visible that they don't; let's hope that those are the exceptions". Sandboxing and compartmentalizing, Poettering said, is essential to ensure that users do not have to rely solely on code review for protection.

Rules

Having examined all the things that one has to think about when creating a security model, Poettering wanted to share the rules that he has come up with. The first is that kernel objects should be authenticated before they are instantiated. "We should minimize any interaction with data, with objects, with stuff that hasn't been authenticated yet because that is always where the risk is."

Poettering also said that security should focus on images, not files; look at the security of an entire app image, rather than trying to examine individual files (or "inodes" as he put it). "We should measure everything in combination before we use it". He brought up sandboxing again, and said that it was necessary to "isolate everywhere".

Another rule is that a comprehensive factory reset is a must, he said. This cannot be an afterthought, but something that needs to be in the system right away. And, finally, "we need to really protect our security boundaries".

But, he said, a security model still has to be useful. And, "as most of us here are hackers" there needs to be a break-glass mode that allows for making temporary changes and debugging. A break glass mode should be a measured and logged event, though: "Even if you are allowed to do this, there needs to be a trace of it afterward". Such a mode should not allow a developer to exfiltrate data from a system, and possibly even invalidate data in some way.

Linux misdesigns

Next, Poettering identified some of the things he felt were misdesigns in the Linux and Unix security models that he does not want to rely on. His first gripe was with the SUID (or "setuid") bit on files. This is not a new topic for him; Poettering said that general-purpose Linux distributions should get rid of SUID binaries in 2023, in response to a GNU C library (glibc) vulnerability. Instead, he suggested using interprocess communication (IPC) to manage executing a privileged operation on behalf of an unprivileged user.

He also felt that the Linux capabilities implementation is a terrible thing. The feature is "kind of necessary", but a design mistake. For example, CAP_SYS_ADMIN is "this grab bag of privileges of the super user". He complained that it had a privilege "so much bigger than all the other ones that it's a useless separation" of privileges. However, complaints about CAP_SYS_ADMIN are neither new nor rare; Michael Kerrisk, for example, enumerated several in his LWN article about it in 2012.

In any case, Poettering did acknowledge that capabilities are "not entirely useless", and that systemd makes heavy use of capabilities. However, "we only make use of it because it's there, and it's really basic, and you cannot even turn it off in the kernel".

One of the core Unix designs that Linux has inherited is "everything is a file". That is, he said, not actually true. There are certain kinds of objects that are not inodes, such as System V semaphores and System V shared memory. That is a problem, because they are objects with a different type of access control than inodes where "at least we know how security works".

Implementation in systemd

"Now, let's be concrete", Poettering said. It was time to explain how systemd implements the security model that he had discussed, and where its components fit into the FLOUT framework. The first was to sandbox services, to limit exposure; systemd has a number of features for putting services into their own sandbox.

Another is using dm-verity and signatures for discoverable disk images (DDIs) that are inspected to ensure they meet image policies. Verifying disk images would frustrate attackers, as well as provide observability; if a disk image does not match the signature, that is a sign of tampering. Systemd's factory reset features provide the "undo" part of the FLOUT framework; in systemd v258 the project added the ability to reset the TPM as well as disk partitions. LWN covered that in August 2025.

Poettering said that we should also "try really hard to do writable XOR executable mounts". A filesystem should be mounted writable so that its contents can be modified, or it should be mounted as executable so that binaries could be run from it. But a filesystem should never be both. If that were implemented through the whole system, he said, it would be much more secure. Systemd provides tools to do this, in part, with its system extension features. Systemd can mount system extension images (sysext) for /usr and /opt, and configuration extension images (confext) for /etc. The default is to mount these extension read-only, though it is possible to make them writable.

Systemd also uses the TPM a lot, "for fundamental key material" to decrypt disks (systemd-cryptsetup) and service credentials (systemd-creds). That, he said, helped to frustrate attackers and limit access. Finally, he quickly mentioned using the varlink IPC model for delegating and making requests to services, which also helped as a way to limit access.

Questions

One member of the audience wanted to know how Poettering would replace capabilities if he had a magic wand capable of doing so. "If you don't like it, what would you like to see instead?" Poettering responded that his issue was not with the capability model per se, but with the actual implementation in Linux. He said that he liked FreeBSD's Capsicum: "if they would implement that, that would be lovely".

Another attendee asked when systemd would enable the no new privileges flag. Poettering said that it was already possible to use that flag with systemd because it does not have SUID binaries. "We do not allow that". But, he said, it does not mean that the rest of the system is free of SUID binaries. It should be the goal, "at least in well-defined systems" to just get rid of SUID binaries.


Index entries for this article
ConferenceAll Systems Go!/2025


to post comments

OpenBSD pledge & unveil are also nice

Posted Nov 5, 2025 16:15 UTC (Wed) by rbranco (subscriber, #129813) [Link]

There are implementations for Linux using seccomp & Landlock:
- https://github.com/jart/pledge/
- https://github.com/marty1885/landlock-unveil

Relationship with kernel

Posted Nov 5, 2025 17:49 UTC (Wed) by SLi (subscriber, #53131) [Link] (1 responses)

I know this is neither the intent nor quite true, but one gets the feeling that the mentality is a bit of a resigned "this is what the kernel folks have decided to give us, and we'll do our best with it"—i.e. there's a large development barrier between systemd and the kernel. This is, of course, probably both good and bad; but given that systemd is relatively central to modern Linux systems, do you think it would make sense to even try to develop them together? If not now, then at some point in the future?

Now it has a bit of a feeling of waterfall development with agreed responsibilities and "you stay there, I stay here".

I'm not even saying this is bad. It's actually very good that the userspace/kernel API gets defined well and narrowly. Rather, do you see this as a hindrance?

Relationship with kernel

Posted Nov 5, 2025 18:17 UTC (Wed) by bluca (subscriber, #118303) [Link]

Fortunately it is not quite the case, generally speaking. Lots of stuff gets added because we ask for them and are the primary users - see most of the PID FD interfaces that were added in the past few years, and lots of cgroups stuff before that too.
However, there are tons of _existing_ interfaces/systems/whatnot that can't really change, as it would be a massive compat break to do so, and an humongous task on top of that, so it is true that we are resigned to e.g. file caps being what they are.
Adding new things is much much easier than changing existing, entrenched subsystems.

So as always it's nuanced, and there's a bit of both at play.

capabilities and, er, capabilities

Posted Nov 5, 2025 18:16 UTC (Wed) by smcv (subscriber, #53363) [Link]

> how Poettering would replace capabilities if he had a magic wand capable of doing so ... He said that he liked FreeBSD's Capsicum

... so, he'd like to replace the thing that is named "capabilities" (but, confusingly, is not a capability-based security model with the meaning used in e.g. https://en.wikipedia.org/wiki/Capability-based_security) with a capability-based security model. Terminology is hard!

Images are a false simplification

Posted Nov 5, 2025 18:32 UTC (Wed) by nim-nim (subscriber, #34454) [Link] (29 responses)

Images are no easier to check or proof than packages. A giant store of isolated images is just a giant store of isolated things, much like Amazon or Alibaba is a giant store of isolated gadgets, where you have no clue if anything is genuine or safe to use, and most often it is no genuine or safe and getting an idea if it is genuine or safe requires someone poking inside products looking what they are built from. Which is more or less equivalent into decomposing an app system into packages.

The disconnect is expecting too much of package validation and too little of image validation, because we wish for things to be simpler than they are.

That being said containment of app systems is clearly worthwhile however you assemble those app systems.

Images are a false simplification

Posted Nov 5, 2025 20:28 UTC (Wed) by ebee_matteo (guest, #165284) [Link] (28 responses)

I think the point being made is rather that, by virtue of using immutable images that can be verified before being started, you can trust that they were not tampered with from the point where they were signed.

Of course, you are right that this does solve just the integrity problem and does not prove authenticity.

The trust boundary however is pushed a bit further: at the point where you can validate an image was signed by the right people with the right keys.

Compare with a Debian package, whose files can be modified on disk after installation by a malicious user. And of course, an image also often implies a reproducible environment (e.g. controlled env variables, etc.) which makes it a bit harder to exploit.

Images are a false simplification

Posted Nov 5, 2025 21:05 UTC (Wed) by bluca (subscriber, #118303) [Link] (9 responses)

> Of course, you are right that this does solve just the integrity problem and does not prove authenticity.

It provides authenticity too, as the point being made was about signed dm-verity images. The signature is verified by the kernel keyring, so both authenticity and integrity are covered.

Of course this is not the case when using more antiquated image formats such as Docker, where it's just a bunch of tarballs in a trenchcoat, but systemd has been supporting better image formats for a long time now.

Images are a false simplification

Posted Nov 5, 2025 22:06 UTC (Wed) by nim-nim (subscriber, #34454) [Link] (3 responses)

Either way the value is limited.

We’ve known for quite a long time it is useless to install genuine foo if genuine foo can not resist exploitation as soon as it is put online (as companies deploying golden Windows images discovered as soon as networking became common), and we’ve known for quite a long time attackers rarely bother altering components in flight they typo squat and trick you into installing genuine authenticated malware (not different from the counterfeits that flood marketplaces and that Amazon or Alibaba will happily ship you in their genuine state).

Security comes from the ability to rebuild and redistribute stuff when it has a hole (honest mistakes) and from poking inside stuff that will be redistributed to check it actually is what it pretends to be (deliberate poisoning). And then you can sign the result and argue if your signing is solid or not, but signing is only worthwhile if the two previous steps have been done properly.

Images are a false simplification

Posted Nov 6, 2025 1:22 UTC (Thu) by Nahor (subscriber, #51583) [Link] (2 responses)

> And then you can sign the result and argue if your signing is solid or not, but signing is only worthwhile if the two previous steps have been done properly.

If what you built and distributed can easily be replaced without you knowing, then those two steps are of limited value too.

And continuing your line of thought, if signing/immutability/rebuild/distribution are all done right, they are useless if you don't very the source code you're using.

And even if the source code verification is done right, it is useless if the person doing the verification and signing of the code can be corrupted or coerced with a $5 wrench.

And even if [...]

TLDR; what you're arguing is that security is pointless and of limited values because there will always be a point where you have to trust something or someone. There will always be a weak link. All we can do is ensuring that most links are safe to reduce the attack surface. Using images is one step in that direction.

Images are a false simplification

Posted Nov 6, 2025 7:32 UTC (Thu) by nim-nim (subscriber, #34454) [Link] (1 responses)

That’s the “trust the vendor” thought but in out world we definitely do not trust the vendor.

We trust a system, where maximum transparency, accountability and absence of lockdown keep vendors honest. We trust the regulator, that forces vendors to provide a minimum of information on their pretty boxes, we trust consumer associations, that check the regulator is not captured by vendors, we trust people that perform reviews, tests and disassembly of products, the more so they are diverse and independent and unable to collude with one another, we trust competition and the regulations that enforce this competition and prevent vendors from cornering and locking down some part of the market.

And then you can add a certificate of genuine authenticity to the mix but most of the things you'll buy in real life don’t come with those because that’s icing on the cake no more. Trusting the vendor produces 737 maxes. This is not a fluke but human nature. You're usually better served by checking other things such as the quality of materials and assembly.

Performing third party checks is hard, and long, and those checks are usually incomplete, be it by distributions or in the real world, while printing authenticity certificates is easy. It is very tempting to slap shiny certificates on an opaque box and declare mission accomplished but it is not. Moreso if the result is reducing vendor accountability and dis-incentivize doing things right (I’m not saying that’s the case here but it is the usual ending of let’s trust the vendor initiatives).

Images are a false simplification

Posted Nov 6, 2025 19:01 UTC (Thu) by Nahor (subscriber, #51583) [Link]

> It is very tempting to slap shiny certificates on an opaque box and declare mission accomplished but it is not

Nobody said that signatures are the only thing needed, that they are sufficient. We only said that they are necessary. You still need someone to verify that what is being signed is what it's supposed to be. And you're only supposed to accept the signature of people you trust (be it a vendor, a regulator, a consumer association, whatever).

On their own, yes, signatures are useless. But so is source code verification if you have no way to ensure that your binaries are built from that code, by a compiler that will not add backdoors, and that the loader/kernel is actually loading that binary when executing.
One without the other is useless. Individually, they are both necessary but insufficient. It's only when they are combined that they become sufficient.

And signatures is what allows you to choose who to trust instead of blindly trusting a vendor. If you trust a consumer association and they have signed off on some regulators. Then you can trust that those regulators are doing their job. And if those regulators signed off on a vendor, then you can trust that the vendor is doing the right thing.

> it is the usual ending of let’s trust the vendor initiatives

Which is better than "let's trust the vendor and trust that no random person is going to change the box".

Images are a false simplification

Posted Nov 5, 2025 22:17 UTC (Wed) by ebee_matteo (guest, #165284) [Link] (4 responses)

> It provides authenticity too, as the point being made was about signed dm-verity images. The signature is verified by the kernel keyring, so both authenticity and integrity are covered.

Yes, authenticity against a digital signature.

But trust has to start somewhere. You need to trust the signing keys, or somebody that transitively approved the key, e.g. as a CA.

In other words, you can prove an image was signed against a key, but if I manage to convince you to trust my public key, I can still run malicious software on your machine.

I still haven't seen the problem of supply-chain attacks being solved (by anybody, regardless of the technology employed).

Images are a false simplification

Posted Nov 5, 2025 22:23 UTC (Wed) by bluca (subscriber, #118303) [Link] (3 responses)

> But trust has to start somewhere.

Yes, and this is a solved problem on x86-64: you trust the vendor who sold you your CPU. You have to anyway, since it's your CPU, and it's silly to pretend otherwise.
That CPU verifies the firmware signature, which verifies the bootloader signature, which verifies the UKI signature, which verifies the dm-verity signature.

Images are a false simplification

Posted Nov 6, 2025 1:32 UTC (Thu) by Nahor (subscriber, #51583) [Link] (2 responses)

> this is a solved problem on x86-64

Not really. It's more like it is an unsolvable problem (or at least impractical to do so) so we choose to stop there.

> you trust the vendor who sold you your CPU

Plenty of people will argue you can't ("blabla manufacturing blabla China blabla" and "blabla NSA blabla backdoor blabla")

Images are a false simplification

Posted Nov 6, 2025 2:46 UTC (Thu) by intelfx (subscriber, #130118) [Link] (1 responses)

> Plenty of people will argue you can't ("blabla manufacturing blabla China blabla" and "blabla NSA blabla backdoor blabla")

That's the point of the GP, which I believe you have missed.

If you don't trust your CPU vendor enough to believe that their root of trust implementation is not subverted by your malicious actor of choice, then why would you trust *anything* that comes out of that CPU against the same malicious actor? The only logical choice of action would be to throw the CPU away immediately.

And if you haven't done that, then it necessarily follows that you *do* trust the CPU vendor, so it's fine if they implement a root of trust too.

Images are a false simplification

Posted Nov 6, 2025 10:29 UTC (Thu) by excors (subscriber, #95769) [Link]

I think there are subtly different definitions of "trust". In normal English it means "I believe this person won't harm me", but in a computer security context it often means "I am allowing this person to harm me". Under the first definition, it's best if you can correctly trust as many people as possible. Under the second, it's best to trust as few as possible.

Ideally the people you trust under the second definition are also trusted under the first definition, but in practice you can rarely have that level of belief in anyone, so you're knowingly opening yourself up to some risk of harm.

You can't prevent your CPU vendor harming you, so you do trust them under the second definition. The best you can do is minimise risk by ensuring they're the only people who can harm you.

Images are a false simplification

Posted Nov 6, 2025 8:10 UTC (Thu) by taladar (subscriber, #68407) [Link] (17 responses)

On the other hand images are one step further away from the actual source of the code (as in the dev team, not the files with the lines) which means there is one more layer that knows and cares less about the details, one more layer to be outdated and more layer you have to penetrate to figure out which open security issues exist and one more layer you need to rebuild once a security issue is fixed.

Images have quite frankly left me totally unconvinced that those who build them do actually care about security issues enough to even check for open issues, much less rebuild them every single time one gets fixed.

What good is having the authentic image if the image contains a mere few hundred open security holes of various (but not just low) severity?

Images are a false simplification

Posted Nov 6, 2025 18:09 UTC (Thu) by dottedmag (subscriber, #18590) [Link] (15 responses)

This is only true if the authors are still throwing the code over the wall and tell others "package it in any way you want to", which is kinda quaint.

Images are a false simplification

Posted Nov 7, 2025 8:48 UTC (Fri) by taladar (subscriber, #68407) [Link] (14 responses)

More common these days seems to be "This is our official Docker image, it is the absolutely only way we support and we don't care about any incompatibilities with dependency versions we do not use in there. No, we do not update the image for any security holes in the underlying base image and indeed keep using the same vulnerable dependencies for years at a time."

Images are a false simplification

Posted Nov 7, 2025 14:05 UTC (Fri) by dottedmag (subscriber, #18590) [Link] (13 responses)

Saying "we support this image" and "we don't care about (exploitable) security holes in the base image" is a contradiction. Stay away from these authors, I guess, the don't know what does the word "support" mean?

Images are a false simplification

Posted Nov 7, 2025 14:43 UTC (Fri) by pizza (subscriber, #46) [Link] (12 responses)

> Stay away from these authors, I guess, the don't know what does the word "support" mean?

It means "if you don't use the image we provide, we will send your problem reports/etc to /dev/null."

They make no promises about anything other than the software *they* write, in the manner *they* distribute.

...and that's okay. It's not like they owe any of us anything, after all.

Images are a false simplification

Posted Nov 7, 2025 14:59 UTC (Fri) by dottedmag (subscriber, #18590) [Link] (11 responses)

> They make no promises about anything other than the software *they* write, in the manner *they* distribute.

That's why I say "stay away" — this is a very misguided position.

There are two internally consistent positions: distribute blueprints (a.k.a. source code) and accept bug reports about software produced using these blueprints; distribute software (a.k.a. built software/images) and accept reports about functioning of the distributed artifact.

So yes, they don't owe anything, but it's a very good symptom that the authors are not very well versed in systems engineering (as defined by INCOSE).

Images are a false simplification

Posted Nov 7, 2025 15:10 UTC (Fri) by pizza (subscriber, #46) [Link] (10 responses)

> So yes, they don't owe anything, but it's a very good symptom that the authors are not very well versed in systems engineering (as defined by INCOSE).

...If you want folks to have "professional standards" then you need to be willing to pay them as such.

There is no middle ground here.

Images are a false simplification

Posted Nov 7, 2025 15:31 UTC (Fri) by dottedmag (subscriber, #18590) [Link] (9 responses)

I'm not talking about standards or certification, I'm talking about knowledge.

Also I'm not saying "put pressure on authors to clean up their act", that's plain wrong, I'm saying "be aware, authors' knowledge in at least some areas related to software engineering is very limited".

Personally, if I had to use a piece of software with the stated support policy in any project of consequence, I'd have to submit it to a detailed security audit.

Images are a false simplification

Posted Nov 7, 2025 16:10 UTC (Fri) by pizza (subscriber, #46) [Link] (8 responses)

> I'm saying "be aware, authors' knowledge in at least some areas related to software engineering is very limited".

That doesn't follow. Their [un]willingness to adhere to "best practices of software engineering" does not mean they lack knowledge -- the far more likely explanation is that they are not willing (or able) to undertake the extra (on an ongoing basis) workload without some sort of compensation.

Images are a false simplification

Posted Nov 7, 2025 16:26 UTC (Fri) by farnz (subscriber, #17727) [Link] (7 responses)

In turn, that means it's reasonable to avoid their work product if they're not willing to do the work you want them to do.

You have no right to demand that they do the work; at best, you can ask nicely and see if they'd come to a mutually agreeable arrangement to do the work, but they have no right to demand that you use their software.

However, they have no right to insist that you use their work product, either; it may inconvenience you to not use it, but you can always find or make an alternative that does meet your standards.

Note that regulation can change this balance (e.g. by requiring them to meet certain standards if conditions are met), but that's the default position absent a specific regulation.

Images are a false simplification

Posted Nov 7, 2025 17:12 UTC (Fri) by pizza (subscriber, #46) [Link] (6 responses)

> However, they have no right to insist that you use their work product, either; it may inconvenience you to not use it, but you can always find or make an alternative that does meet your standards.

I'm reminded of this essay:

https://caddy.community/t/the-realities-of-being-a-foss-m...

"I do find it ironic that the open source community is so irate about having to compile software from source to customize it the way they want."

Best parts of the Caddy essay

Posted Nov 7, 2025 23:18 UTC (Fri) by farnz (subscriber, #17727) [Link] (5 responses)

The entitlement section of that essay is significant, and the following (from the "Emotional Manipulation" section) is probably the most significant quote you can pull from the essay:
Here’s the brutal truth for 99.9% (* not an actual figure) of open source projects, folks: you (the user of an open source project) need and rely on the project more than the maintainers do.

Best parts of the Caddy essay

Posted Nov 8, 2025 7:02 UTC (Sat) by dottedmag (subscriber, #18590) [Link] (4 responses)

Is it? I personally find it puzzling that "let's make maintainers do something" argument even came up in this thread, I thought it's all discussed and agreed long time ago that authors owe nothing to whoever uses their product (heck, this is written on the can from the very beginning).

I understand some people may be burned by it and see it in every shadow, but read again and you'll see nobody proposed pushing authors to do anything.

Best parts of the Caddy essay

Posted Nov 9, 2025 13:22 UTC (Sun) by farnz (subscriber, #17727) [Link] (3 responses)

I think it is, because the reply to you that triggered this subthread amounts to "upstream owes me support for their code in a form I'm willing to accept", just phrased differently.

And this is a problem because it implies that the comment author has internalised the idea that "open source" means "free labour", even if they wouldn't ever claim that consciously - and even if they'd fight back at the idea that open source maintainers owe them anything.

Best parts of the Caddy essay

Posted Nov 11, 2025 16:08 UTC (Tue) by nye (guest, #51576) [Link] (2 responses)

> I think it is, because the reply to you that triggered this subthread amounts to "upstream owes me support for their code in a form I'm willing to accept", just phrased differently.

I really don't agree that "stay away from X" is another way of phrasing "X owes me support".

Best parts of the Caddy essay

Posted Nov 11, 2025 16:13 UTC (Tue) by dottedmag (subscriber, #18590) [Link] (1 responses)

Of course. Because it is not.

Come on people, what the hell is wrong with the community that "open source authors owe me anything" comes up in every discussion that has nothing to do with it? Is it really that bad nowadays? My last experience leading open source project was in 2010, has the scene changed that dramatically that everyone is now burned out?

Best parts of the Caddy essay

Posted Nov 11, 2025 17:21 UTC (Tue) by pizza (subscriber, #46) [Link]

> Is it really that bad nowadays? My last experience leading open source project was in 2010, has the scene changed that dramatically that everyone is now burned out?

In a word... yes. And also yes.

Images are a false simplification

Posted Nov 7, 2025 6:00 UTC (Fri) by raven667 (subscriber, #5198) [Link]

Honestly there is a tradeoff here and in many cases I'd prefer an app that works stably, reliably, but uses an out-of-date runtime than one which is always glitchy because the runtime is changing around it constantly and there aren't enough maintenance resources to keep up. In many cases the risk of someone compromising me through that app because of its insecure runtime is far far less than the risk of me yeeting the computer through a window because the app doesn't do what I need it to do.

Security of the web browser and any services on the network interface are paramount, those get exposed to a lot of unsolicited badness, but the risk of me opening a maliciously crafted file that gains a foothold because it targets a vulnerability in an of an out-of-date library dependency in a poorly maintained app I run has is way way less, even if technically possible.

SELinux and containers are complementary

Posted Nov 6, 2025 7:54 UTC (Thu) by tomf (subscriber, #113110) [Link] (7 responses)

> But that is not how many of Linux's security mechanisms are built. SELinux, for instance, requires a specific policy for each daemon. Then, one might write the policy that forbids that daemon from creating device nodes. But that is much more fragile and difficult to maintain, he said. "It's much easier figuring out universal truths and enforcing them system-wide". To do that, components should be isolated into separate worlds.

I'm reminded of maybe a Dan Walsh quote in which he says SELinux policy complexity reflects an underlying oversharing, and that the SELinux policy files for containers are simple precisely because containers define separate worlds.

Meanwhile, SELinux has prevented some container escapes. So I think of containers and SELinux as being complementary.

I see the author also wrote https://www.redhat.com/en/blog/selinux-mitigates-containe... :)

SELinux and containers are complementary

Posted Nov 6, 2025 7:59 UTC (Thu) by Cyberax (✭ supporter ✭, #52523) [Link] (6 responses)

SELinux policy reflects the inherently wrong approach it takes to security. It starts with a simple idea that you just need to be able to compare the label lists. It can be formally analyzed (it's just set operations after all).

But then it turns out that you need to be able to label everything. And propagate the labels. And then have escape hatches from all of that. So pretty much every complex Linux installation ends up with disabled SELinux, some vendors don't even bother with it. Amazon ships their Amazon Linux with SELinux disabled by default.

AppArmor offers comparable security but much simpler policies. Yet it has never gained any traction because it's not complex enough, apparently.

Complex means vulnerable

Posted Nov 6, 2025 18:32 UTC (Thu) by marcH (subscriber, #57642) [Link] (1 responses)

Vulnerabilities and bugs in general exist only thanks to complexity. There is a direct connection between complexity and bugs, every engineer sees that connection everyday. Bugs need complexity to escape code reviews, static analyzers and our limited brains.

That's why our entire field relies on abstractions: to divide and conquer into smaller bits that we can comprehend and reason about. Otherwise nothing would work at all.

So, the idea that you can make a complex system more secure by labeling and micro-managing everything and adding another layer of "complex security" on top is insane. At best, it's wasting a lot of time. At worst, it's also giving a false feeling of security.

It's not just SELinux. In a former life, I spend days trying to make sense of the apparently simpler NTFS permissions and adjust them for some not very particular use case. I eventually gave up. I bet most people don't have days for something like this.

Complexity in "security features" is in a generally much worse state than complexity in regular features because you cannot sell the former and you almost never get rewarded for getting it right. So it gets even less attention.

Anytime you see some complex security system, assume it's misused and misconfigured greatly.

Complex means vulnerable

Posted Nov 7, 2025 8:52 UTC (Fri) by taladar (subscriber, #68407) [Link]

Very true. In my experience almost every time a permission system or similar feature is created it is made orders of magnitude too complicated for most users anyway because of some theoretical case someone who never uses the system imagines during development or specification. Years later, 99.9% of all installations of the system only use the simplest 10% of that complexity but there are just enough complex cases in the existing production data that you can't migrate to a simpler system easily.

SELinux and containers are complementary

Posted Nov 7, 2025 9:13 UTC (Fri) by emmi3 (subscriber, #62443) [Link] (3 responses)

> So pretty much every complex Linux installation ends up with disabled SELinux, some vendors don't even bother with it.

I must object this claim. In my experience RedHat, CentOS and Fedora come with extensive and very usable SELinux policies.

None of our ~20 RH/COS servers has any of it disabled. Sure, if you deploy your own software, it takes some time to get everything right and it can at times be very frustrating to debug (especially if you forget about the 'dontaudit' thing). But in the end the docs are very good and we got every single service running and secured: Overleaf, Collabora, Dokuwiki, Openproject, NFS, Samba. SELinux is one of the main reasons why we choose RH/COS over Debian for our internet facing servers (the other being more stable Ceph support).

On the desktop I only had to fiddle once with SELinux on Fedora on our convertible laptop: After an upgrade the DE could not access the orientation/tilt sensor any more to rotate the screen as needed. This was easy to discover and fix.

But as always: YMMV. Using SELinux in unusual environments requires some work (possibly from an already overworked admin). But I still think it's worth it.

SELinux and containers are complementary

Posted Nov 7, 2025 19:37 UTC (Fri) by marcH (subscriber, #57642) [Link] (1 responses)

> In my experience RedHat, CentOS and Fedora come with extensive and very usable SELinux policies. None of our ~20 RH/COS servers has any of it disabled.

Just "usable" or actually adding security? Has some corresponding penetration testing been performed, are the reports available somewhere? Is there any other evidence that threats were blocked? Are you reviewing all policy changes for errors, malicious or not? That must be a lot of work!

> Sure, if you deploy your own software, it takes some time to get everything right and it can at times be very frustrating to debug (especially if you forget about the 'dontaudit' thing).

Which means 100 times more work for your entire Linux distribution than for just your own apps. So do you know who did that huge amount of work, who maintains it and how and how much you can trust them? Don't get me wrong: you need to trust your Linux distribution anyway. But was SELinux really the best use of their limited security time?

> But in the end the docs are very good and we got every single service running and secured

SELinux: check!

Too bad security is not just a collection of checkboxes. It requires actually looking at what's behind the checkboxes. So how did your SELinux penetration testing go? What is your change review process? What is the ratio between the SELinux security value you get (hard to measure, I know) and the effort you put there and how does that ratio compare to other security measures you take?

SELinux and containers are complementary

Posted Nov 7, 2025 21:05 UTC (Fri) by ballombe (subscriber, #9523) [Link]

Now there is a library to adapt selinux policy...
<https://arstechnica.com/gadgets/2025/11/commercial-spywar...>

SELinux and containers are complementary

Posted Nov 7, 2025 21:29 UTC (Fri) by Cyberax (✭ supporter ✭, #52523) [Link]

> I must object this claim. In my experience RedHat, CentOS and Fedora come with extensive and very usable SELinux policies.

For the default installation. They also don't _always_ work, and then you're stuck debugging the label hell. So people just give up and disable SELinux.

I claim that at this point SELinux doesn't provide more in practice than just using namespaces (containers) after dropping extra privileges.

How would file system being only writable or only executable work in practice?

Posted Nov 6, 2025 12:12 UTC (Thu) by gray_-_wolf (subscriber, #131074) [Link] (10 responses)

> A filesystems should be mounted writable so that its contents can be modified, or it should be mounted as executable so that binaries could be run from it. But a filesystem should never be both. If that were implemented through the whole system, he said, it would be much more secure.

So, uh, how is this supposed to work in practice? I want to install program into /opt/PROG, using `make install'. So I first need to switch /opt to be writable. (Well, first I need to make it into a separate file system.) Ok, now I can install my program. And after I am done, I need to re-mount the /opt into executable mode. And then I will need to go through the installed files and decide which needs to be executable and which writable. Since /opt/PROG/bin needs to be executable, but /opt/PROG/etc needs to be writable.

This does not seem very... ergonomic.

Related question, is there an upper limit on number of mounts? Quick `find' across my file system suggests I would need around 10k of them currently (but I did a clean up fairly recently).

How would file system being only writable or only executable work in practice?

Posted Nov 6, 2025 12:56 UTC (Thu) by bluca (subscriber, #118303) [Link]

How would file system being only writable or only executable work in practice?

Posted Nov 6, 2025 16:12 UTC (Thu) by raven667 (subscriber, #5198) [Link] (6 responses)

> So, uh, how is this supposed to work in practice? I want to install program into /opt/PROG, using `make install'.

Clearly not like that.

This design is predicated on systems being shipped as full filesystem images with merged /usr so there is a clear separation between mutable /etc and /var and immutable /usr, so if you aren't familiar with these systems (like Fedora Silverblue or Bazzite) then maybe this seems insane to you. Someone else already pointed out the sysext and confext as a way to package overlay images to extend the base system and containers as a way to run arbitrary apps/services, so the `make install` would happen in a container build process and that's where you'd install your special thing. This is a different style of packaging and system management than the world of `/opt`, `/usr/local` and `make install` so you have to understand the worldview to understand the proposal.

I can never tell when a response like that which fails to consider that other parts of the system can be changed is bad faith (does the OP genuinely believe that 10,000 mounts is what is being proposed? or is that just an affectation for the sake of argument?) or a genuine misunderstanding of the proposal/possibilities.

How would file system being only writable or only executable work in practice?

Posted Nov 6, 2025 17:09 UTC (Thu) by IanKelling (subscriber, #89418) [Link] (1 responses)

> Clearly not like that.
>
> This design is predicated on systems being shipped

I get it! Delegate every realistic security risk to be run on a different machine, then go give talks as if this gimped machine is the only one which exists and is super amazing and secure. (a bit of sarcasm here)

How would file system being only writable or only executable work in practice?

Posted Nov 6, 2025 22:22 UTC (Thu) by marcH (subscriber, #57642) [Link]

> I get it! Delegate every realistic security risk to be run on a different machine, then go give talks as if this gimped machine is the only one which exists and is super amazing and secure. (a bit of sarcasm here)

Maybe this has too many layers for me to understand the irony but yes: development systems are much less secure than production systems. That's why there's a lot of code reviews, testing, QA and other processes gating the latter from the former.

How would file system being only writable or only executable work in practice?

Posted Nov 6, 2025 17:16 UTC (Thu) by gray_-_wolf (subscriber, #131074) [Link] (3 responses)

> This is a different style of packaging and system management than the world of `/opt`, `/usr/local` and `make install` so you have to understand the worldview to understand the proposal.

Hm, sure. I can see this approach working just fine on my Steamdeck for example. However I am not sure how to incorporate it into a general purpose computing system (e.g., How do I even run `make check' if VPATH cannot be writable and executable at the same time?). It just seems extremely painful, so I was curious about how people actually use systems where everything is either writable or executable.

> does the OP genuinely believe that 10,000 mounts is what is being proposed

I do not believe it is specifically being proposed, no. I was -- in the spirit of "other parts of the system can be changed" -- just thinking about how to approach this in GNU Guix / NixOS, where each package is installed into a separate directory under /{gnu,nix}/store. Each package would likely require 1 or more mounts, so I was curious whether there is a practical limit under Linux.

How would file system being only writable or only executable work in practice?

Posted Nov 6, 2025 18:21 UTC (Thu) by NYKevin (subscriber, #129325) [Link]

For local development, of arbitrary projects, it will probably never be feasible to have a fully write-xor-execute filesystem. But we can get partway there:

* A lot of users are not interested in local development, and just want to install and run applications that somebody else wrote. They can ignore this problem.
* If we are doing local development and need a writable executable filesystem, we can at least narrow the scope of that to $HOME or possibly even something more specific like the project directory.
* If we are using something like Bazel, we may be able to go further and actually have a write-xor-execute filesystem, because Bazel already requires you to pervasively describe the inputs and outputs of all parts of the build process, and already uses build sandboxing to enforce correctness. So it knows exactly which files need to be "blessed" or transferred into some immutable-and-executable location, and it even knows when this "blessing" operation needs to happen for correct build sequencing. I'm not sure if it actually has the functionality to do this, but I imagine it can be added if it is not already there.

Disclaimer: I work for Google and use the internal equivalent of Bazel all the time, but I have not studied its sandboxing functionality in detail.

How would file system being only writable or only executable work in practice?

Posted Nov 7, 2025 5:47 UTC (Fri) by raven667 (subscriber, #5198) [Link]

> I can see this approach working just fine on my Steamdeck for example. However I am not sure how to incorporate it into a general purpose computing system

This style of system won't be appropriate for every kind of use case, but I think we should try and push this style of system to see how far it can go, because I think it can work for a lot of uses and can be much more reliable and simple to reason about. Only a fraction of computer use is developing binary software, most is editing data files which this kind of system design can already handle fully. Even development in languages which don't compile to binary executables would work fine.

For compiled binary software carving out a portal to a read+execute subdirectory accessible from a container, which may have a limited view of the system outside of its own runtime and the directory for development. Having read+execute access to a small part of the system in a controlled way is still a win when the rest of the system can't be compromised and the blast radius of any badness is small and manageable.

I've been using Silverblue for my day job (and just switched to Bazzite at home for my gaming system) and the immutable image-based systems are different, but not bad. It's nice to know that there is a solid base underneath my work that I can't accidentally crud up with changes and experiments I forgot making. Flatpak has been a joy (although a few nits to pick, slow startup time for simple apps is one), but I still target my development to RPMs on traditionally-managed servers, so I don't know how painful translating that to OCI containers would be, although I think building a container using traditional OS distribution packaging tools makes sense, those were developed in response to `make install` style system management and provide useful frameworks to manage that complexity.

How would file system being only writable or only executable work in practice?

Posted Nov 7, 2025 11:23 UTC (Fri) by farnz (subscriber, #17727) [Link]

One component of making this usable is exploiting containerization. You have a "project A developer container", which has a filesystem that's both writable and executable, and once "project A" is ready to deploy, you build a "project A production container" which is either writable or executable but not both.

Then, you deploy the production container (possibly on the same machine as the developer container) for normal use; you don't use the developer container except for development. This extra stage is overhead, but it reduces the attack surface, since the container you use in normal use (the production container) doesn't have a writable filesystem, and ideally has a more restrictive sandboxing policy applied than the developer container (which has to have fewer restrictions so that you can actually do work).

How would file system being only writable or only executable work in practice?

Posted Nov 6, 2025 22:16 UTC (Thu) by marcH (subscriber, #57642) [Link] (1 responses)

How would file system being only writable or only executable work in practice?

Posted Nov 7, 2025 5:51 UTC (Fri) by raven667 (subscriber, #5198) [Link]

Yeah, there is that too, for development workstations you need a different security policy than workstations just editing data, although even in that case adding a local key to the Secure Boot process using mokutil is not that hard, necessary if you want to use akmods to build out-of-tree stuff like the nVidia driver, but something that I've done several times just by following the directions.

Socket passing as capabilities

Posted Nov 7, 2025 17:08 UTC (Fri) by MrWim (subscriber, #47432) [Link]

Something I appreciate about systemd is socket passing. Having init open the listening socket and passing it into the service feels like using a proper capability system. You get the guarantee that the service listening on port x is the one you expect, and the service itself needn't have network access at all (`PrivateNetwork=true`). It's secure and I find it easy to reason about (unlike iptables, etc.).

Unfortunately still many daemons still don't support it. I suspect this may be due to docker not supporting it - and that being the predominant deployment method these days - even though it seems like a natural fit for containerisation.

How about minimizing the attack surface

Posted Nov 7, 2025 17:11 UTC (Fri) by rbranco (subscriber, #129813) [Link]

https://security.opensuse.org/2025/10/01/summer-spotlight...

> Increase in Complexity in systemd

> With this version of systemd we are seeing a noticeable increase in complexity in the implementation of a number of systemd components. In the area of container management the complexity is pretty much by design, given the intricacy of the different namespace mechanisms playing together, partly under the control of unprivileged users. There is also the addition of Varlink for Inter-Process-Communication, however, which means that two different interfaces for D-Bus and Varlink now exist in parallel for some services. This is also the case for systemd-machined.

> While the D-Bus and Varlink interfaces usually call into shared functions for most of the business logic and share the same Polkit actions, there is necessarily a certain amount of redundancy in parsing and evaluation of input parameters. As a result this also increases the burden on code reviewers which now need to keep track of two different entry paths to the same logic.

> We are not yet completely finished with reviewing all notable changes in systemd v258 but intend to complete the effort within the next couple of weeks. We are happy that our review efforts already prevented a local root exploit in software as widespread as systemd from ending up in production environments.

Known as problematic for a long time

Posted Nov 8, 2025 13:57 UTC (Sat) by fraetor (subscriber, #161147) [Link]

Reading the "Worlds apart" section, I'm reminded of the ponderings on the hierarchical namespace of the filesystem and the vulgarities of the Unix permission system in the Ghosts of Unix Past series of articles from 2010. Its well worth a read.

Part 1: Full exploitation - https://lwn.net/Articles/411845/
Part 2: Conflated designs - https://lwn.net/Articles/412131/
Part 3: Unfixable designs - https://lwn.net/Articles/414618/
Part 4: High-maintenance designs - https://lwn.net/Articles/416494/


Copyright © 2025, Eklektix, Inc.
This article may be redistributed under the terms of the Creative Commons CC BY-SA 4.0 license
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds