//FIXME: should show that safe_mode is off when it is (this only shows the safe_mode setting when it's on) (also might be generally helpful to show things like open_basedir, too or even add phpinfo() output or a link to another script that has phpinfo()
echo $IND . 'safe_mode: ' . $safe_mode;
if (empty($prefs_dsn) || empty($addrbook_dsn))
echo ' (<font color="red">double check data and attachment directory ownership, etc!</font>)';
if (!empty($addrbook_dsn) || !empty($prefs_dsn) || !empty($addrbook_global_dsn))
echo ' (<font color="red">does PHP have access to database interface?</font>)';
do_err('You have register_globals turned on. This is not an error, but it CAN be a security hazard. Consider turning register_globals off.', false);
}
/* variables_order check */
// FIXME(?): Hmm, how do we distinguish between when an ini setting is not available (ini_set() returns empty string) and when the administrator set the value to an empty string? The latter is sure to be highly rare, so for now, just assume that empty value means the setting isn't even available (could also check PHP version when this setting was implemented) although, we'll also warn the user if it is empty, with a non-fatal error
do_err('Your variables_order setting seems to be empty. Make sure it is undefined in any PHP ini files, .htaccess files, etc. and not specifically set to an empty value or SquirrelMail may not function correctly', false);
do_err('Your variables_order setting is insufficient for SquirrelMail to function. It needs at least "GPCS", but you have it set to "' . sm_encode_html_special_chars($variables_order) . '"', true);
// FIXME(?): Hmm, how do we distinguish between when an ini setting is not available (ini_set() returns empty string) and when the administrator set the value to an empty string? The latter is sure to be highly rare, so for now, just assume that empty value means the setting isn't even available (could also check PHP version when this setting was implemented) although, we'll also warn the user if it is empty, with a non-fatal error
do_err('Your gpc_order setting seems to be empty. Make sure it is undefined in any PHP ini files, .htaccess files, etc. and not specifically set to an empty value or SquirrelMail may not function correctly', false);
do_err('Your gpc_order setting is insufficient for SquirrelMail to function. It needs to be set to "GPC", but you have it set to "' . sm_encode_html_special_chars($gpc_order) . '"', true);
do_err("I cannot write to attachment dir ($attachment_dir)!");
}
echo $IND . "Attachment dir OK.<br />\n";
}
echo "Checking plugins...<br />\n";
/* check plugins and themes */
//FIXME: check requirements given in plugin _info() function, such as required PHP extensions, Pear packages, other plugins, SM version, etc see development docs for list of returned info from that function
//FIXME: update this list with most recent contents of the Obsolete category - I think it has changed recently
$bad_plugins = array(
'attachment_common', // Integrated into SquirrelMail 1.2 core
'auto_prune_sent', // Obsolete: See Proon Automatic Folder Pruning plugin
'compose_new_window', // Integrated into SquirrelMail 1.4 core
'delete_move_next', // Integrated into SquirrelMail 1.5 core
'disk_quota', // Obsolete: See Check Quota plugin
'email_priority', // Integrated into SquirrelMail 1.2 core
'emoticons', // Obsolete: See HTML Mail plugin
'focus_change', // Integrated into SquirrelMail 1.2 core
'folder_settings', // Integrated into SquirrelMail 1.5.1 core
'global_sql_addressbook', // Integrated into SquirrelMail 1.4 core
'hancock', // Not Working: See Random Signature Taglines plugin
'msg_flags', // Integrated into SquirrelMail 1.5.1 core
'message_source', // Added to SquirrelMail 1.4 Core Plugins (message_details)
'motd', // Integrated into SquirrelMail 1.2 core
'paginator', // Integrated into SquirrelMail 1.2 core
'printer_friendly', // Integrated into SquirrelMail 1.2 core
'procfilter', // Obsolete: See Server Side Filter plugin
'redhat_php_cgi_fix', // Integrated into SquirrelMail 1.1.1 core
'send_to_semicolon', // Integrated into SquirrelMail 1.4.1 core
'spamassassin', // Not working beyond SquirrelMail 1.2.7: See Spamassassin SpamFilter (Frontend) v2 plugin
'sqcalendar', // Added to SquirrelMail 1.2 Core Plugins (calendar)
'sqclock', // Integrated into SquirrelMail 1.2 core
'sql_squirrel_logger', // Obsolete: See Squirrel Logger plugin
'tmda', // Obsolete: See TMDA Tools plugin
'vacation', // Obsolete: See Vacation Local plugin
'view_as_html', // Integrated into SquirrelMail 1.5.1 core
'xmailer' // Integrated into SquirrelMail 1.2 core
do_err('You have enabled the <i>'.$plugin.'</i> plugin, which causes problems with this version of SquirrelMail. Please check the ReleaseNotes or other documentation for more information.', false);
}
}
// load plugin functions
include_once(SM_PATH . 'functions/plugin.php');
// turn on output buffering in order to prevent output of new lines
// if plugin outputs more than newlines and spacing, stop script execution.
if (!empty($output)) {
$plugin_load_error = 'Some output was produced when plugin <i>' . $name . '</i> was loaded. Usually this means there is an error in the plugin\'s setup or configuration file. The output was: '.sm_encode_html_special_chars($output);
do_err('The plugin <i>' . $name . '</i> is supposed to be registered on the <i>' . $hook_name . '</i> hook, but it is not. You need to re-run the configuration utility and re-save your configuration file.', FALSE);
$missing_plugins .= ', ' . $depend_name . ' (version ' . $depend_requirements['version'] . ', ' . ($depend_requirements['activate'] ? 'must be activated' : 'need not be activated') . ')';
}
$error_string = (!empty($incompatible_plugins) ? $name . ' cannot be activated at the same time as the following plugins: ' . trim($incompatible_plugins, ', ') : '')
. (!empty($missing_plugins) ? (!empty($incompatible_plugins) ? '. ' . $name . ' is also ' : $name . ' is ') . 'missing some dependencies: ' . trim($missing_plugins, ', ') : '');
echo '<p>No fatal errors were found, but there was at least 1 warning. Please check the flagged issue(s) carefully, as correcting them may prevent erratic, undefined, or incorrect behavior (or flat out breakage).</p>';
echo $footer;
} else {
print <<< EOF
<p>Congratulations, your SquirrelMail setup looks fine to me!</p>
<p><a href="login.php">Login now</a></p>
</body>
</html>
EOF;
echo $footer;
}
Documentation generated on Mon, 13 Jan 2020 04:22:11 +0100 by phpDocumentor 1.4.3