From: Thijs K. <ki...@us...> - 2002-08-14 14:24:52
|
Update of /cvsroot/squirrelmail/squirrelmail/plugins/squirrelspell In directory usw-pr-cvs1:/tmp/cvs-serv18905 Modified Files: Tag: SM-1_2-STABLE INSTALL sqspell_config.php sqspell_functions.php sqspell_interface.php sqspell_options.php Log Message: rg=off for squirrelspell plugin Index: INSTALL =================================================================== RCS file: /cvsroot/squirrelmail/squirrelmail/plugins/squirrelspell/INSTALL,v retrieving revision 1.3 retrieving revision 1.3.2.1 diff -u -w -r1.3 -r1.3.2.1 --- INSTALL 15 Nov 2001 13:00:20 -0000 1.3 +++ INSTALL 14 Aug 2002 14:24:48 -0000 1.3.2.1 @@ -31,7 +31,9 @@ **/ /* Just for poor wretched souls with E_ALL. :) */ - global $username, $data_dir; + global $data_dir; + + $username = $_SESSION['username']; /** SPELL-CHECKING APPLICATIONS: Index: sqspell_config.php =================================================================== RCS file: /cvsroot/squirrelmail/squirrelmail/plugins/squirrelspell/sqspell_config.php,v retrieving revision 1.9 retrieving revision 1.9.2.1 diff -u -w -r1.9 -r1.9.2.1 --- sqspell_config.php 31 Jan 2002 04:54:13 -0000 1.9 +++ sqspell_config.php 14 Aug 2002 14:24:48 -0000 1.9.2.1 @@ -13,7 +13,9 @@ require_once('../functions/prefs.php'); /* Just for poor wretched souls with E_ALL. :) */ -global $username, $data_dir; +global $data_dir; + +$username = $_SESSION['username']; /** * Example: Index: sqspell_functions.php =================================================================== RCS file: /cvsroot/squirrelmail/squirrelmail/plugins/squirrelspell/sqspell_functions.php,v retrieving revision 1.8 retrieving revision 1.8.2.1 diff -u -w -r1.8 -r1.8.2.1 --- sqspell_functions.php 6 Mar 2002 02:09:21 -0000 1.8 +++ sqspell_functions.php 14 Aug 2002 14:24:48 -0000 1.8.2.1 @@ -26,7 +26,10 @@ * @return void */ function sqspell_makePage($title, $scriptsrc, $body){ - global $color, $SQSPELL_VERSION, $MOD; + global $color, $SQSPELL_VERSION; + + $MOD = $_GET['MOD']; + displayPageHeader($color, 'None'); echo " <br>\n"; /** @@ -326,8 +329,12 @@ * the user's old mailbox password. I admin, this is rather dirty, * but efficient. ;) */ - global $key, $onetimepad, $old_key; - if ($old_key) { + + $key = $_COOKIE['key']; + $onetimepad = $_SESSION['onetimepad']; + $old_key = $_POST['old_key']; + + if ($old_key != '') { $clear_key=$old_key; } else { /** @@ -434,7 +441,9 @@ * User wants to encrypt the file. So be it. * Get the user's password to use as a key. */ - global $key, $onetimepad; + $key = $_COOKIE['key']; + $onetimepad = $_SESSION['onetimepad']; + $clear_key=OneTimePadDecrypt($key, $onetimepad); /** * Try encrypting it. If fails, scream bloody hell. Index: sqspell_interface.php =================================================================== RCS file: /cvsroot/squirrelmail/squirrelmail/plugins/squirrelspell/sqspell_interface.php,v retrieving revision 1.6 retrieving revision 1.6.2.1 diff -u -w -r1.6 -r1.6.2.1 --- sqspell_interface.php 2 Feb 2002 02:17:05 -0000 1.6 +++ sqspell_interface.php 14 Aug 2002 14:24:48 -0000 1.6.2.1 @@ -39,7 +39,13 @@ * If $MOD is undefined, use "init", else check for security * breaches. */ -if (!isset($MOD) || !$MOD){ +if(isset($_POST['MOD'])) { + $MOD = $_POST['MOD']; +} elseif (isset($_GET['MOD'])) { + $MOD = $_GET['MOD']; +} + +if (!$MOD){ $MOD='init'; } else { sqspell_ckMOD($MOD); Index: sqspell_options.php =================================================================== RCS file: /cvsroot/squirrelmail/squirrelmail/plugins/squirrelspell/sqspell_options.php,v retrieving revision 1.6 retrieving revision 1.6.2.1 diff -u -w -r1.6 -r1.6.2.1 --- sqspell_options.php 2 Feb 2002 02:17:05 -0000 1.6 +++ sqspell_options.php 14 Aug 2002 14:24:48 -0000 1.6.2.1 @@ -36,7 +36,13 @@ * If $MOD is unspecified, assign "init" to it. Else check for * security breach attempts. */ -if (!isset($MOD) || !$MOD){ +if(isset($_POST['MOD'])) { + $MOD = $_POST['MOD']; +} elseif (isset($_GET['MOD'])) { + $MOD = $_GET['MOD']; +} + +if(!$MOD) { $MOD = 'options_main'; } else { sqspell_ckMOD($MOD); |