Tutorials on ASP.NET Core, Blazor, jQuery, JavaScript, Entity Framework, Identity, WordPress, SQL, HTML & more


How to work with Policies in ASP.NET Core Identity

Last Updated: April 27, 2024

policies identity

ASP.NET Core Identity Policy is a collection of requirements a user must have for him to be authorized to access a resource on the app. Identity Policy based Authorization can contains additional requirements for Identity Roles and Claims for a user to have, and this helps us to build richer authorization structures in our apps.

For example - we can create an Identity Policy named "MIT" that contains 3 requirements say "Grade A in High School", "18 Years or less", "Nationality American". Now we can apply this policy on the MIT portal and this will allow only those students to apply for a graduate course who have these 3 things:

  1. Grade A in High School
  2. 18 Years or less
  3. Nationality American
(more…)

How to work with Claims in ASP.NET Core Identity

Last Updated: April 23, 2024

claims identity

(more…)

How to add Custom User Properties in ASP.NET Core Identity

Last Updated: April 22, 2024

Custom User Properties in identity

If we want to add custom user properties like "Age, Country & Salary" to the ASP.NET Core Identity Users then we can do this by adding Custom User Properties to the User class. The User class, as we all know, inherits from the IdentityUser parent class. These new custom properties are added as new columns to the AspNetUsers table of Identity database.

(more…)

How to work with Roles in ASP.NET Core Identity

Last Updated: April 21, 2024

identity roles

In ASP.NET Core Identity, we can create Roles that contain a set of permissions for performing a set of activities in the app. For example an organization can have 4 roles which are:

(more…)

How to do Authentication of Users in ASP.NET Core Identity

Last Updated: April 11, 2024

identity authentication

What is Identity Authentication in ASP.NET Core? Authentication is the process of recognition of a user when he successfully logins to the app. ASP.NET Core Identity presents a login form where user has to provide his username and password to authenticate himself. On successful login, Identity authenticates the user and he is granted access the secured resources of the ASP.NET Core app.

(more…)

Username, Email & Password Policy in ASP.NET Core Identity

Last Updated: April 3, 2024

username email password policy

(more…)

How to Create, Read, Update & Delete users in ASP.NET Core Identity

Last Updated: February 23, 2024

user management identity

In this tutorial we will perform ASP.NET Core Identity CRUD Operations for Creating, Reading, Updating and Deleting Users. This will help us to Manage Identity Users right through our ASP.NET Core app. Before continuing, kindly Setup and Configure ASP.NET Core Identity in your app. Once you did it kindly follow from here.

(more…)

How to Setup and Configure ASP.NET Core Identity

Last Updated: February 22, 2024

setup configure identity

ASP.NET Core Identity is a Toolkit and an API with which you can create Authorization and Authentication features in your application. Users can create an account and login with a user name and password. This also includes Roles and Roles Management. ASP.NET Core Identity uses a SQL Server Database to store user names, passwords, roles, and profile data.

(more…)

Execute SQL Stored Procedures using FromSqlRaw() & ExecuteSqlRawAsync() methods in Entity Framework Core

Last Updated: November 19, 2024

execute stored procedures ef core

SQL Stored Procedures can be easily executed using the FromSqlRaw() & ExecuteSqlRawAsync() methods in Entity Framework Core. This tutorial will cover them in details.

(more…)

Execute Raw SQL Queries using FromSqlRaw() method in Entity Framework Core

Last Updated: November 19, 2024

execute sql queries ef core

Entity Framework Core FromSqlRaw() method is used to Execute Raw SQL Queries including Parameterized Queries. This method returns an entity object. We use this method when we can't generate queries through LINQ or when EF Core generates inefficient queries.

(more…)