thinQmaster Virtual testing partner Adaptive practice exams that find your weak spots and drill them. Every answer explained. From $69
Enroll

thinQmaster

Find your exam

Five questions free, before you decide.

Step 1 · choose a vendor

In one of our camps? Your practice exams come with the tuition — they are on your study page already.

Systems & Data Center · Advanced

SELinux Context

The security label (user:role:type:level) attached to every file, process and port that SELinux uses for access decisions.

Definition

Type enforcement is the key field; for example, httpd_t processes may read httpd_sys_content_t files. Contexts are viewed with ls -Z and ps -Z, and persistent file context rules are defined with semanage fcontext.

Example

ls -Z /var/www/html/index.html shows system_u:object_r:httpd_sys_content_t:s0.

Exam tip

Files moved with mv keep their old context, while files copied with cp get the destination's context, a common cause of denials.

Related terms