40. DoS and DDoS – Availability Attacks
40.10 Putting It Together – Purple Team Mindset
Thodkyaat: DoS/DDoS chapter = availability + classes + SYN/amp/app + Mirai lesson + scrub stack + ethics + IR. Tools change; habit (own-lab only, rate limit, hide origin) rahate.
Interview model (clean English): "I never run floods or amplification against systems I do not own. In the lab I stress my own nginx, then apply rate limits and timeouts. For real incidents I escalate to ISP/CDN scrubbing and protect origin IP."
| Red team (attacker) does | Blue team (defender) detects / stops |
|---|---|
| Full chain in lab: weak origin → controlled load → outage | Purple Team: limit_req + firewall + monitoring proven |
| Shames SME during festival outage | Helps SME scrub + communicate; documents lessons for Raja/Rani |
Ravindra Bagale's Tip
Volumetric numbers look huge in the news – your first job is often an app-layer rate limit + a CDN checkbox. Keep the basics strong. Next up: session hijacking!
Ravindra Bagale's Tip – मराठी
Volumetric numbers बातम्यांमध्ये खूप मोठे दिसतात – तुमचे पहिले काम बऱ्याचदा app-layer rate limit + CDN tickbox असते. Basics strong ठेवा. आता पुढे session hijacking!
Ravindra Bagale's Tip – हिंदी
Volumetric numbers खबरों में बहुत बड़े दिखते हैं – आपका पहला काम अक्सर app-layer rate limit + CDN tickbox होता है. Basics strong रखो. अब आगे session hijacking!
Lab
Chapter project (40.9 box) complete kara. Mag 10 flashcards: DoS, DDoS, volumetric, SYN flood, amplification, slowloris-class, Mirai, scrubbing, Anycast, limit_req. Pair: ek Red "how availability breaks", ek Blue "how we survive".
Thodkyaat sangaycha tar
- DoS = few sources; DDoS = many (botnet) – both attack availability (उपलब्धता).
- Classes: volumetric, protocol, application-layer – different Blue controls.
- SYN flood → SYN cookies + rate limits; never flood shared/public networks.
- Amplification/reflection (DNS/NTP/Memcached) – study GitHub 2018; never amp the internet.
- App-layer: rate limits, timeouts, WAF, sensible workers.
- Mirai-class: IoT defaults + segmentation + egress hygiene.
- Defence stack: monitor, scrub, Anycast CDN, WAF, origin limits, firewalld/ufw.
- Lab ethics: own VMs/host-only only; IT Act awareness; project Build-Hack-Fix for Raja-Rani order page.
- IR: confirm → mitigate upstream → communicate → harden; CERT-In / cybercrime.gov.in awareness.
Samjla ka? DoS/DDoS shiklo – pan pratyek sobat bachav ani safe lab. Pudhchya chapter madhe **session hijacking** (session tokens, cookies, defence) – CEH modules pudhe. Chala pudhe, mitrano!
Extended teaching notes
Why this lesson matters
Availability attacks try to exhaust bandwidth, connections or app workers. Learning them is about detection and defence — never about stressing networks you do not own (that can be illegal and harmful).
- Rate limits and WAF/CDN at the edge.
- SYN cookies / tuning on servers.
- Autoscaling with care (cost controls).
- Keep IoT devices off default passwords (Mirai lesson).
- Lab simulations only on isolated networks you own.
Mini case study
Suppose we are on a purple-team exercise for an Indian mid-size company (sample data). Red notes a technique from this lesson against a lab clone. Blue must show the control that stops it, the log that would have fired, and the ticket that hardens production. That is the standard this course trains you for.
Defender's worksheet (do this today)
- Write the lesson title, date and the exact lab target you are allowed to use.
- List three owned systems (VMs, apps, or cloud accounts) where this lesson applies.
- Run one safe check from the lesson on a lab system only. Paste the command and output.
- Write a two-sentence fix you would give a teammate.
- Name one related public advisory (CERT-In, CISA, NVD, or a vendor bulletin) with its date.
Indian workplace (sample data)
Suppose we are a junior analyst at Infosys, TCS, Wipro or a fintech SOC in Bengaluru/Pune. Turn this lesson into one checklist item with an owner, a due date and a place to store evidence (ticket + screenshot).
Global practice
Compare your notes with OWASP, CIS Benchmarks, NIST CSF/IR guidance or a cloud Well-Architected security question. Write five lines on what overlaps.
Everyday analogy
Explain the risk and the fix to a family member without jargon. If they can repeat the warning, you understand it well enough to teach juniors.
Key terms
- Control: a safeguard (patch, config, process, detection).
- Finding: a weakness backed by evidence.
- Remediation: the fix plus how you verified it.
- Scope: systems you have written permission to touch.
- Least privilege: only the access the task needs.
- Defence in depth: several layers so one failure does not end the story.
Common mistakes
- Skipping written permission "just for a quick scan".
- Practising on hostel, office or public targets without authorisation.
- Collecting tool output without writing the fix.
- Copying attack steps onto production to "verify". Defenders verify with versions, configs and patches.
- Publishing screenshots that contain secrets, cookies or internal hostnames.
Recap
- Evidence, fix, owner, date.
- Own lab only.
- Fix > spectacle.