title: ASP.NET Core: Using custom Identity Options isn't working
body: <p>I'm using Identity in an ASP.NET Core Web API application and want to use custom Identity options. I pass them in the <code>Startup.cs</code> when registering Identity like this:</p>
  <pre><code>Action&lt;IdentityOptions&gt; configureOptions = options =&gt;
     {
      options.Password.RequireDigit = false;
      options.Password.RequiredLength = 4;
      options.Password.RequireLowercase = false;
      options.Password.RequireUppercase = false;
      options.Password.RequireNonAlphanumeric = false;
      options.SignIn.RequireConfirmedAccount = true;
      options.SignIn.RequireConfirmedEmail = true;
    };
  
  services
   .AddIdentityCore&lt;ApplicationUser&gt;(configureOptions)
   .AddDefaultTokenProviders()
   .AddEntityFrameworkStores&lt;ApplicationDbContext&gt;()
   .AddErrorDescriber&lt;CustomIdentityErrorDescriber&gt;();
  </code></pre>
  <p>But these options doesn't change anything.</p>
  <p>For example when I set passwords required minimum length to 4 and add a user's password with the length of 5 I get an IdentityError which says that the minimum length is 8.</p>
  <p>That seems strange for me because the <a href="https://docs.microsoft.com/en-us/aspnet/core/security/authentication/identity-configuration?view=aspnetcore-5.0" rel="nofollow noreferrer">documentations of Identity</a> states that the default value is 6?</p>
  <p>So where does the 8 come from and why isn't it 4 as I configured it?</p>