Systemd's DynamicUser feature is currently dangerous
Since something&#x27;s probably going to be said eventually, I&#x27;ll do it this time.<p>&gt; <i>...how timesyncd is supposed to get access through an inaccessible directory. I&#x27;ll quote the explanation for that:</i><p>&gt; &gt; <i>[Access through &#x2F;var&#x2F;lib&#x2F;private] is achieved by invoking the service process in a slightly modified mount name-space: it will see most of the file hierarchy the same way as everything else on the system ([...]), except for &#x2F;var&#x2F;lib&#x2F;private, which is over-mounted with a read-only tmpfs file system instance, with a slightly more liberal access mode permitting the service read access. [...]</i><p>Reading this, I didn&#x27;t quite <i>completely</i> facepalm, but...<p>This solution - the high-level general architecture&#x2F;approach; the ideas used - is, IMO, frankly insane.<p>It means your running system&#x27;s state can no longer be easily and straightforwardly reasoned about: no longer can you run a few commands and get a high level idea of what&#x27;s configured (with respect to filesystems) and how everything&#x27;s set up, see what files are where, and immediately know what a given file&#x27;s permissions are.<p>Instead, it seems you&#x27;re now being expected to consider any arbitrary, given filesystem path you&#x27;re puzzling over from the perspective of every FS namespace as viewed by each process (to be clear, this means every file * every namespace * every process). No sysadmin&#x2F;devops type is going to do that; it&#x27;s not sustainable.<p>This architecture is bizarre enough that few tools will be built to do adequate introspection unless developers (<i>glares at one in particular</i>) actually extend and build on this further and additional even more wonderful breakage happens as a result, meaning that the tools <i>must</i> be created in order to keep systems manageable. Hopefully things don&#x27;t get that bad? - but in the meantime said tools don&#x27;t exist, so people get to to reverse-engineer PID 1 (<i>AHEM</i>) the Fun™ way, and keep all the half-square, half-circle pieces they discover along the way.<p>Looking further afield, I&#x27;m more hesitant about the future of Linux as a viable trustworthy platform to have confidence in. I say that both from the perspective of straightforward enjoyable maintenance (which Linux is already struggling with) and from the perspective of <i>reasonably</i> consistent and surprise-free mental modelling to aid security best practice. UNIX was based on the idea of &quot;everything&#x27;s a file&quot;. Not, IMHO, the best&#x2F;most efficient model; but okay. This... this blows that model out the window, because suddenly we have architectural interestingness being built on building blocks that exceed the scope of the original file model (look at a file, see the permissions of that file), <i>but without pivoting&#x2F;extending the basic building blocks of the system to incorporate the new models</i>. Linux is still known as a UNIX clone, and the UNIX standards (&quot;everything&#x27;s a file&quot; being fundamental) hasn&#x27;t changed anytime recently, so this is... not <i>dishonest</i>, but definitely a potential source for a lot of confusion. And kind of technically dishonest.<p>Furthermore, there&#x27;s no defined direction for this new... standard? that seems to be appearing. I can&#x27;t effectively model this seemingly byzantine architecture; I can&#x27;t intuit landmarks or similarities from other systems (although I&#x27;ll admit I&#x27;ve only used Linux, Windows and DOS).<p>I do understand mount, PID and network namespacing. These concepts are not that difficult to reason about, in isolation. But they can be combined in very very unintuitive ways that make state analysis very difficult, and what I&#x27;m trying to express here is that I don&#x27;t consider the architecture presented to be intuitive, easy to debug, or effective. (I never envisaged namespacing being used like this, of course.) Perhaps it was the simplest solution, in isolation, but it doesn&#x27;t feel well-designed or thought through (with respect to sane diagnostics and transparent low-level housekeeping).<p>Part of my freakout is that the tools available to examine namespaces are very target-specific; they don&#x27;t consider the system as a whole. The question is whether the developers (<i>briefly resumes glaring</i>) nearest the namespace bits would be willing to maintain tools to help introspect at a holstic level. That may be needed soon.<p>I guess the other part is that it feels Linux is getting really complicated. I <i>think</i>, based on my understanding of psychology, that this may be because I&#x27;ve been using Linux for a few years now (a decade or so), and my usage of it has perhaps become ingrained and rusted in place. Maybe so. But I do also wonder if the bazaar has scaled to the point where nobody can keep track of all the pieces as they move forward.