Home » DDoS Protection: Detection, Mitigation และ Architecture Design
DDoS Protection: Detection, Mitigation และ Architecture Design
DDoS Protection: Detection, Mitigation และ Architecture Design
DDoS (Distributed Denial of Service) เป็นการโจมตีที่ส่ง traffic จำนวนมหาศาลจากหลาย sources เพื่อทำให้ target service ล่ม DDoS attacks มีขนาดใหญ่ขึ้นทุกปี (record 3.47 Tbps ใน 2023) การป้องกันต้อง design architecture ที่รองรับ detection + mitigation ตั้งแต่ network edge จนถึง application layer
DDoS ไม่ใช่แค่ volumetric flooding อีกต่อไป — modern DDoS มี application-layer attacks (L7) ที่ใช้ bandwidth น้อยแต่ทำ server crash ได้ เช่น HTTP flood, Slowloris, DNS query flood การป้องกันต้องครอบคลุมทั้ง network layer (L3/L4) และ application layer (L7)
DDoS Attack Types
| Type |
Layer |
วิธีโจมตี |
ตัวอย่าง |
| Volumetric |
L3/L4 |
Flood bandwidth ด้วย traffic ปริมาณมาก |
UDP flood, ICMP flood, DNS amplification |
| Protocol |
L3/L4 |
Exploit protocol weakness ใช้ resources |
SYN flood, Ping of Death, Smurf |
| Application |
L7 |
Target application logic (low bandwidth, high impact) |
HTTP flood, Slowloris, DNS query flood |
| Reflection/Amplification |
L3/L4 |
Spoof source IP → reflector ส่ง response ไป victim |
DNS amp (54x), NTP amp (556x), Memcached (51000x) |
Amplification Factors
| Protocol |
Amplification Factor |
Port |
| Memcached |
51,000x |
11211/UDP |
| NTP (monlist) |
556x |
123/UDP |
| DNS (ANY query) |
54x |
53/UDP |
| SSDP |
30x |
1900/UDP |
| SNMP |
6x |
161/UDP |
| CLDAP |
70x |
389/UDP |
Detection Methods
| Method |
วิธีทำงาน |
ข้อดี/ข้อเสีย |
| Flow-Based (NetFlow/sFlow) |
วิเคราะห์ flow patterns หา anomalies |
Low overhead แต่ไม่ real-time (sampling delay) |
| Inline Detection |
Inspect ทุก packet ที่ผ่าน |
Real-time แต่ performance impact |
| BGP Flowspec |
Distribute filtering rules ผ่าน BGP |
Fast mitigation at network edge |
| Behavioral Analysis |
Baseline traffic → alert เมื่อ deviation |
Detect novel attacks แต่ false positives |
| Rate-Based |
Alert เมื่อ traffic > threshold |
Simple แต่ miss L7 attacks |
Mitigation Architecture
| Layer |
Solution |
ป้องกันอะไร |
| Cloud/CDN Edge |
Cloudflare, Akamai, AWS Shield |
Absorb volumetric attacks ก่อนถึง origin |
| ISP/Transit |
Upstream blackhole, flowspec |
Drop attack traffic ที่ ISP level |
| Scrubbing Center |
Dedicated DDoS scrubbing (Arbor, Radware) |
Clean traffic แล้วส่ง clean traffic ไป origin |
| On-Premise |
Firewall, IPS, load balancer |
L7 attacks, smaller attacks |
| Application |
WAF, rate limiting, CAPTCHA |
L7 application attacks |
Cloud DDoS Protection
| Provider |
Product |
Capacity |
จุดเด่น |
| Cloudflare |
DDoS Protection (free + paid) |
248+ Tbps |
Always-on, free L3/L4, WAF for L7 |
| AWS |
Shield Standard/Advanced |
AWS network capacity |
Shield Standard ฟรี, Advanced = managed + WAF |
| Akamai |
Prolexic |
20+ Tbps scrubbing |
Dedicated SOC, enterprise-grade |
| Google Cloud |
Cloud Armor |
Google network |
Adaptive protection, ML-based |
| Azure |
DDoS Protection |
Azure network |
Standard = always-on, auto-tuned |
BGP Blackhole
| Feature |
รายละเอียด |
| วิธีทำงาน |
Announce /32 victim IP กับ blackhole community → ISP drops ALL traffic ไป IP นั้น |
| Community |
65535:666 (RFC 7999 BLACKHOLE community) |
| ข้อดี |
Fast (minutes), stops volumetric at ISP edge |
| ข้อเสีย |
Victim IP ใช้ไม่ได้ (drop ทั้ง good + bad traffic) |
| ใช้เมื่อ |
Last resort เมื่อ attack ใหญ่เกินกว่า scrub ได้ |
L7 DDoS Mitigation
| Technique |
วิธีป้องกัน |
| Rate Limiting |
Limit requests per IP/session (e.g., 100 req/min) |
| WAF Rules |
Block malicious patterns (User-Agent, headers, payload) |
| CAPTCHA/Challenge |
JavaScript challenge หรือ CAPTCHA สำหรับ suspicious requests |
| Bot Management |
Fingerprint bots vs humans (browser fingerprint, behavior) |
| Geo-Blocking |
Block traffic จาก countries ที่ไม่มี legitimate users |
| Connection Limiting |
Limit concurrent connections per IP |
Best Practices
| Practice |
รายละเอียด |
| Multi-layer defense |
Cloud edge + ISP + on-prem + WAF (defense in depth) |
| Always-on protection |
ใช้ cloud DDoS (Cloudflare/AWS Shield) always-on ไม่ใช่ on-demand |
| DDoS runbook |
มี playbook สำหรับ DDoS incident (who, what, when) |
| Capacity planning |
Bandwidth headroom + auto-scaling สำหรับ absorb spikes |
| Reduce attack surface |
ปิด unnecessary ports/services + hide origin IP |
| Regular testing |
DDoS simulation tests (with provider permission) |
ทิ้งท้าย: DDoS Protection = Multi-Layer Defense
DDoS = volumetric (L3/L4) + protocol + application (L7) Cloud DDoS (Cloudflare/AWS Shield) = first line of defense BGP blackhole = last resort (drops all traffic to victim IP) L7: WAF + rate limiting + CAPTCHA + bot management Multi-layer: cloud edge → ISP → scrubbing → on-prem → WAF
อ่านเพิ่มเติมเกี่ยวกับ Zero Trust ZTNA และ Network Security Zones ที่ siamlancard.com หรือจาก icafeforex.com และ siam2r.com