Add new option in service.Configure => options.UseSecurityTokenValidators = true;
read more: https://learn.microsoft.com/en-us/dotnet/core/compatibility/aspnet-core/8.0/securitytoken-events