View Categories

What is cross-site scripting (XSS) and how can I prevent it?

< 1 min read

What is cross-site scripting (XSS) and how can I prevent it?


  1. Cross-Site Scripting (XSS) is an attack in which malicious code is injected into a website or application.
  2. To stop an XSS attack, developers should:
    • Validate user input using input filtering
    • Encode output using HTML entities and character references
    • Use a Content Security Policy (CSP)

Powered by BetterDocs