Serksa
All Concepts
Security

Authentication vs Authorization

1

What is it?

<strong>Authentication</strong> is proving who you are (like showing your ID), while <strong>Authorization</strong> is determining what you're allowed to do (like having a VIP pass). They work together but serve different purposes.

2

Think of it like...

The Airport Security Analogy

At the airport, you show your ID to prove who you are (authentication). Then your boarding pass determines if you can access first class or economy (authorization).

🎫

Ticket (Authentication)

Proves you're a passenger

🚪

Security Check

Verifies identity

✈️

Boarding Pass (Authorization)

Determines your seat class

3

Visual Flow

👤User

Provides Credentials

🔐Authentication

Verifies Identity

🎯Authorization

Grants Permissions

4

Where you see it

1

User provides credentials

Username and password submitted

2

Authentication verifies

System checks if credentials are valid

3

User is authenticated

System knows WHO you are

4

Authorization checks permissions

System checks WHAT you can access

5

Access granted or denied

Based on your role and permissions

5

Common Mistake

Wrong

"Authentication and authorization are the same thing"

Correct

<strong>Authentication</strong> answers 'Who are you?' while <strong>Authorization</strong> answers 'What can you do?'. You can be authenticated but not authorized for certain actions.

💡 Real-World Example

In a company system:

1

Authentication: You log in with your employee ID and password

2

Authorization: Your role (admin, manager, employee) determines access

3

Admin can delete users, manager can approve requests, employee can only view

4

You're authenticated as 'John', but authorized only for employee-level actions