Book Image

ASP.NET Core Essentials

By : Shahed Chowdhuri
Book Image

ASP.NET Core Essentials

By: Shahed Chowdhuri

Overview of this book

<p>ASP.NET Core is the latest collection of Microsoft’s web application development technologies. When you’re trying to reach a broad spectrum of users with a robust web application, ASP.NET Core is there to help you build that application. With the ability to cater to users on desktop, tablet, or smartphone platforms, you can put together a solution that works well anywhere.</p> <p>This book is what you need to get started developing ASP.NET Core applications was quickly as possible; starting by introducing the software and how it can be used in today’s modern world of web applications and smartphone apps. Walking you through the benefits of a Web API to support both applications and mobile apps to give you a solid understanding of the tech to build upon as you see what ASP.NET Core can do for you.</p> <p>The book wraps up with practical guidelines for the use of database technologies, unit tests, security best practices, and cloud deployments for the real world.</p>
Table of Contents (15 chapters)
ASP.NET Core Essentials
Credits
About the Author
About the Reviewer
www.PacktPub.com
Preface

Enabling authentication in ASP.NET


You may be pleased to hear that ASP.NET Core includes built-in authentication methods in its web template. In fact, creating the sample projects mentioned in previous chapters will result in a functioning web application with authentication included. If you start a brand new project, this section will also help you identify what you need to do to include authentication.

High-level overview

Here is a high-level overview of how you can enable authentication in a new ASP.NET Core application using the web template:

  1. Create a new project with a web template.

  2. Select the authentication method.

  3. Verify the packages and references.

  4. Verify the code in the Startup.cs class.

  5. Add additional identity options as needed.

  6. Add external providers as needed.

If you want to start with an empty project, you can perform the following steps:

  1. Create a new empty web project.

  2. Do not select an authentication method.

  3. Add packages and references for authentication.

  4. Add code to the Startup.cs class...