aboutsummaryrefslogtreecommitdiffstats
path: root/includes/WebStart.php
diff options
context:
space:
mode:
authorSiebrand Mazeland <siebrand@kitano.nl>2014-05-11 17:34:55 +0200
committerReedy <reedy@wikimedia.org>2014-05-11 19:35:09 +0000
commit4b8523198f177820a0ff835dc1703c6ad8711dd6 (patch)
tree6cfc3ae895944fcef724df4ecd7dcc5ee2d1f064 /includes/WebStart.php
parent2daa1fab7a200ac2045e1e03e17a19fea1792afe (diff)
downloadmediawikicore-4b8523198f177820a0ff835dc1703c6ad8711dd6.tar.gz
mediawikicore-4b8523198f177820a0ff835dc1703c6ad8711dd6.zip
Make phpcs-strict pass on includes/ (4/~10)
Change-Id: I2767205a7059adfb8fa090a82abd332e518f2590
Diffstat (limited to 'includes/WebStart.php')
-rw-r--r--includes/WebStart.php5
1 files changed, 4 insertions, 1 deletions
diff --git a/includes/WebStart.php b/includes/WebStart.php
index 766b3bf53421..09f01c008b1e 100644
--- a/includes/WebStart.php
+++ b/includes/WebStart.php
@@ -30,8 +30,10 @@
# This must be done before any globals are set by the code
if ( ini_get( 'register_globals' ) ) {
if ( isset( $_REQUEST['GLOBALS'] ) || isset( $_FILES['GLOBALS'] ) ) {
- die( '<a href="http://www.hardened-php.net/globals-problem">$GLOBALS overwrite vulnerability</a>' );
+ die( '<a href="http://www.hardened-php.net/globals-problem">'
+ . '$GLOBALS overwrite vulnerability</a>' );
}
+
$verboten = array(
'GLOBALS',
'_SERVER',
@@ -50,6 +52,7 @@ if ( ini_get( 'register_globals' ) ) {
'_SESSION',
'HTTP_SESSION_VARS'
);
+
foreach ( $_REQUEST as $name => $value ) {
if ( in_array( $name, $verboten ) ) {
header( "HTTP/1.1 500 Internal Server Error" );