Course contentsShow
← Security
Lesson 1450 of 3,05229. Operating System Security - HardeningFree lesson

MAC vs DAC: Fundamental Differences

Compare Mandatory Access Control with Discretionary Access Control and understand when MAC is necessary.

MAC vs DAC: Fundamental Differences

You'll learn: The core distinction between Mandatory Access Control (MAC) and Discretionary Access Control (DAC), and when each security model is appropriate.

Two Approaches to Access Control

Up to now, you've been working with Discretionary Access Control (DAC)—the standard model where file owners decide who can access their resources. When you run chmod or set permissions on a file, you're using DAC. It's "discretionary" because the owner has discretion over access.

Mandatory Access Control (MAC) flips this paradigm: the system enforces security policies that users cannot override. Even if you own a file, MAC policies can prevent you from changing its security label or granting access to others. Think of it like this: DAC is asking permission from the homeowner; MAC is requiring government clearance regardless of what the homeowner wants.

Key Differences

AspectDACMAC
ControlOwner decidesSystem policy decides
FlexibilityHigh—users can share freelyLow—rigid rules
Trust modelTrusts users to make decisionsAssumes users may be compromised
Bypass riskUsers can accidentally oversharePolicy violations impossible

When MAC Is Necessary

MAC becomes critical when:

  • Regulatory requirements demand provable access control (defense, healthcare)
  • Multi-level security is needed (Top Secret, Secret, Unclassified data on same system)
  • Protection from compromised users is essential—even root can't violate MAC policies
  • Containment is required—processes must be confined regardless of user actions

Key Takeaway: DAC trusts owners to protect their data; MAC enforces system-wide mandatory policies that no user—not even administrators—can bypass. Choose MAC when regulatory compliance, defense-in-depth, or protection from insider threats outweighs operational flexibility.