mirror of
https://github.com/github/codeql.git
synced 2025-12-18 18:10:39 +01:00
11 lines
332 B
JavaScript
11 lines
332 B
JavaScript
function test() {
|
|
var tainted = document.location.search
|
|
|
|
$(tainted); // NOT OK
|
|
$("body", tainted); // OK
|
|
$("." + tainted); // OK
|
|
$("<div id=\"" + tainted + "\">"); // NOT OK
|
|
$("body").html("XSS: " + tainted); // NOT OK
|
|
$(window.location.hash); // OK
|
|
}
|