Backend Fundamentals · Who are you, and what may you do?
Authentication vs authorization
Authentication proves who is calling; authorization decides what they may do. Most access bugs are not broken logins but one missing check on one record.
- Time20 min
- LevelDeveloper
- Pictures10 diagrams
- Check6 questions







Browser sends
Her own order the same check on order 123 passes, so it is sent.
API gateway rejects requests with no valid credentials before they reach a service.
Middleware attaches the identity and enforces coarse role rules for every route.
Handler or policy function checks this caller against this record and this action.
Query filters by owner or tenant, so a missed check returns nothing.
Database row-level security a backstop that hides other tenants' rows.