Glossary

What is XSS? (Cross-Site Scripting)

A type of attack in which an attacker plants a malicious script in a trusted web page so that it runs in other users' browsers.

XSS occurs when an application reflects user input onto a page without sanitizing it sufficiently. The malicious script runs in the victim’s browser as if the site were trusted; it can steal session information, change page content or redirect the user.

The main types are reflected XSS, stored XSS and XSS that originates from scripts in the browser. The core defense is encoding output appropriately for its context, validating input and using content security policies.

A WAF can provide additional protection by blocking requests that contain suspicious script patterns, but it does not replace fixing the code. XSS is considered within the injection family under the OWASP Top 10. For a similar risk on the server side, see SQL injection.

← All terms

Related solutions

Related articles

Application and Network Security

What Is a WAF? How a Web Application Firewall Works

A WAF (Web Application Firewall) inspects HTTP traffic at the application layer. Learn how it works, its rule models, deployment steps, and common mistakes.

· 7 min read

Let's plan your critical systems together

Tell us what you need; our team will work out the right architecture and migration path with you.