X
X

Select Your Currency

₺ Türk Lirası $ US Dollar
X
X

Select Your Currency

₺ Türk Lirası $ US Dollar

Safe Configuration Guide for DDoS Attack Prevention

HomepageArticlesSecuritySafe Configuration Guide for DDoS A...

DDoS attack prevention requires more than enabling a single setting: you must determine whether the attack is concentrated at the network layer, in HTTP requests, or at a specific endpoint in the application. First check your hosting provider’s network protection and, if available, the CDN/WAF layer; then apply only reversible rules suited to the traffic you have observed.

How can you distinguish DDoS traffic from normal spikes?

A DDoS attack generates traffic intended to consume a service from many sources. In volumetric attacks, connection capacity, packet processing, or the server network may be affected; in that case, the site’s application logs may not be created at all. In attacks at the HTTP layer, however, a large number of requests may target specific URLs, login pages, or search endpoints, and the web server may record these requests.

This distinction determines the first decision: if the network connection and other services are also inaccessible, blocking individual IP addresses will not be sufficient, so the hosting provider’s network operations team and upstream protection must be involved. If only a specific HTTP request is slowing down, resource usage is increasing, and new requests are appearing in the logs, rate limiting at the CDN, WAF, or application layer may be more appropriate.

Identify your environment and access before starting

If you use shared hosting, you generally cannot access the server firewall or network routing. In this environment, you can review the security, CDN, caching, and traffic statistics in the control panel and ask the provider for information about the attack period and the affected layer. A managed or self-managed server may require access to DNS, the WAF/CDN, the web server, the firewall, and the provider’s control panel.

Before making changes, record the existing DNS records, proxy status, WAF rules, and rate-limiting values. If possible, use a configuration export or the provider’s rollback feature. Do not change multiple rules at the same time; otherwise, you will not be able to determine which change affected real visitors.

Practical review sequence for DDoS attack prevention

  1. Record the time range and affected service. Note when the rise began on the traffic graph and whether the site itself or another service, such as email, SSH, or an API, was affected. If only the website is affected, focus on the HTTP layer; if access to the entire network is disrupted, focus on the provider-side attack protection. Use the same time range later when searching the logs.
  2. Compare the new evidence in the control panel and logs. In the CDN/WAF event screen, examine fields such as the request path, country or network provider, response code, and blocking reason. In the web server’s access and error logs, look for unusual URLs, methods, or response times with the same timestamps. If the connection is being disrupted without any web records being created, contact the provider about network protection instead of adding an application rule.
  3. Verify the existing edge protection. Routing a domain through a CDN or WAF may require a DNS record, a proxy option, or separate activation, depending on the provider. Proceed to the next step only if the control panel shows that protection is actually enabled and that traffic is not going directly to the origin server. If the origin IP address was previously exposed, enabling the proxy alone may not be sufficient; discuss a new origin address, access restrictions, and the migration method with the provider.
  4. Apply rate limiting only to the specific behavior. For example, if the logs show an extremely high number of requests to the same dynamic search URL while static files remain normal, configure the limit to target that path and similar client behavior rather than the entire site. Read the criterion the rule uses to distinguish real users, the time window, and the exceptions. Consider that automatic blocking on login, payment, or API endpoints may affect legitimate users; when the situation is unclear, first use an observation mode or a milder challenge option.
  5. Repeat the same operation and examine the new evidence. After applying the rule, retry the URL or operation that previously caused problems under the same conditions. Using the new timestamp, check in the WAF event that the request was limited for the expected reason while normal pages still open. If the response code has changed but a new database or timeout error appears in the application error log, do not assume that the DDoS rule solved the problem; examine the application layer separately.
  6. Use the rollback plan without making the result worse. If real users are being blocked, API clients are being disconnected, or the error rate is increasing, first restore only the most recently added rule to its previous value. If traffic is still consuming network capacity, ask the provider for attack response instead of randomly increasing rate limits; changing DNS and security settings repeatedly while the attack is ongoing can make diagnosis more difficult.

Targeted correction based on a specific finding

Suppose that a hypothetical product site slows down only during search requests; the WAF records show repeated requests to the same search URL at short intervals, while requests to the home page show normal traffic. This finding suggests applying measured rate limiting to the search endpoint and, if necessary, a caching policy rather than immediately increasing general server resources. However, if a database timeout appears in a new test, the problem may not be limited to attack traffic; the search query and database resources should also be examined.

When is a particular protection not sufficient?

A CDN or WAF can filter web traffic, but its behavior varies according to the provider, the plan’s capacity, the supported protocols, and the origin server’s configuration. In a large attack at the network level, a single HTTP rule added through the control panel may not be sufficient. Conversely, imposing a strict limit on the entire site during a normal campaign may interrupt sales, login, or API operations.

A practical choice can be made as follows: if only one web path is receiving excessive requests, choose a path-specific, low-risk rule; if multiple ports and services are affected, evaluate the provider’s network-based protection and traffic routing. As a permanent solution, restricting origin access to authorized edge layers may be possible with some providers, but its feasibility depends on the server and network architecture; verify the provider’s procedure before accidentally blocking existing administrative access.

To clarify which protections your provider offers and what level of access is available during the initial review, you can evaluate the relevant hosting information on İyibirNet. The next safe step is to note the attack time, affected URL, and observed log finding and report them to the provider; do not share credentials or confidential tokens.


Top