From 572e49f494bf885a8360b94134b30366f7e5fa95 Mon Sep 17 00:00:00 2001 From: Mathew White Date: Sun, 8 Nov 2015 12:56:53 +0000 Subject: [PATCH 1/6] Removed print_r in recapcha helper --- application/helpers/recaptchalib_helper.php | 1 - 1 file changed, 1 deletion(-) diff --git a/application/helpers/recaptchalib_helper.php b/application/helpers/recaptchalib_helper.php index 60efba5..7322ad9 100644 --- a/application/helpers/recaptchalib_helper.php +++ b/application/helpers/recaptchalib_helper.php @@ -126,7 +126,6 @@ class ReCaptcha $answers = json_decode($getResponse, true); $recaptchaResponse = new ReCaptchaResponse(); - print_r($answers); if (trim($answers['success']) == true) { $recaptchaResponse->success = true; } else { From 50ddf8b99c56663bb844a5f66b5aac86e0d38c09 Mon Sep 17 00:00:00 2001 From: REJack Date: Mon, 9 Nov 2015 16:59:48 +0100 Subject: [PATCH 2/6] fix for allow_user and allow_group problem #90 --- application/libraries/Aauth.php | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/application/libraries/Aauth.php b/application/libraries/Aauth.php index 0ecff64..a927c05 100644 --- a/application/libraries/Aauth.php +++ b/application/libraries/Aauth.php @@ -1555,6 +1555,10 @@ class Aauth { $perm_id = $this->get_perm_id($perm_par); + if( ! $perm_id) { + return TRUE; + } + $query = $this->aauth_db->where('user_id',$user_id); $query = $this->aauth_db->where('perm_id',$perm_id); $query = $this->aauth_db->get($this->config_vars['perm_to_user']); @@ -1601,8 +1605,17 @@ class Aauth { public function allow_group($group_par, $perm_par) { $perm_id = $this->get_perm_id($perm_par); + + if( ! $perm_id) { + return TRUE; + } + $group_id = $this->get_group_id($group_par); + if( ! $group_id) { + return TRUE; + } + $query = $this->aauth_db->where('group_id',$group_id); $query = $this->aauth_db->where('perm_id',$perm_id); $query = $this->aauth_db->get($this->config_vars['perm_to_group']); From c7e05f0265347068d176f6eb09143220e227455e Mon Sep 17 00:00:00 2001 From: REJack Date: Tue, 10 Nov 2015 11:54:28 +0100 Subject: [PATCH 3/6] sry thats was my failure --- application/libraries/Aauth.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/application/libraries/Aauth.php b/application/libraries/Aauth.php index a927c05..0eed802 100644 --- a/application/libraries/Aauth.php +++ b/application/libraries/Aauth.php @@ -1556,7 +1556,7 @@ class Aauth { $perm_id = $this->get_perm_id($perm_par); if( ! $perm_id) { - return TRUE; + return FALSE; } $query = $this->aauth_db->where('user_id',$user_id); @@ -1607,13 +1607,13 @@ class Aauth { $perm_id = $this->get_perm_id($perm_par); if( ! $perm_id) { - return TRUE; + return FALSE; } $group_id = $this->get_group_id($group_par); if( ! $group_id) { - return TRUE; + return FALSE; } $query = $this->aauth_db->where('group_id',$group_id); From a858c1abf459b165dfc1ccb61c554c26ab9125cc Mon Sep 17 00:00:00 2001 From: REJack Date: Sun, 15 Nov 2015 18:51:51 +0100 Subject: [PATCH 4/6] changed 'TOTP Code' to 'Authentication Code' in english lang file --- application/language/english/aauth_lang.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/application/language/english/aauth_lang.php b/application/language/english/aauth_lang.php index 437a69d..ced329e 100644 --- a/application/language/english/aauth_lang.php +++ b/application/language/english/aauth_lang.php @@ -25,8 +25,8 @@ $lang['aauth_error_email_invalid'] = 'Invalid e-mail address'; $lang['aauth_error_password_invalid'] = 'Invalid password'; $lang['aauth_error_username_invalid'] = 'Invalid Username'; $lang['aauth_error_username_required'] = 'Username required'; -$lang['aauth_error_totp_code_required'] = 'TOTP Code required'; -$lang['aauth_error_totp_code_invalid'] = 'Invalid TOTP Code'; +$lang['aauth_error_totp_code_required'] = 'Authentication Code required'; +$lang['aauth_error_totp_code_invalid'] = 'Invalid Authentication Code'; // Account update errors From b254c9d7159a3f5e9610c30684958260d278aa68 Mon Sep 17 00:00:00 2001 From: scombat Date: Tue, 17 Nov 2015 14:30:28 +0100 Subject: [PATCH 5/6] Update array clearing for php compatibilities remove array clearing method (lines 1911 and 2001) : ```php $this->infos = []; ``` in profit of a more php compatible method : ```php $this->infos = array(); ``` --- application/libraries/Aauth.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/application/libraries/Aauth.php b/application/libraries/Aauth.php index 0ecff64..8cf71cc 100644 --- a/application/libraries/Aauth.php +++ b/application/libraries/Aauth.php @@ -1908,7 +1908,7 @@ class Aauth { */ public function clear_errors() { - $this->errors = []; + $this->errors = array(); $this->CI->session->set_flashdata('errors', $this->errors); } @@ -1998,7 +1998,7 @@ class Aauth { */ public function clear_infos() { - $this->infos = []; + $this->infos = array(); $this->CI->session->set_flashdata('infos', $this->infos); } From 8161fff5d24007f4edc6753653da0cb8c473c8a5 Mon Sep 17 00:00:00 2001 From: Emre Akay Date: Wed, 2 Dec 2015 13:37:47 +0200 Subject: [PATCH 6/6] Update Aauth.php --- application/libraries/Aauth.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/application/libraries/Aauth.php b/application/libraries/Aauth.php index 6ac87b8..6bb69eb 100644 --- a/application/libraries/Aauth.php +++ b/application/libraries/Aauth.php @@ -13,7 +13,7 @@ * * @copyright 2014-2015 Emre Akay * - * @version 2.4.5 + * @version 2.4.6 * * @license LGPL * @license http://opensource.org/licenses/LGPL-3.0 Lesser GNU Public License