File tree Expand file tree Collapse file tree 2 files changed +20
-7
lines changed
DigitalLearningSolutions.Web Expand file tree Collapse file tree 2 files changed +20
-7
lines changed Original file line number Diff line number Diff line change @@ -35,14 +35,9 @@ public override Task ReturnQuotaExceededResponse(
3535 RateLimitRule rule ,
3636 string retryAfter )
3737 {
38- if ( _configuration [ "ASPNETCORE_ENVIRONMENT" ] == "PRODUCTION" )
39- {
40- httpContext . Response . Headers [ "Location" ] = "/toomanyrequests" ;
41- httpContext . Response . StatusCode = 302 ;
42-
43- }
38+ httpContext . Response . Headers [ "Location" ] = "/toomanyrequests" ;
39+ httpContext . Response . StatusCode = 302 ;
4440 return httpContext . Response . WriteAsync ( "" ) ;
45-
4641 }
4742 }
4843}
Original file line number Diff line number Diff line change 2424 "MaxBulkUploadRows" : 200 ,
2525 "LoginWithLearningHub" : true
2626 },
27+ "IpRateLimiting" : {
28+ "EnableEndpointRateLimiting" : false ,
29+ "StackBlockedRequests" : false ,
30+ "RealIpHeader" : " X-Real-IP" ,
31+ "HttpStatusCode" : 429 ,
32+ "GeneralRules" : [
33+ {
34+ "Endpoint" : " post:/ForgotPassword" ,
35+ "Period" : " 1m" ,
36+ "Limit" : 5
37+ },
38+ {
39+ "Endpoint" : " post:/Login" ,
40+ "Period" : " 1m" ,
41+ "Limit" : 5
42+ }
43+ ]
44+ },
2745 "LearningHubOpenAPIBaseUrl" : " https://uks-learninghubnhsuk-openapi-test.azurewebsites.net" ,
2846 "FreshdeskAPIConfig" : {
2947 "GroupId" : " 80000650208" ,
You can’t perform that action at this time.
0 commit comments