// Init filters
registerFilter('init', 'LOAD_CONFIGURATION');
+ registerFilter('init', 'INIT_RANDOMIZER');
registerFilter('init', 'LOAD_RUNTIME_INCLUDES');
registerFilter('init', 'INIT_EXTENSIONS');
- registerFilter('init', 'INIT_RANDOMIZER');
registerFilter('init', 'INIT_RANDOM_NUMBER');
registerFilter('init', 'CHECK_SVN_REVISION');
registerFilter('init', 'RUN_DAILY_RESET');
// Load the include
loadIncludeOnce($inc);
} // END - foreach
-
- // Load admin include file if he is admin
- if (isAdmin()) {
- // Administrative functions
- loadIncludeOnce('inc/modules/admin/admin-inc.php');
- } // END - if
- //* DEBUG: */ addPointsThroughReferalSystem('test', 36, 1000);
- //* DEBUG: */ die();
}
// Filter for checking admin ACL
//* DEBUG: */ outputHtml(__FUNCTION__.':'.strlen($passHash).'/'.strlen(getConfig('secret_key')).'<br />');
if ((strlen($passHash) != 49) || (strlen(getConfig('secret_key')) != 40)) {
// Both keys must have same length so return unencrypted
+ logDebugMessage(__FUNCTION__, __LINE__, strlen($passHash).'!=49/'.strlen(getConfig('secret_key')).'!=40');
return $ret;
} // END - if
$fileHash
);
- // Count of chars to be taken from back of the string
- $nums = mt_rand(40, 45);
-
// Generate secret key from a randomized string
- $secretKey = substr(sha1(generatePassword(mt_rand(128, 256))), -$nums);
+ $secretKey = sha1(generateHash(mt_rand(128, 256)));
// File hash was never created
writeToFile($FQFN, $secretKey);