diff --git a/controllers/front/AuthController.php b/controllers/front/AuthController.php index 5a6bed7ec..c067b5ace 100644 --- a/controllers/front/AuthController.php +++ b/controllers/front/AuthController.php @@ -277,11 +277,7 @@ class AuthControllerCore extends FrontController $customer = new Customer(); $authentication = $customer->getByEmail(trim($email), trim($passwd)); if (!$authentication || !$customer->id) - { - // Handle brute force attacks - sleep(1); $this->errors[] = Tools::displayError('Authentication failed'); - } else { $this->context->cookie->id_compare = isset($this->context->cookie->id_compare) ? $this->context->cookie->id_compare: CompareProduct::getIdCompareByIdCustomer($customer->id); diff --git a/install-dev/data/xml/configuration.xml b/install-dev/data/xml/configuration.xml index fdbb84398..f9677d4b8 100644 --- a/install-dev/data/xml/configuration.xml +++ b/install-dev/data/xml/configuration.xml @@ -143,9 +143,6 @@ 1 - - 1 - 3 diff --git a/modules/blockmyaccount/blockmyaccount.php b/modules/blockmyaccount/blockmyaccount.php index c4dee7a72..082ae9f0a 100644 --- a/modules/blockmyaccount/blockmyaccount.php +++ b/modules/blockmyaccount/blockmyaccount.php @@ -65,7 +65,7 @@ class BlockMyAccount extends Module return false; $this->smarty->assign(array( - 'voucherAllowed' => (int)Configuration::get('PS_VOUCHERS'), + 'voucherAllowed' => CartRule::isFeatureActive(), 'returnAllowed' => (int)Configuration::get('PS_ORDER_RETURN'), 'HOOK_BLOCK_MY_ACCOUNT' => Hook::exec('displayMyAccountBlock'), )); diff --git a/modules/blockmyaccountfooter/blockmyaccountfooter.php b/modules/blockmyaccountfooter/blockmyaccountfooter.php index e243c34c3..8cc74b5e4 100644 --- a/modules/blockmyaccountfooter/blockmyaccountfooter.php +++ b/modules/blockmyaccountfooter/blockmyaccountfooter.php @@ -63,7 +63,7 @@ class Blockmyaccountfooter extends Module if (!$params['cookie']->isLogged()) return false; $smarty->assign(array( - 'voucherAllowed' => (int)(Configuration::get('PS_VOUCHERS')), + 'voucherAllowed' => CartRule::isFeatureActive(), 'returnAllowed' => (int)(Configuration::get('PS_ORDER_RETURN')), 'HOOK_BLOCK_MY_ACCOUNT' => Hook::exec('displayMyAccountBlock') )); @@ -95,7 +95,7 @@ class Blockmyaccountfooter extends Module global $smarty; $smarty->assign(array( - 'voucherAllowed' => (int)(Configuration::get('PS_VOUCHERS')), + 'voucherAllowed' => CartRule::isFeatureActive(), 'returnAllowed' => (int)(Configuration::get('PS_ORDER_RETURN')), 'HOOK_BLOCK_MY_ACCOUNT' => Hook::exec('displayMyAccountBlock') ));