JS: whitelist $(location) in simple cases

This commit is contained in:
Asger F
2018-12-18 13:01:22 +00:00
parent c17eca90a1
commit 02978c97f1
4 changed files with 3 additions and 36 deletions

View File

@@ -91,7 +91,8 @@ module DomBasedXss {
isPrefixOfJQueryHtmlString(astNode, prefix) and
strval = prefix.asExpr().getStringValue() and
not strval.regexpMatch("\\s*<.*")
)
) and
not isDocumentURL(astNode)
)
or
// call to an Angular method that interprets its argument as HTML