magento < 1.9 xss 漏洞修復說明

magento XSS漏洞 介紹就不說了    百度一下  到處都是


這邊簡單記錄下 處理過程, (比較粗暴,是否有效尚未驗證)

編輯

app/design/adminhtml/default/default/template/sales/order/view/info.phtml

文件

搜索 getCustomerEmail  

 

有兩處  輸出調用


使用  htmlentities 方法過濾處理  即可    如下:

<td class="value">
    <a href="mailto:<?php echo htmlentities($_order->getCustomerEmail()); ?>">
    <strong>
        <?php echo htmlentities($_order->getCustomerEmail()); ?>
    </strong>
    </a>
</td>


PS:  主要是雲ECS 老提示安全問題, 如此處理後  煩人的提示就沒了,至於是否有效可用,有需要的可以驗證下  ,如有不對  歡迎拍磚 :)

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章