diff -r 070ff1509cc2 -r 40f7fa5fd061 plugins/admin/SecurityLog.php
--- a/plugins/admin/SecurityLog.php Thu Sep 20 11:27:49 2007 -0400
+++ b/plugins/admin/SecurityLog.php Sun Sep 23 18:42:16 2007 -0400
@@ -21,10 +21,10 @@
return;
}
- if ( defined('ENANO_DEMO_MODE') )
- {
- die('Security log is disabled in demo mode.');
- }
+ // if ( defined('ENANO_DEMO_MODE') && substr($_SERVER['REMOTE_ADDR'], 0, 8) != '192.168.' )
+ // {
+ // die('Security log is disabled in demo mode.');
+ // }
echo '
System security log
';
@@ -79,12 +79,12 @@
unset($dbname, $dbhost, $dbuser, $dbpasswd);
unset($dbname, $dbhost, $dbuser, $dbpasswd); // PHP5 Zend bug
}
- if ( defined('ENANO_DEMO_MODE') && !isset($_GET[ $hash ]) && substr($_SERVER['REMOTE_ADDR'], 0, 8) != '192.168.' )
- {
- $return .= 'Logs are recorded but not displayed for privacy purposes in the demo. |
';
- }
- else
- {
+ // if ( defined('ENANO_DEMO_MODE') && !isset($_GET[ $hash ]) && substr($_SERVER['REMOTE_ADDR'], 0, 8) != '192.168.' )
+ // {
+ // $return .= 'Logs are recorded but not displayed for privacy purposes in the demo. |
';
+ // }
+ // else
+ // {
if(is_int($num))
{
$l = 'SELECT action,date_string,author,edit_summary,time_id,page_text FROM '.table_prefix.'logs WHERE log_type=\'security\' ORDER BY time_id DESC, action ASC LIMIT '.$num.';';
@@ -99,7 +99,7 @@
$return .= seclog_format_inner($r);
}
$db->free_result();
- }
+ // }
$return .= '';
return $return;
@@ -115,6 +115,10 @@
global $db, $session, $paths, $template, $plugins; // Common objects
$return = '';
static $cls = 'row2';
+ if ( substr($_SERVER['REMOTE_ADDR'], 0, 8) != '192.168.' && defined('ENANO_DEMO_MODE') )
+ {
+ $r['edit_summary'] = preg_replace('/([0-9])/', 'x', $r['edit_summary']);
+ }
if ( $r['action'] == 'illegal_page' )
{
list($illegal_id, $illegal_ns) = unserialize($r['page_text']);