Bug #78663 [NEW]: Side effects with _SERVER var _SERVER['root']

From: Date: Fri, 11 Oct 2019 17:36:15 +0000
Subject: Bug #78663 [NEW]: Side effects with _SERVER var _SERVER['root']
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-223177@lists.php.net to get a copy of this message
From: flobee at gmail dot com Operating system: Deb10/ Sury's php packages PHP version: 7.3.10 Package: *General Issues Bug Type: Bug Bug description:Side effects with _SERVER var _SERVER['root'] Description: ------------ Hey Some side effects i dont understand to address to but i can confirm the following: Running as 'root' | 'user' var_dump( in_array( 'root', $_SERVER ) ); // true | false var_dump( isset( $_SERVER['root'] ) ); // false | false var_dump( array_key_exists( 'root', $_SERVER ) ); // false | false hmm. So, my break point 'in_array( 'root', $_SERVER ) ? exit(1)..' works. To be save not running scripts under root, but: I miss a documentation/suggestion or is this a bug? Test script: --------------- # Running as 'root' | 'user' var_dump( in_array( 'root', $_SERVER ) ); // true | false var_dump( isset( $_SERVER['root'] ) ); // false | false var_dump( array_key_exists( 'root', $_SERVER ) ); // false | false Expected result: ---------------- depends on implementation/ documentation. -- Edit bug report at https://bugs.php.net/bug.php?id=78663&edit=1 -- Fix committed: https://bugs.php.net/fix.php?id=78663&r=fixed Fixed in release: https://bugs.php.net/fix.php?id=78663&r=alreadyfixed Need backtrace: https://bugs.php.net/fix.php?id=78663&r=needtrace Need Reproduce Script: https://bugs.php.net/fix.php?id=78663&r=needscript Try newer version: https://bugs.php.net/fix.php?id=78663&r=oldversion Not developer issue: https://bugs.php.net/fix.php?id=78663&r=support Expected behavior: https://bugs.php.net/fix.php?id=78663&r=notwrong Not enough info: https://bugs.php.net/fix.php?id=78663&r=notenoughinfo Submitted twice: https://bugs.php.net/fix.php?id=78663&r=submittedtwice register_globals: https://bugs.php.net/fix.php?id=78663&r=globals PHP version support discontinued: https://bugs.php.net/fix.php?id=78663&r=phptooold Daylight Savings: https://bugs.php.net/fix.php?id=78663&r=dst IIS Stability: https://bugs.php.net/fix.php?id=78663&r=isapi Install GNU Sed: https://bugs.php.net/fix.php?id=78663&r=gnused Floating point limitations: https://bugs.php.net/fix.php?id=78663&r=float No Zend Extensions: https://bugs.php.net/fix.php?id=78663&r=nozend MySQL Configuration Error: https://bugs.php.net/fix.php?id=78663&r=mysqlcfg

« previous php.bugs (#223177) next »