Skip to main content

Auth for ASP.NET Cores

Authentication and authorisation in ASP.NET Core are two separate steps. Authentication establishes who the caller is, using cookies, JWT bearer tokens or an external provider such as OpenID Connect, and authorisation decides what they may do through roles, claims and policies applied to endpoints.

Stage: Security · Part of the ASP.NET Core roadmap · Last reviewed 19 November 2026

What to learn in Auth

Auth interview questions

What is the difference between authentication and authorization?

Authentication verifies identity, such as checking a password or validating a token. Authorization decides whether that identity may perform an action, such as reading a resource. In ASP.NET Core they are separate middleware, and authentication must run first so authorization has a user to evaluate.

What does policy-based authorization offer over roles?

A policy bundles one or more requirements, such as a claim value, minimum age or custom handler logic, under a name. It expresses rules more flexibly than fixed role names and lets a handler load resources to decide, for example whether a user owns a document.

Where Auth fits in the ASP.NET Core roadmap

Auth belongs to the Security stage (intermediate level), which takes about 21 hours. Protect it.

Back to the full ASP.NET Core roadmap