diff --git a/foxxey/config.php b/foxxey/config.php index 5daab98..7dc9a47 100644 --- a/foxxey/config.php +++ b/foxxey/config.php @@ -42,9 +42,8 @@ 'debugStartUpSound' => false, 'antiBruteDebug' => false, 'randTextsDebug' => false, - 'debugStartUpSound' => false, - /* AUTHORISATION */ + /* AUTHORISATION Modules */ 'checkHWID' => true, 'geoIPcheck' => true, 'useAntiBrute' => true, diff --git a/foxxey/scripts/functions.class.php b/foxxey/scripts/functions.class.php index 313bdd9..0f4733d 100644 --- a/foxxey/scripts/functions.class.php +++ b/foxxey/scripts/functions.class.php @@ -11,7 +11,7 @@ ----------------------------------------------------- File: functions,class.php ----------------------------------------------------- - Version: 0.1.4.1 Experimental + Version: 0.1.4.2 Experimental ----------------------------------------------------- Usage: A bunch of functions ===================================================== @@ -51,21 +51,6 @@ public function getUserData($login,$data){ } return $answer; } - - public function passwordReHash($pass, $realPass, $realName){ - global $config; - //$db = new db($config['db_user'],$config['db_pass'],$config['db_database']); - if (password_needs_rehash($realPass, PASSWORD_DEFAULT)) { - session_regenerate_id(); - $this->realPass = password_hash($this->pass, PASSWORD_DEFAULT); - $new_pass_hash = 'password='.$this->db->safesql($realPass).', '; - } else { - $new_pass_hash = ''; - } - - $hash = functions::generateLoginHash(); - $this->db->run("UPDATE LOW_PRIORITY dle_users SET ".$new_pass_hash." hash='".$hash."', lastdate='".CURRENT_TIME."' WHERE name='".$realName."'"); - } /* STATIC FUNCTIONS (NO DB NEEDED)*/ @@ -85,30 +70,50 @@ static function generateLoginHash(){ return $hash; } + public static function passwordReHash($pass, $realPass, $realName){ + global $config; + $db = new db($config['db_user'],$config['db_pass'],$config['db_database']); + if (password_needs_rehash($realPass, PASSWORD_DEFAULT)) { + session_regenerate_id(); + $this->realPass = password_hash($this->pass, PASSWORD_DEFAULT); + $new_pass_hash = 'password='.$db->safesql($realPass).', '; + } else { + $new_pass_hash = ''; + } + + $hash = functions::generateLoginHash(); + $db->run("UPDATE LOW_PRIORITY dle_users SET ".$new_pass_hash." hash='".$hash."', lastdate='".CURRENT_TIME."' WHERE name='".$realName."'"); + } + public static function includeModules($dirInclude, $debug = false){ $count = 1; + $IncludingText = ''; $dir = opendir($dirInclude); if($debug === true){ - echo '