Overview

Static Rendering

ZauberCMS uses EF Core identity for all authentication. You can read more about .Net Core Blazor authentication here

The main thing you need to understand with Identity in Blazor, is that all the account forms (Login, Register etc...) have to be rendered in static mode. They cannot use interactive server because they rely on the HttpContext constantly being available, which is not always the case in Blazor.

Because of this the account pages use their own layout and are stand alone, but you can still customise them by creating your own layout

Account Layout

Configuration

You can configure a lot of the Identity settings directly in the appSettings, under the Identity section

"Identity": {
  "PasswordRequireDigit": true,
  "PasswordRequireLowercase": true,
  "PasswordRequireNonAlphanumeric": false,
  "PasswordRequireUppercase": true,
  "PasswordRequiredLength": 8,
  "PasswordRequiredUniqueChars": 1,
  "SignInRequireConfirmedAccount": false,
  "AccountLayout": "ZauberCMS.Components.Pages.BlankLayout",
  "ExternalProviders": {
    "Google": {
      "ClientId": "",
      "ClientSecret": ""
    },
    "Facebook": {
      "AppId": "",
      "AppSecret": ""
    },
    "Microsoft": {
      "ClientId": "",
      "ClientSecret": ""
    }
  }
},

Last updated