重要提醒:下载并安装Magento...如何确保这些补丁安装成功?[复制]

magento.stackexchange https://magento.stackexchange.com//questions/64077

  •  12-12-2019
  •  | 
  •  

我从 Magento 收到这条消息

“重要提醒:下载并安装 Magento 安全补丁。现在下载。”

在我成功安装所需的补丁后,我仍然收到该消息,所以我的问题是如何确保这些补丁安装成功?我是否应该手动删除该警报?

有帮助吗?

解决方案

修补的主要文件之一是 app/core/Mage/Core/Controller/Request/Http.php

例如,在 Magento 1.6.2.0 中,在修补文件和原始文件之间进行比较会显示以下添加的代码。

Compare: (<)V:\Magento\Magento 1.6\Changes\20150217 Patches\5346\Http.php (15698 bytes)
   with: (>)V:\Magento\Magento 1.6\Changes\20150217 Patches\5346\Http.php.old (15031 bytes)

79,85d79
<      * Flag for recognizing if request internally forwarded
<      *
<      * @var bool
<      */
<     protected $_internallyForwarded = false;
< 
<     /**
540,562d533
< 
<     /**
<      * Define that request was forwarded internally
<      *
<      * @param boolean $flag
<      * @return Mage_Core_Controller_Request_Http
<      */
<     public function setInternallyForwarded($flag = true)
<     {
<         $this->_internallyForwarded = (bool)$flag;
<         return $this;
<     }
< 
<     /**
<      * Checks if request was forwarded internally
<      *
<      * @return bool
<      */
<     public function getInternallyForwarded()
<     {
<         return $this->_internallyForwarded;
<     }
< 

下面的命令行条目可以通过查找添加的内容快速判断该文件是否已被修补 _internallyForwarded 旗帜。在 Magento 根文件夹中运行它:

grep "_internallyForwarded" app/code/core/Mage/Core/Controller/Request/Http.php

下图显示该文件已被修补。

public_html$ grep "_internallyForwarded" app/code/core/Mage/Core/Controller/Request/Http.php
     protected $_internallyForwarded = false;
        $this->_internallyForwarded = (bool)$flag;
        return $this->_internallyForwarded;

其他可能已修补的文件:

app/code/core/Mage/Admin/Model/Observer.php
app/code/core/Mage/Core/Controller/Request/Http.php
lib/Varien/Db/Adapter/Pdo/Mysql.php

另请检查 app/etc/applied.patches.list 以查看列表末尾的最新补丁应用程序。

请注意,以防 Magento 完全出色的内部质量控制将补丁识别为 5346,而不是下载中广告的 5344。他们在附加消息中得到了它(某些东西?)。

其他提示

该消息来自 Magento 的 RSS 源 - 它与您是否安装了补丁无关,因此如果您安装了补丁,则可以手动删除警报。

有一台扫描仪位于 https://shoplift.byte.nl/ 它会检查您是否正确安装了 SUPEE-5344 补丁。

提醒

提醒是在Mage_AdminNotification模块中实现的。

不检查是否安装了补丁。

要删除提醒:

  • 登录后台
  • 导航 System → Notification
  • 将提醒标记为已读或将其删除

补丁

应用补丁:

应用了哪些补丁?

  • 检查文件 /app/etc/applied.patches.list
许可以下: CC-BY-SA归因
scroll top