JS: add window.name as DOM-based remote flow source

This commit is contained in:
Asger F
2018-11-30 11:06:43 +00:00
parent a4b3b1e8c8
commit 14621760bb

View File

@@ -199,4 +199,18 @@ private class PostMessageEventParameter extends RemoteFlowSource {
override string getSourceType() {
result = "postMessage event"
}
}
}
/**
* An access to `window.name`, which can be controlled by the opener of the window,
* even if the window is opened from a foreign domain.
*/
private class WindowNameAccess extends RemoteFlowSource {
WindowNameAccess() {
this = DataFlow::globalVarRef("name")
}
override string getSourceType() {
result = "Window name"
}
}