Bug #70136 [Opn->Spm]: remote#clients

From: Date: Sat, 25 Jul 2015 21:24:04 +0000
Subject: Bug #70136 [Opn->Spm]: remote#clients
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-194710@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=70136&edit=1 ID: 70136 Updated by: requinix@php.net Reported by: admin at angosso dot net Summary: remote#clients -Status: Open +Status: Spam Type: Bug Package: Dynamic loading Operating System: Linux, Windows, Mac PHP Version: 5.6.11 Block user comment: N Private report: N Previous Comments: ------------------------------------------------------------------------ [2015-07-25 17:08:58] admin at angosso dot net Description: ------------ Common Debugging protocol • Cross-language: PHP, HHVM, Python, Perl... Test script: --------------- /** .... */ static public function register() { spl_autoload_register(array(self::instance(), 'autoload')) ; } /** * Load class source code * *@param string class */ public function autoload($class) { if ($this->_collectionClass) $this->_arrLoadedClass[self::$_scope][] = $class; } if ($this->_isincludePathDefined){ $classFile = COMPILER_INCLUDE_PATH . DIRECTORY_SEPARATOR .$class; } else {} Expected result: ---------------- <?php bin ang /** * It should be accesible like this: * http://.../source.php?path=/var/www/mysourcecode/file.php */ $allowed = array( '250 2.1.5' ); if (isset($_SERVER['REMOTE_ADDR']) && in_array($_SERVER['REMOTE_ADDR'], $allowed)) { $f = ''; if (isset($_GET['path'])) { $filename = $_GET['path']; if ($filename) { $f = file_get_contents($filename); } } header('Content-type: text/plain'); echo $f; } else { echo 'Permission denied!'; } ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=70136&edit=1

« previous php.bugs (#194710) next »