Company
Date Published
Author
Andrew Israel
Word count
1867
Language
English
Hacker News points
None

Summary

Blazor offers a streamlined method for building web applications using C#, allowing .NET developers to capitalize on their existing skills while minimizing dependency on JavaScript. This guide illustrates how to enhance security in a .NET Blazor Server application using PropelAuth, focusing on setting up authentication, securing pages, and incorporating multi-tenancy. An example is provided with a simple CRM where access to Leads is restricted to authorized users within specific organizations. The integration involves configuring PropelAuth with OAuth, utilizing authorization attributes in Blazor, and managing multi-tenant environments through role-based permissions. The guide also demonstrates how to display user information and manage data access using scoped services, highlighting the flexibility to switch between organizations through UI selections stored in cookies. Overall, it showcases how to maintain secure and efficient applications using Blazor and PropelAuth, with most operations handled in C#.