Open Closed

Exception on creating user by organization login #7751


User avatar
0
imranStem created

I have configured the Azure OpenId but when I use organization login and try to register the user, auth server throwing exception of Setting value for 'Abp.Mailing.Smtp.Password' is null or empty!

.AddOpenIdConnect("AzureOpenId", "Organisation login", options =>
           {
               options.Authority = configuration["Azure:AzureAd:Instance"] + configuration["Azure:AzureAd:TenantId"] + configuration["Azure:AzureAd:Version"];
               options.ClientId = configuration["Azure:AzureAd:ClientId"];
               options.ResponseType = OpenIdConnectResponseType.CodeIdToken; 
               options.CallbackPath = configuration["Azure:AzureAd:CallbackPath"];
               options.ClientSecret = configuration["Azure:AzureAd:ClientSecret"];
               options.RequireHttpsMetadata = false;
               options.SaveTokens = true;
               options.GetClaimsFromUserInfoEndpoint = true;
               options.Scope.Add("email");
           });

If I create user from users management then there is no error and its working fine.

  • ABP Framework version: v8.1.3
  • UI Type: Angular
  • Database System: EF Core (SQL Server)
  • Tiered (for MVC) or Auth Server Separated (for Angular): yes
  • Exception message and full stack trace:
  • Steps to reproduce the issue:

3 Answer(s)
  • User Avatar
    0
    liangshiwei created
    Support Team Fullstack Developer

    ABP is trying to send an email to confirm.

    you can turn off the confirm email send or configure your email settings.

  • User Avatar
    0
    imranStem created

    Confirm email is disabled.

  • User Avatar
    0
    liangshiwei created
    Support Team Fullstack Developer

    Hi,

    sorry, if you don't need to email send, you can use the NullEmailSender

    add this to the ConfigureServices.

    context.Services.Replace(ServiceDescriptor.Singleton<IEmailSender, NullEmailSender>());

Made with ❤️ on ABP v9.1.0-preview. Updated on December 12, 2024, 07:15