liveBook · Manning

SELinux

As explained in Kubernetes in Action, Second Edition

SELinux is a Linux security mechanism that enforces mandatory access control through labels and policy rules.

SELinux (Security-Enhanced Linux) is a mandatory access control mechanism that strengthens container isolation. It attaches labels to files, system resources, users, and processes, then permits access only when those labels satisfy defined policies. section 2.3.4

SELinux controls access through:

  • Labels attached to subjects and objects, including users, processes, files, and system resources. section 2.3.4
  • Policies that determine whether the labels involved permit a requested access. section 2.3.4
  • Mandatory enforcement that adds protection beyond the isolation provided by namespaces and other container mechanisms. section 2.3.4 section 2.4

SELinux and AppArmor

Both SELinux and AppArmor strengthen operating-system and container security. SELinux uses labels and applies policies to users and processes; AppArmor uses file paths and focuses on processes. section 2.3.4

How Kubernetes in Action, Second Edition covers it

How deep it goes
Defines labels and policy matching, but stops short of showing policy authoring or operational configuration.
Examples
Contrasts SELinux labels and policies with AppArmor file paths and process-focused protection.
What it assumes
Assumes basic container-isolation concepts, especially namespaces, while introducing SELinux at a conceptual level.
What you can do after
Evaluate how label-based mandatory access control contributes to container and operating-system isolation.
How it connects
Connects SELinux with containers, namespaces, capabilities, seccomp, AppArmor, labels, and mandatory access control.

Also explained in

Compare how 2 books explain SELinux →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Kubernetes in Action, Second Edition. The section links point to the parts of the book it draws on.