mirror of
https://github.com/github/codeql.git
synced 2026-03-17 04:56:58 +01:00
20 lines
629 B
Plaintext
20 lines
629 B
Plaintext
/**
|
|
* @name Reflected cross-site scripting
|
|
* @description Writing user input directly to an HTTP response allows for
|
|
* a cross-site scripting vulnerability.
|
|
* @kind problem
|
|
* @problem.severity error
|
|
* @precision high
|
|
* @id js/reflected-xss
|
|
* @tags security
|
|
* external/cwe/cwe-079
|
|
* external/cwe/cwe-116
|
|
*/
|
|
|
|
import javascript
|
|
import semmle.javascript.security.dataflow.ReflectedXss::ReflectedXss
|
|
|
|
from Configuration xss, DataFlow::Node source, DataFlow::Node sink
|
|
where xss.hasFlow(source, sink)
|
|
select sink, "Cross-site scripting vulnerability due to $@.",
|
|
source, "user-provided value" |