Skip to content

AccountRateLimiterServiceCollectionExtensions.AddAccountRateLimiter method

Adds a global rate limiter that limits POST requests to account actions like login, forgot password and sign up per client IP address and path, see AccountRateLimitOptions. Other requests are not limited. Call app.UseRateLimiter() in the request pipeline to activate it. If the application is behind a proxy, make sure forwarded headers are configured, otherwise all clients share the IP address of the proxy.

public static IServiceCollection AddAccountRateLimiter(this IServiceCollection services)
parameter description
services The service collection.

See Also