Module: nagvis Branch: master Commit: d85ed369c386f6104b910f3e6565302b3c4ce836 URL: http://nagvis.git.sourceforge.net/git/gitweb.cgi?p=nagvis/nagvis;a=commit;h=d85ed369c386f6104b910f3e6565302b3c4ce836
Author: LaMi <[email protected]> Date: Mon Mar 8 22:30:09 2010 +0100 #202 Removed deprecated auth code --- share/frontend/wui/classes/WuiPage.php | 25 ------------------------- share/server/core/functions/getuser.php | 21 --------------------- 2 files changed, 0 insertions(+), 46 deletions(-) diff --git a/share/frontend/wui/classes/WuiPage.php b/share/frontend/wui/classes/WuiPage.php index bd4ed9c..44b2327 100644 --- a/share/frontend/wui/classes/WuiPage.php +++ b/share/frontend/wui/classes/WuiPage.php @@ -37,9 +37,6 @@ class WuiPage { // String for the body private $body; - // logged in user - private $user; - /** * Class Constructor * @@ -72,9 +69,6 @@ class WuiPage { // http://www.nagios-portal.org/wbb/index.php?page=Thread&threadID=13885 $this->extHeader .= '<meta name="viewport" content="width=480; initial-scale=0.6666; maximum-scale=1.0; minimum-scale=0.6666" />'; - $this->user = getUser(); - $this->CORE->getMainCfg()->setRuntimeValue('user',$this->user); - self::checkPreflight(); } @@ -97,24 +91,6 @@ class WuiPage { } /** - * Checks for logged in Users - * - * @param Boolean $printErr - * @return Boolean Is Check Successful? - * @author Lars Michelsen <[email protected]> - */ - private function checkUser($printErr) { - if($this->user != '') { - return TRUE; - } else { - if($printErr) { - new GlobalMessage('ERROR', $this->CORE->getLang()->getText('noUser')); - } - return FALSE; - } - } - - /** * Does the Prflight checks before building the page * * @return Boolean Is Check Successful? @@ -122,7 +98,6 @@ class WuiPage { */ private function checkPreflight() { $ret = TRUE; - $ret = $ret & $this->checkUser(TRUE); $ret = $ret & $this->checkPHPVersion(TRUE); return $ret; diff --git a/share/server/core/functions/getuser.php b/share/server/core/functions/getuser.php deleted file mode 100644 index d4ebdd9..0000000 --- a/share/server/core/functions/getuser.php +++ /dev/null @@ -1,21 +0,0 @@ -<?PHP -/** -* Gets the User -* -* @return String String with Username -* @author Lars Michelsen <[email protected]> -*/ -function getUser() { - if(isset($_SERVER['PHP_AUTH_USER']) && $_SERVER['PHP_AUTH_USER'] != '') { - return $_SERVER['PHP_AUTH_USER']; - } elseif(isset($_SERVER['REMOTE_USER']) && $_SERVER['REMOTE_USER'] != '') { - return $_SERVER['REMOTE_USER']; - } elseif(isset($_SESSION['nagvis_user']) && $_SESSION['nagvis_user'] != '') { - // Support for session based authentication which is used in Ninja - // This will be changed in 1.5 to module based authentication - return $_SESSION['nagvis_user']; - } else { - return ''; - } -} -?> ------------------------------------------------------------------------------ Download Intel® Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev _______________________________________________ Nagvis-checkins mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/nagvis-checkins
