Welcoming SELinux userspace 3.11: secilcheck for validating neverallow, restorecon -F in the foreground, new setfiles -A and -U options, modern Python support, and security fixes including CVE-2026-59676 and CVE-2026-59677.

After automating the whole policy lifecycle in episode 20, there's a fair question: where is SELinux heading next? The answer is in the latest userspace release. In this episode 21, we dissect SELinux userspace 3.11, released in July 2026 — new features directly useful for CI and daily operations, important security fixes, and the roadmap for the next release. This is also preparation before episode 22, the finale of this series, where we tie together all the story threads.
SELinux consists of two worlds: the kernel, which enforces decisions, and the userspace, which composes, loads, and manages the policy. Release 3.11 is the collection of userspace tools and libraries (libselinux, libsepol, policycoreutils, SETools, and others) that are the everyday language of admins. Because userspace releases run on roughly a yearly rhythm, 3.11 is the "annual fix package" you must install.
The most interesting feature for automation is secilcheck. Up until now, validating neverallow rules — rules that forbid certain access combinations — required a full policy with the source tree. secilcheck does that directly against the binary policy already installed:
secilcheck -c /etc/selinux/targeted/policy/policy.33 myapp.cilHow to read it: give -c for checking mode, the path to the binary policy, and the CIL file containing the neverallow rules you want to verify. If there's a violation, secilcheck reports it with a non-zero exit code — exactly what the CI pipeline from episode 20 needs.
Tip
This completes the policy-as-code workflow: besides make, which guarantees a module can be compiled, secilcheck guarantees the module doesn't violate established invariants. Turn it on in your CI from day one — a neverallow violation detected before deploy is far cheaper than one found when running semodule -i in production.
Every userspace release also brings security fixes, and 3.11 is no exception. Three areas worth noting:
Included among them are fixes for CVE-2026-59676 and CVE-2026-59677 (denial of service on seunshare) that you already know from episode 19. If you skipped the 3.10 to 3.11 upgrade for any reason, this is the strongest reason to do it now.
restorecon is the go-to tool for fixing labels. In 3.11, using -F becomes friendlier to scripting: the process runs in the foreground, so its exit code is reliable for automation. The function of -F itself stays the same: forcing a context reset even on files whose labels are already correct — useful when the policy changes and old labels no longer fit:
restorecon -F -Rv /var/www/myappfixfiles -F onbootA simple analogy: restorecon -R is like putting a new label sticker only on files whose sticker has come off; -F puts a new sticker on everything without asking whether the old sticker is still attached. For the "new policy, labels changed a lot" case, -F is the right choice.
setfiles is the high-performance relabel engine used by fixfiles and the boot process. Release 3.11 adds the -A and -U options for finer control in special scenarios:
-A — controls how labels are associated with file context specifications, useful when you're fixing labels from a rescue environment that doesn't yet have the full context.-U — sets the user mapping in contexts during the relabel process, relevant for systems with an MLS policy and many users.Its practical use in a recovery environment:
mount /dev/sda1 /mnt
setfiles -F -A -U system_u -r /mnt /etc/selinux/targeted/contexts/files/file_contextsImportant
setfiles is a system-level tool — calling it wrong can overwrite labels on the entire filesystem. Never run it without understanding -r (root path) and without a backup. For normal needs, restorecon -F -Rv is more than enough; setfiles is reserved for rare recovery cases.
For those of you automating SELinux through scripts, 3.11 brings good news: the tools and Python bindings now support modern Python versions (3.11 and up). This means SETools and other tooling can run on the latest distributions and pipelines without version hacks. The practical effect: the policy analysis scripts in CI from episode 20 won't be left behind by ever-rising Python versions.
SELinux is not a project that stops. The community-agreed roadmap covers three directions:
The release rhythm follows the habit: roughly once a year, with 3.12 expected in 2027. That means you don't need to anticipate surprising big changes — just make userspace upgrades part of routine maintenance, like kernel updates.
dnf update libselinux libsepol policycoreutils setools-consoleapt update && apt install --only-upgrade libselinux1 policycoreutils setoolsAfter the upgrade, verify that the policy is still valid and SELinux is still active:
sestatus
restorecon -Rv /etc /usr/sbinIn this episode 21, you've seen SELinux as a living project: userspace 3.11 brings secilcheck for neverallow validation in CI, scripting-friendly restorecon -F, the setfiles -A and -U options for recovery, modern Python support, and — not to be missed — security fixes including CVE-2026-59676 and CVE-2026-59677. The roadmap is clear: regular roughly-annual releases, active collaboration with the kernel, and 3.12 waiting in 2027.
Key points to take home:
secilcheck makes neverallow validation run in CI without the full policy source.restorecon -F -Rv is the answer for outdated labels; fixfiles -F onboot for a full relabel.setfiles is reserved for recovery; don't use it without understanding the risks.At this point, all the material is complete. In episode 22 — the finale of the Learn SELinux series — we'll compare SELinux with other security ecosystems, recap the whole journey from episode 0 to 21, and close with a production checklist and learning resources. See you there!