User-controllable input is placed in web output without neutralization, letting attackers run script in victims' browsers.
Contextually encode all output; set a strict Content-Security-Policy; prefer frameworks that auto-escape.
MITRE ATT&CK techniques associated with this weakness class (mapped via MITRE CAPEC). A vulnerability of this type could let an adversary carry out:
A stage-by-stage walkthrough of the attack, mapped to the real MITRE ATT&CK tactics for this weakness — what the attacker is trying to do, what's at risk (what can be stolen or damaged), and how you defend. Understanding the playbook is how you shut it down.
Map what else is reachable — hosts, services, data stores, and accounts.
Internal topology, service inventory, and data locations the attacker enumerates.
Network segmentation and detection of unusual internal scanning.
This is a defensive, conceptual walkthrough for education — stages reflect MITRE ATT&CK tactics associated with this weakness class, not a working exploit. Not every attack uses every stage.