IpRateLimiting
It is possible to limit the number of requests sent to the api to avoid DDoS. All options are described here. Here is a sample configuration section.
Ip Rate Limiting is disabled by default (if no configuration is provided)
CODE
"IpRateLimiting": {
"EnableEndpointRateLimiting": false,
"StackBlockedRequests": false,
"RealIpHeader": "X-Real-IP",
"ClientIdHeader": "X-ClientId",
"HttpStatusCode": 429,
"IpWhitelist": [ "127.0.0.1", "::1/10" ],
"EndpointWhitelist": [ "get:/health/live","get:/health/ready" ],
"ClientWhitelist": [ ],
"GeneralRules": [
{
"Endpoint": "*",
"Period": "1s",
"Limit": 2
},
{
"Endpoint": "*",
"Period": "15m",
"Limit": 100
},
{
"Endpoint": "*",
"Period": "12h",
"Limit": 1000
},
{
"Endpoint": "*",
"Period": "7d",
"Limit": 10000
}
]
}