ECSHOP商城模板2.73版本防注入漏洞修復(fù)操作
需要修改漏洞的三個(gè)文件路徑,網(wǎng)站更目錄下的includes/modules/payment/alipay.php,api/client/includes/lib_api.php,admin/edit_languages.php
1.includes/modules/payment/alipay.php修復(fù)方法(大概在第180行)
$order_sn = trim($order_sn);
修改為
$order_sn = trim(addslashes($order_sn));
2.api/client/includes/lib_api.php修復(fù)方法(大概在第247行)
function API_UserLogin($post)
{
修改為
function API_UserLogin($post)
{ if (get_magic_quotes_gpc()) { $post['UserId'] = $post['UserId'] } else { $post['UserId'] = addslashes($post['UserId']); }
3.admin/edit_languages.php修復(fù)方法(大概在第120行)
$dst_items[$i] = $_POST['item_id'][$i] .' = '. '"' .$_POST['item_content'][$i]. '";';
修改為
$dst_items[$i] = $_POST['item_id'][$i] .' = '. ''' .$_POST['item_content'][$i]. '';';