ASP.NET Identity Management Template for VS 2017

I was working on integrating ASP.NET Identity into an existing project and realized that I couldn't find a management piece to go along with the identity piece.  I searched all the usual places, but the only luck I had was finding bits and snippets of how the whole management part was supposed to work.  I finally was able to cull all these different pieces into a working solution, complete with user and role editing, and the assignment of roles to users.

To take this solution to the next step, I created a VS 2017 template that takes the boilerplate solution I created and gives the developer the ability to rename the project, which in turn, renames the namespace and prefixes for the identity classes, managers, stores, etc. with the safe project name.  It also creates an Administrators role and admin users via seeding the database.  This can be changed (and I strongly encourage this change) so as to not put the default admin name and password live on the web.

I can't take full credit for writing this from scratch, it's just a gathering of the different methods that I found either on Stack Overflow or on other developer blogs.  I just want to help us developers to spend less time on searching for answers and make use of templates.

Here is the GitHub link to the project, which includes the source files and the actual template file in zipped format.

Let me know what you think in the comments section.

This article was updated on September 8, 2019

Jerry P