Web Security

Cross-Site Scripting (XSS)

Risk: Malicious scripts executed in user browsers. Understand XSS types and effective prevention strategies.

WEB-XSS-01Module ID
Hands-onLab Type
IntermediateLevel

Overview

Explore reflected, stored, and DOM XSS patterns and learn defenses that work across contexts and frameworks.

Learning Outcomes

  • Identify reflected, stored, and DOM-based XSS
  • Apply context-aware output encoding
  • Leverage CSP and sanitization where needed
  • Avoid dangerous sinks and template pitfalls
  • Validate fixes with automated tests

Hands-on Labs

Trigger and fix XSS across contexts and verify with CSP reporting and unit tests.

Defenses

Default to safe templating, strict CSP, and robust input handling.