Activities of "JeffreyKhor"

Question

Hi,

i am new in ABP framework, and i am working on the LDAP integration, i have followed the guide as link below: https://docs.abp.io/en/commercial/latest/modules/account/ldap#customize-built-in-services However i found out few objects were not found neither in LDAPForNet nor Volo.Abp.Ldap, error as screenshot below:

i cant find the LdapExternalLoginProvider, therefore i had followed the link as below: https://support.abp.io/QA/Questions/2540/Ldap-Operations-Error to create an external class of the LdapExternalLoginProvider, but then there are still errors on ILdapSettingProvider, which i cant finr the reference also, does anybody can help on this?

Thanks and regards, Jeffrey

ABP Framework version: v4.4.3

See https://docs.abp.io/en/commercial/4.4/modules/account/ldap

Hi,

thanks for the info, i managed to put into my project, however how should i know which class is placed under which project? according to the documentation, i put the VoloOpenLdapManager.cs and VoloLdapExternalLoginProvider.cs under the HttpApi.Host project as below:

is this correct? sorry for my immature experience

hi

You are right, You need to put it in the project where the account is hosted.

thanks, i managed to solve it

Question

Hi,

Below is my ABP details information:

  • ABP Framework version: v4.4.3
  • UI type: Angular
  • DB provider: EF Core
  • Tiered (MVC) or Identity Server Separated (Angular): yes

Continue to my last question, i would like to ask, is there any possible to customise to have multiple BaseDc instead of only one BaseDc for the LDAP login credential?

Thanks and regards, Jeffrey Khor

Hi,

Below is my ABP details information:

ABP Framework version: v4.4.3

UI type: Angular

DB provider: EF Core

Tiered (MVC) or Identity Server Separated (Angular): yes

I would like to ask, is there any possible to disable concurrent user login? maybe to make the first login become invalid after second login on another device

Thanks and regards, Jeffrey Khor

Hi,

Below is my ABP details information:

ABP Framework version: v4.4.3

UI type: Angular

DB provider: EF Core

Tiered (MVC) or Identity Server Separated (Angular): yes

We would like to ask, we have been using the AspNetCoreRateLimit package from this link: https://www.nuget.org/packages/AspNetCoreRateLimit/

and we had been followed tutorial link as below: https://blog.elmah.io/rate-limiting-api-requests-with-asp-net-core-and-aspnetcoreratelimit/ https://www.c-sharpcorner.com/article/implement-rate-limiting-in-asp-net-core-web-api/ https://code-maze.com/aspnetcore-web-api-rate-limiting/

but still not working, its still allow concurrent sending request within milliseconds, anyone have been facing this issue before?

Regards, Jeffrey Khor

no error or any warning logs, below are files that i put in according to the tutorial:

startup.cs:

using AspNetCoreRateLimit;
//using AspNetCoreRateLimit.Redis;
using DevExpress.AspNetCore;
using DevExpress.AspNetCore.Reporting;
using DevExpress.AspNetCore.Reporting.QueryBuilder;
using DevExpress.AspNetCore.Reporting.ReportDesigner;
using DevExpress.AspNetCore.Reporting.WebDocumentViewer;
using DevExpress.XtraReports.Security;
using DevExpress.XtraReports.Services;
//using DevExpress.XtraReports.Web.Extensions;
//using DevExpress.XtraReports.Web.ReportDesigner.Services;
//using DevExpress.XtraReports.Web.WebDocumentViewer;
//using KMS.EntityFrameworkCore;
using KMS.HubConfig;
using KMS.Reports;
//using KMS.Services;
using Microsoft.AspNetCore.Builder;
using Microsoft.AspNetCore.Hosting;
using Microsoft.AspNetCore.Http;
//using Microsoft.EntityFrameworkCore;
using Microsoft.Extensions.Configuration;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Logging;
//using StackExchange.Redis;
using System;
//using System.Collections.Generic;
//using Volo.Abp.Users;

namespace KMS
{
    public class Startup
    {
        private readonly IConfiguration appConfiguration;

        public Startup(IConfiguration _appConfiguration)
        {
            appConfiguration = _appConfiguration;
        }

        public void ConfigureServices(IServiceCollection services)
        {
            services.AddApplication<KMSHttpApiHostModule>();

            //added
            services.AddCors(options =>
            {
                options.AddPolicy("AllowAllHeaders",
                    builder =>
                    {
                        builder.AllowAnyOrigin()
                                .AllowAnyHeader()
                                .AllowAnyMethod();
                    });
            });

            //added
            services.AddSignalR(options =>
            {
                options.EnableDetailedErrors = true;
            });

            //added
            services.AddControllers();

            services.AddOptions();
            services.AddMemoryCache();
            services.Configure<IpRateLimitOptions>(appConfiguration.GetSection("IpRateLimit"));
            services.AddSingleton<IIpPolicyStore, MemoryCacheIpPolicyStore>();
            services.AddSingleton<IRateLimitCounterStore, MemoryCacheRateLimitCounterStore>();
            services.AddSingleton<IRateLimitConfiguration, RateLimitConfiguration>();
            services.AddSingleton<IProcessingStrategy, AsyncKeyLockProcessingStrategy>();
            services.AddSingleton<IHttpContextAccessor, HttpContextAccessor>();
            services.AddInMemoryRateLimiting();
            //services.AddHttpContextAccessor();

            ScriptPermissionManager.GlobalInstance = new ScriptPermissionManager(ExecutionMode.Unrestricted);
        }

        public void Configure(IApplicationBuilder app, IWebHostEnvironment env, ILoggerFactory loggerFactory)
        {
            app.InitializeApplication();

            app.UseDevExpressControls();
            //added
            app.UseCors("AllowAllHeaders");

            app.UseIpRateLimiting();

            //added
            app.UseEndpoints(endpoints =>
            {
                endpoints.MapControllers();
                endpoints.MapHub<MyMessageHub>("/signalrkms");
            });

            DevExpress.XtraReports.Web.ClientControls.LoggerService.Initialize(ProcessException);
        }

        void ProcessException(Exception ex, string message)
        {
            // Log exceptions here. For instance:
            System.Diagnostics.Debug.WriteLine("[{0}]: Exception occured. Message: '{1}'. Exception Details:\r\n{2}",
                DateTime.Now, message, ex);
        }
    }
}

appsettings.json:

{
...
"IpRateLimit": {
    "EnableEndpointRateLimiting": true,
    "StackBlockedRequests": false,
    "RealIPHeader": "X-Real-IP",
    "ClientIdHeader": "X-ClientId",
    "HttpStatusCode": 429,
    "GeneralRules": [
      {
        "Endpoint": "*:/api/app/kiosks",
        "Period": "30s",
        "Limit": 1
      }
    ]
  }
}

this is strange, i had tried on non ABP framework, no issue, and its working!!! only when with ABP framework causing issue

i had emailed you with the template project with the version 4.4.3, pls check ya, thanks in advance!!!

Regards, Jeffrey Khor

Showing 1 to 10 of 17 entries
Made with ❤️ on ABP v8.2.0-preview Updated on March 25, 2024, 15:11