Extending Identity – Adding Roles at User Registration

Depending on the application there may be times that it is desirable or required to add a user to a role immediately when they register. Other times you may want to add users to various roles depending on what privileges you want them to have. This is very easily accomplished in the Register method of the AccountController. This is the third post in a 3 part series on extending the ASP.NET Identity Framework.

Continue reading

Extending Identity – Account Verification

As stated in the previous blog post Identity is very useful for Asp.net developers out of the box. There is some functionality that must be configured to make it completely functional. User can register and they will be redirected to a default page that asks them to check and confirm their email. The system is not setup however to email the confirmation message nor is it configured to lock users out until they confirm their email. This takes a little configuration but I take it a step further to make it as user friendly as possible. This is the second post in a 3 part series on extending the ASP.NET Identity Framework.

Continue reading

Snippet Managers

I have found myself returning to past projects looking up code that I had done previously so that I did not have to figure it out again. Many times it is for larger sections of code that I have to use on a regular basis. Having to dig through multiple solutions to find the code that I am looking for becomes a pain after a while. Visual Studio has the ability to store code snippets but those snippets don’t always carry over from solution to solution. I began looking into snippet managers and found some very promising options.

Continue reading

Making ASP.NET Identity and Unity Work Together

The beauty of ASP.NET MVC is its ability to leverage so many other frameworks to help improve code security, maintainability and SOLID development principles. One downfall however is that these different frameworks don’t always want to work together out of the box at times such as Identity for authentication and authorization and Unity for dependency injection. This is not very difficult to fix as long as you know what you need to add where.  Continue reading

Log4Net ASP.NET MVC UI

Log4Net is a very powerful logging application for ASP.NET applications. Logs can be written to a text file or also to a database. The one major downfall of Log4Net is that it does not have a built in interface to view the logs. I have created a new project on GitHub to house a MVC based UI for Log4Net logs that are written to a database. Continue reading