diff options
Diffstat (limited to 'application/modules/ipxe/controllers')
| -rw-r--r-- | application/modules/ipxe/controllers/AuthController.php | 9 | ||||
| -rw-r--r-- | application/modules/ipxe/controllers/ResourceController.php | 1 |
2 files changed, 8 insertions, 2 deletions
diff --git a/application/modules/ipxe/controllers/AuthController.php b/application/modules/ipxe/controllers/AuthController.php index 0492339..bedd202 100644 --- a/application/modules/ipxe/controllers/AuthController.php +++ b/application/modules/ipxe/controllers/AuthController.php @@ -34,6 +34,7 @@ class Ipxe_AuthController extends Zend_Controller_Action { $serialnumber = $this->_request->getParam('serialnumber'); $mac = $this->_request->getParam('mac'); + $login = $this->_request->getParam('login'); if(isset($serialnumber)){ // Create a session @@ -69,9 +70,13 @@ class Ipxe_AuthController extends Zend_Controller_Action $result = "#!ipxe\n"; $result .= "imgfree\n"; - $result .= "login\n"; + if(isset($login)){ + $result .= "login\n"; + }else{ + $login = false; + } - $result .= "chain http://".$_SERVER['HTTP_HOST']."/ipxe/resource/getvesamenu/alpha/".$session->getAlphasessionID()." http://\${username:uristring}:\${password:uristring}@".$_SERVER['HTTP_HOST']."/ipxe/resource/getvesamenuconfig/alpha/".$session->getAlphasessionID(); + $result .= "chain http://".$_SERVER['HTTP_HOST']."/ipxe/resource/getvesamenu/alpha/".$session->getAlphasessionID()." http://\${username:uristring}:\${password:uristring}@".$_SERVER['HTTP_HOST']."/ipxe/resource/getvesamenuconfig/alpha/".$session->getAlphasessionID()."/login/".$login; header("Content-Length: ".(strlen($result))); diff --git a/application/modules/ipxe/controllers/ResourceController.php b/application/modules/ipxe/controllers/ResourceController.php index 6884aa1..ed317ce 100644 --- a/application/modules/ipxe/controllers/ResourceController.php +++ b/application/modules/ipxe/controllers/ResourceController.php @@ -87,6 +87,7 @@ class Ipxe_ResourceController extends Zend_Controller_Action $vesamenuView->addScriptPath(APPLICATION_PATH.'/modules/ipxe/views/scripts/resource/'); $vesamenuView->username = $_SERVER['PHP_AUTH_USER']; $vesamenuView->password = $_SERVER['PHP_AUTH_PW']; + $vesamenuView->login = $this->_request->getParam('login'); $vesamenuView->host = $_SERVER['HTTP_HOST']; $_SESSION['alphasessionID'] = $this->thisSession->getAlphasessionID(); |
