Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
ID |
scala.xss.scala_xss_rule_mvcapi |
Severity |
low |
Resource |
Xss |
Language |
Scala |
Rationale
Disabling HTML escaping put the application at risk for Cross-Site Scripting (XSS).
The following code illustrates a vulnerable pattern detected by this rule:
def unsafe(value: String) = Action{
// VULNERABLE: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
Ok(value)
}
Remediation
Follow secure coding practices and review the references below for detailed remediation guidance.
References
-
OWASP Top 10 2021 - A03 : Injection.