Skip to content

Interview question · Systems, OS & Memory Safety

Discretionary versus mandatory access control: how do SELinux and AppArmor confine a process, and how do you handle a denial?

Everyone knows MAC is 'stricter'. The scored part is why a compromised root process can still be confined, how labels differ from paths, and what you do when the policy blocks production at 2am.

mediumEssentialNewPreparation tags: Google, Amazon, MicrosoftUpdated Nov 2026

Everyone knows MAC is 'stricter'. The scored part is why a compromised root process can still be confined, how labels differ from paths, and what you do when the policy blocks production at 2am.

Make your first attempt

What would you say before reading the answer?

  1. 01 State the assumptions your answer depends on.
  2. 02 Explain the mechanism and choose a control.
  3. 03 Name a condition that would change your decision.

The worked answer includes an approach, scoring criteria and follow-up questions. Compare the reasoning with your own.

signing in unlocks more free answers per topic

What if · the follow-ups in this answer

The answer works through 6 follow-ups like an interviewer would

A web server is compromised, but SELinux is enforcing on the host, and the team wants to know what that limited.

  1. What is discretionary access control?
  2. What does mandatory access control add?
  3. What did SELinux likely limit here?
  4. How does AppArmor differ?
  5. What weakens MAC in practice?
  6. How would you explain and use MAC?

Each rung has a nudge, a model answer, the principle that carries over and the weak answer to avoid. Sign in free to open it.

UP NEXT ON YOUR JOURNEY
DISCUSSION · 0

No comments yet. Share a correction or a different way to answer it.