Version Notes
stable release
Download this release
Release Info
| Developer | Magento Core Team |
| Extension | ET_IpSecurity |
| Version | 1.5.1 |
| Comparing to | |
| See all releases | |
Code changes from version 1.5.0 to 1.5.1
app/code/community/ET/ET_IpSecurity_ChangeLog.txt
CHANGED
|
@@ -9,12 +9,14 @@ TODO and some thoughts:
|
|
| 9 |
+ integrate anti spam service http://www.projecthoneypot.org/
|
| 10 |
|
| 11 |
=====================================
|
|
|
|
|
|
|
|
|
|
| 12 |
ver. 1.5.0
|
| 13 |
+ added table to database to store blocked ip's
|
| 14 |
+ added log grid in admin
|
| 15 |
+ added option: send notification every time on block or only on first
|
| 16 |
|
| 17 |
-
|
| 18 |
ver. 1.2.0
|
| 19 |
+ changed code pool from local to community
|
| 20 |
+ changed settings section
|
| 9 |
+ integrate anti spam service http://www.projecthoneypot.org/
|
| 10 |
|
| 11 |
=====================================
|
| 12 |
+
ver. 1.5.1
|
| 13 |
+
* resolved infinite loop when admin block rule happens and option "Add Store Code to Urls" = Yes and redirect to CMS page is on.
|
| 14 |
+
|
| 15 |
ver. 1.5.0
|
| 16 |
+ added table to database to store blocked ip's
|
| 17 |
+ added log grid in admin
|
| 18 |
+ added option: send notification every time on block or only on first
|
| 19 |
|
|
|
|
| 20 |
ver. 1.2.0
|
| 21 |
+ changed code pool from local to community
|
| 22 |
+ changed settings section
|
app/code/community/ET/IpSecurity/Model/Observer.php
CHANGED
|
@@ -80,7 +80,32 @@ class ET_IpSecurity_Model_Observer
|
|
| 80 |
$block_ips = null;
|
| 81 |
$except_ips = null;
|
| 82 |
$current_page = $this->trim_slashes(Mage::helper('core/url')->getCurrentUrl());
|
| 83 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 84 |
$neednotify = true;
|
| 85 |
$scope = $this->isFrontend?'frontend':'admin';
|
| 86 |
|
| 80 |
$block_ips = null;
|
| 81 |
$except_ips = null;
|
| 82 |
$current_page = $this->trim_slashes(Mage::helper('core/url')->getCurrentUrl());
|
| 83 |
+
|
| 84 |
+
// searching for CMS page storeId
|
| 85 |
+
// if we don't do it - we have loop in redirect with setting Add Store Code to Urls = Yes (block access to admin redirects to admin)
|
| 86 |
+
$stores = array();
|
| 87 |
+
foreach (Mage::app()->getStores() as $store)
|
| 88 |
+
{
|
| 89 |
+
$stores[] = $store->getId();
|
| 90 |
+
$pageId = Mage::getModel('cms/page')->checkIdentifier($this->redirect_page,$store->getId());
|
| 91 |
+
if($pageId===false) continue;
|
| 92 |
+
$pageStoreIds = Mage::getResourceModel('cms/page')->lookupStoreIds($pageId);
|
| 93 |
+
if (count($pageStoreIds)) // found page
|
| 94 |
+
break;
|
| 95 |
+
}
|
| 96 |
+
|
| 97 |
+
if (!count($pageStoreIds)) // no found in any store
|
| 98 |
+
$pageStoreIds[] = 0;
|
| 99 |
+
|
| 100 |
+
foreach ($pageStoreIds as $pageStoreId)
|
| 101 |
+
{
|
| 102 |
+
if ($pageStoreId > 0)
|
| 103 |
+
break;
|
| 104 |
+
}
|
| 105 |
+
if ($pageStoreId == 0)
|
| 106 |
+
$pageStoreId = $stores[0]; // first available store
|
| 107 |
+
|
| 108 |
+
$this->redirect_page = $this->trim_slashes(Mage::app()->getStore($pageStoreId)->getBaseUrl())."/".$this->redirect_page;
|
| 109 |
$neednotify = true;
|
| 110 |
$scope = $this->isFrontend?'frontend':'admin';
|
| 111 |
|
app/code/community/ET/IpSecurity/etc/config.xml
CHANGED
|
@@ -23,7 +23,7 @@
|
|
| 23 |
<config>
|
| 24 |
<modules>
|
| 25 |
<ET_IpSecurity>
|
| 26 |
-
<version>1.5.
|
| 27 |
<descr>
|
| 28 |
<ru_RU><