X-Git-Url: https://git.mxchange.org/?p=mailer.git;a=blobdiff_plain;f=inc%2Fgen_sql_patches.php;h=d853f1ca8d9b9b1b56619e90b1827f27d2c1db99;hp=a358c8d74a31730107d78eb09ce915688c3d742c;hb=4b7f401f2a4680ae46ca41c57f749cfe35163660;hpb=263a089d8a499e0e26d0af9e7aa7639f88b8ca60 diff --git a/inc/gen_sql_patches.php b/inc/gen_sql_patches.php index a358c8d74a..d853f1ca8d 100644 --- a/inc/gen_sql_patches.php +++ b/inc/gen_sql_patches.php @@ -18,6 +18,7 @@ * svn:keywords Date Revision" (autoprobset!) at least!!!!!! * * -------------------------------------------------------------------- * * Copyright (c) 2003 - 2009 by Roland Haeder * + * Copyright (c) 2009, 2010 by Mailer Developer Team * * For more information visit: http://www.mxchange.org * * * * This program is free software; you can redistribute it and/or modify * @@ -39,10 +40,7 @@ // Some security stuff... if (!defined('__SECURITY')) { die(); -} - -// Check for version of sql_patches -if (getExtensionVersion('sql_patches') < '0.3.6') return false; +} // END - if // Check if there is no scrambling string if (getConfig('pass_scramble') == '') { @@ -77,11 +75,8 @@ if (getConfig('file_hash') == '') { $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); @@ -116,5 +111,5 @@ if (getConfig('file_hash') == '') { } // END - if } // END - if -// -?> \ No newline at end of file +// [EOF] +?>