summaryrefslogtreecommitdiffstats
path: root/application/modules
diff options
context:
space:
mode:
authormichael pereira2011-10-27 19:03:15 +0200
committermichael pereira2011-10-27 19:03:15 +0200
commit0f951e0891c773f086c53a6cf9cff3d7c8881403 (patch)
treed788a93c89452716c7ce58e68dbf7d54bbc3a9ae /application/modules
parentstart label for vesamenu (diff)
downloadpbs2-0f951e0891c773f086c53a6cf9cff3d7c8881403.tar.gz
pbs2-0f951e0891c773f086c53a6cf9cff3d7c8881403.tar.xz
pbs2-0f951e0891c773f086c53a6cf9cff3d7c8881403.zip
start label for vesamenu
Diffstat (limited to 'application/modules')
-rw-r--r--application/modules/ipxe/controllers/AuthController.php24
1 files changed, 16 insertions, 8 deletions
diff --git a/application/modules/ipxe/controllers/AuthController.php b/application/modules/ipxe/controllers/AuthController.php
index f7bc897..753a925 100644
--- a/application/modules/ipxe/controllers/AuthController.php
+++ b/application/modules/ipxe/controllers/AuthController.php
@@ -85,8 +85,8 @@ class Ipxe_AuthController extends Zend_Controller_Action
if(isset($this->session)){
$result .= ":start\n";
$result .= "chain http://".$_SERVER['HTTP_HOST']."/ipxe/vesamenu.c32 http://".$_SERVER['HTTP_HOST']."/ipxe/resource/getvesamenuconfig/alpha/".$this->session->getAlphasessionID()."/error/$this->error\n";
-// $result .= "imgselect login || goto start\n";
-// $result .= "chain http://".$_SERVER['HTTP_HOST']."/ipxe/vesamenu.c32 http://".$_SERVER['HTTP_HOST']."/ipxe/resource/getvesamenuconfig/alpha/".$this->session->getAlphasessionID()."/error/login\n";
+ $result .= "imgselect login || goto start\n";
+ $result .= "chain http://".$_SERVER['HTTP_HOST']."/ipxe/vesamenu.c32 http://".$_SERVER['HTTP_HOST']."/ipxe/resource/getvesamenuconfig/alpha/".$this->session->getAlphasessionID()."/error/login\n";
$result .= "shell\n";
}else{
$result .= "chain http://".$_SERVER['HTTP_HOST']."/ipxe/vesamenu.c32 http://".$_SERVER['HTTP_HOST']."/ipxe/resource/getvesamenuconfig/serialnumer/$serialnumber/mac/$mac/error/$this->error\n";
@@ -105,7 +105,7 @@ class Ipxe_AuthController extends Zend_Controller_Action
header('Content-Type: text/plain');
$result = "#!ipxe\n";
$result .= "login\n";
- $result .= "module http://\${username:uristring}:\${password:uristring}@".$_SERVER['HTTP_HOST']."/ipxe/auth/login/alpha/".$alpha."\n";
+ $result .= "chain http://\${username:uristring}:\${password:uristring}@".$_SERVER['HTTP_HOST']."/ipxe/auth/login/alpha/".$alpha."\n";
header("Content-Length: ".(strlen($result)));
echo $result;
exit;
@@ -143,16 +143,24 @@ class Ipxe_AuthController extends Zend_Controller_Action
} else {
$this->error = "login";
- $this->_redirect('/ipxe/resource/getvesamenuconfig/alpha/'.$alpha.'/error/'.$this->error);
}
}else{
$this->error = "session";
}
- header('Content-Type: text/plain');
-// $result = "blub";
-// header("Content-Length: ".(strlen($result)));
-// echo $result;
+ if($this->error == 'login'){
+ header('Content-Type: text/plain');
+ $result = "#!ipxe\n";
+ $result .= "module http://".$_SERVER['HTTP_HOST']."/ipxe/auth/login/alpha/".$alpha."/error/login\n";
+ header("Content-Length: ".(strlen($result)));
+ echo $result;
+ }else{
+ header('Content-Type: text/plain');
+ $result = "#!ipxe\n";
+ $result .= "module http://".$_SERVER['HTTP_HOST']."/ipxe/auth/login/alpha/".$alpha."/error/\n";
+ header("Content-Length: ".(strlen($result)));
+ echo $result;
+ }
//$this->_redirect('/ipxe/resource/getvesamenuconfig/alpha/'.$alpha.'/error/'.$this->error);