From: Brion Vibber Date: Thu, 9 Sep 2004 06:12:04 +0000 (+0000) Subject: Fix register_globals vulnerability checked in last week. X-Git-Tag: 1.5.0alpha1~2048 X-Git-Url: https://git.cyclocoop.org/%242?a=commitdiff_plain;h=6810e5a92e1b92337dcfa4cd3ea27e8c46c8639f;p=lhc%2Fweb%2Fwiklou.git Fix register_globals vulnerability checked in last week. --- diff --git a/includes/DefaultSettings.php b/includes/DefaultSettings.php index 133ab5598e..55d758ef9b 100644 --- a/includes/DefaultSettings.php +++ b/includes/DefaultSettings.php @@ -678,12 +678,13 @@ $wgUseRCPatrol = true; # If you rename it, then you can access them through the new namespace name. # # Custom namespaces should start at 100. -#$wgExtraNamespaces= -# array(100 => "Hilfe", +#$wgExtraNamespaces = +# array(100 => "Hilfe", # 101 => "Hilfe_Diskussion", -# 102 =>"Aide", -# 103 =>"Discussion_Aide" +# 102 => "Aide", +# 103 => "Discussion_Aide" # ); +$wgExtraNamespaces = NULL; # Enable SOAP interface. Off by default # SOAP is a protocoll for remote procedure calls (RPC) using http as middleware. diff --git a/includes/Namespace.php b/includes/Namespace.php index 43f0d78a3a..a52e06d79c 100644 --- a/includes/Namespace.php +++ b/includes/Namespace.php @@ -34,8 +34,8 @@ $wgCanonicalNamespaceNames = array( NS_CATEGORY_TALK => 'Category_talk' ); -if(isset($wgExtraNamespaces)) { - $wgCanonicalNamespaceNames=$wgCanonicalNamespaceNames+$wgExtraNamespaces; +if( defined( 'MEDIAWIKI' ) && is_array( $wgExtraNamespaces ) ) { + $wgCanonicalNamespaceNames = $wgCanonicalNamespaceNames + $wgExtraNamespaces; } /**